/*
Theme Name: Orijinal Child - Responsive
Theme URI: http://kuwashige-dance.com/
Description: オリジナルテーマのレスポンシブ対応子テーマ
Author: Kuwashige Dance School
Author URI: http://kuwashige-dance.com/
Template: orijinal
Version: 1.0.0
Text Domain: orijinal-child
*/

/* ==========================================================================
   親テーマのスタイルを継承
   ========================================================================== */
/* 親テーマのスタイルはfunctions.phpで読み込みます */

/* ==========================================================================
   重要：floatレイアウトの基本設定
   ========================================================================== */
#wrapper {
    overflow: visible;
}

/* floatをクリアする要素 */
.clear {
    clear: both;
    height: 0;
    line-height: 0;
    font-size: 0;
}

/* ==========================================================================
   重要：デスクトップ表示では親テーマのレイアウトを完全に保持
   ========================================================================== */

/* デフォルトはcontent-box（親テーマと同じ） */
* {
    box-sizing: content-box;
}

/* ==========================================================================
   デスクトップ (941px以上) - 2カラムレイアウトを確実に維持
   ========================================================================== */
@media screen and (min-width: 941px) {
    /* wrapperを固定幅に */
    #wrapper {
        width: 940px !important;
        margin: 0 auto !important;
        padding: 0 !important;
        position: relative !important;
    }

    .inner {
        width: 940px !important;
        margin: 0 auto !important;
        padding: 0 !important;
    }

    /* サイドバーを左に配置（本番サイトと同じ） */
    body #wrapper #sidebar,
    #sidebar {
        width: 265px !important;
        float: left !important;
        clear: none !important;
        margin: 0 !important;
        margin-top: 0 !important;
        padding: 10px 40px 10px 0 !important;
        padding-top: 10px !important;
        border-top: none !important;
        box-sizing: content-box !important;
        position: relative !important;
        display: block !important;
    }

    /* メインコンテンツを右に配置 */
    #content_top {
        width: 625px !important;
        float: right !important;
        clear: none !important;
        margin: 0 !important;
        padding: 20px 0 10px 0 !important;
        box-sizing: content-box !important;
        position: relative !important;
    }

    #content {
        width: 625px !important;
        float: right !important;
        clear: none !important;
        margin: 0 !important;
        padding: 10px 0 10px 0 !important;
        box-sizing: content-box !important;
        position: relative !important;
    }

    /* サイドバーの子要素も制御 */
    #sidebar section,
    #sidebar .widget {
        width: 100% !important;
        box-sizing: content-box !important;
    }

    /* フッターのレイアウト */
    #footer {
        clear: both !important;
        width: 100% !important;
    }

    #footerLogo {
        width: 280px !important;
        float: left !important;
    }

    #footer ul {
        width: 660px !important;
        float: left !important;
    }

    /* clearfix - より確実に */
    #wrapper:after,
    #wrapper:before {
        content: "";
        display: table;
        clear: both;
    }

    /* wrapperの高さを確保 */
    #wrapper {
        overflow: hidden;
        *zoom: 1; /* IE7対応 */
    }

    /* floatの確実なクリア */
    .clear:after,
    .clear:before {
        content: "";
        display: table;
        clear: both;
    }

    /* モバイルメニューボタンは非表示 */
    .mobile-menu-toggle {
        display: none !important;
    }

    /* PC用メニュー表示、モバイル用メニュー非表示 */
    nav#mainNav.pc-menu {
        display: block !important;
    }

    nav#mobileNav.mobile-menu {
        display: none !important;
    }
}

/* ==========================================================================
   タブレット (768px - 940px)
   ========================================================================== */
@media screen and (max-width: 940px) {
    /* ここからbox-sizingを適用 */
    * {
        box-sizing: border-box;
    }

    /* コンテナの幅調整 */
    #wrapper, .inner {
        width: 100%;
        max-width: 940px;
        padding: 0 20px;
    }

    /* ヘッダー調整 */
    #header .inner {
        padding: 10px 20px;
    }
}

/* 768px以上940px以下では2カラムを維持 */
@media screen and (min-width: 768px) and (max-width: 940px) {
    /* メインコンテンツエリア */
    #content_top,
    #content {
        width: calc(100% - 285px);
        float: left;
    }

    /* サイドバー */
    #sidebar {
        width: 265px;
        float: right;
    }

    /* フッターの調整 */
    #footerLogo {
        width: 40%;
    }

    #footer ul {
        width: 60%;
    }
}

/* ==========================================================================
   モバイル (767px以下) - 1カラムレイアウト
   ========================================================================== */
@media screen and (max-width: 767px) {
    /* 1カラムレイアウトへ変更 */
    #content_top,
    #content {
        float: none !important;
        width: 100% !important;
        padding: 20px 0 !important;
    }

    /* サイドバーを非表示 */
    #sidebar {
        display: none !important;
    }

    /* モバイルヘッダーの最適化 */
    #header {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        width: 100%;
        z-index: 9999;
        background: #fff;
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
        -webkit-backface-visibility: hidden;
        backface-visibility: hidden;
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
    }

    #header .inner {
        height: 114px; /* 固定高さで安定化 */
        padding: 0;
        position: relative;
        overflow: hidden;
    }

    /* モバイルでの見出し調整 - 全幅表示、常に表示 */
    #header .inner h1 {
        display: block !important;
        position: static !important;
        font-size: 9px !important;
        line-height: 1.3 !important;
        margin: 0 !important;
        padding: 6px 10px !important;
        color: #666 !important;
        text-align: center !important;
        width: 100% !important;
        visibility: visible !important;
        opacity: 1 !important;
        top: auto !important;
        left: auto !important;
        background: #f9f9f9;
        border-bottom: 1px solid #e5e5e5;
        height: 32px; /* 固定高さで安定化 */
        box-sizing: border-box;
        overflow: hidden;
    }

    #header .inner hgroup {
        display: block !important;
        width: 100% !important;
        height: 114px; /* 固定高さで安定化 */
        visibility: visible !important;
        opacity: 1 !important;
        position: static !important;
    }

    #header .inner h2 {
        position: static !important;
        margin: 0 !important;
        display: flex !important;
        padding: 0px 8px;
        height: 82px; /* h1の下の残りの高さ（114 - 32 = 82） */
        box-sizing: border-box;
        align-items: center;
        pointer-events: none; /* h2自体はクリックを受け取らない */
    }

    #header .inner h2 a,
    #header .inner h2 img {
        pointer-events: auto; /* リンクと画像はクリック可能に */
    }

    #header .inner h2 img {
        height: 64px;
        width: auto;
        max-width: 200px;
        display: block;
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }

    /* 電話番号と住所を非表示（必要に応じてフッターに移動） */
    #info {
        display: none;
    }

    /* メニューバナーを非表示 */
    #menu {
        display: none !important;
    }

    /* コンテンツの上部・下部マージンを確保 - 固定ヘッダー＆固定帯対応 */
    body {
        padding-top: 114px; /* ヘッダー全体の高さ（h1含む）*/
        padding-bottom: 60px; /* 固定帯の高さ分 */
        -webkit-overflow-scrolling: touch;
    }

    /* メイン画像の位置調整 - モバイルでは画面幅いっぱいに、余白なし */
    div#mainImg {
        margin-top: 0; /* ヘッダー直下に配置、余白なし */
        position: relative;
        left: 50%;
        right: 50%;
        margin-left: -50vw;
        margin-right: -50vw;
        width: 100vw;
        max-width: 100vw;
        background: transparent !important;
        padding: 0;
        height: 190px;
        overflow: hidden;
    }

    div#mainImg img {
        width: 100%;
        height: auto;
        display: block;
    }

    /* PC用メニュー非表示、モバイル用メニュー表示 */
    nav#mainNav.pc-menu {
        display: none !important;
    }

    nav#mobileNav.mobile-menu {
        display: block !important;
    }

    /* ナビゲーションのモバイル対応 */
    nav#mobileNav {
        position: fixed;
        top: 114px; /* ヘッダーの高さ */
        left: -100%;
        width: 80%;
        max-width: 300px;
        height: calc(100vh - 114px);
        background: #fff;
        box-shadow: 2px 0 10px rgba(0,0,0,0.2);
        transition: left 0.3s ease;
        z-index: 9998;
        overflow-y: auto;
    }

    /* メニューが開いた時 */
    nav#mobileNav.active {
        left: 0;
    }

    /* メニューオーバーレイ */
    .menu-overlay {
        display: none;
        position: fixed;
        top: 114px; /* ヘッダーの高さ */
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0,0,0,0.5);
        z-index: 9997;
    }

    .menu-overlay.active {
        display: block;
    }

    /* モバイルメニューボタン（ヘッダー内に配置） */
    .mobile-menu-toggle {
        display: flex !important;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        background: #3c2f13;
        border: none;
        border-radius: 4px;
        cursor: pointer;
        position: absolute !important;
        right: 8px;
        top: 51px; /* h1（32px）+ h2エリアの中央（(82-44)/2 = 19）= 32+19 = 51 */
        transition: background 0.3s ease;
        flex-shrink: 0;
        z-index: 10000; /* ヘッダーより上に配置 */
        will-change: transform;
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
        pointer-events: auto; /* クリックを確実に受け取る */
    }

    .mobile-menu-toggle:hover {
        background: #624e24;
    }

    /* ハンバーガーアイコン */
    .hamburger-line {
        display: block;
        width: 24px;
        height: 3px;
        background: #fff;
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        transition: all 0.3s ease;
    }

    .hamburger-line:nth-child(1) {
        top: 13px;
    }

    .hamburger-line:nth-child(2) {
        top: 50%;
        transform: translate(-50%, -50%);
    }

    .hamburger-line:nth-child(3) {
        bottom: 13px;
    }

    /* メニューが開いた時のアニメーション */
    .mobile-menu-toggle.active .hamburger-line:nth-child(1) {
        top: 50%;
        transform: translate(-50%, -50%) rotate(45deg);
    }

    .mobile-menu-toggle.active .hamburger-line:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-toggle.active .hamburger-line:nth-child(3) {
        bottom: 50%;
        transform: translate(-50%, 50%) rotate(-45deg);
    }

    /* モバイルメニューを調整 */
    nav#mobileNav .inner {
        padding: 0;
    }

    /* LINE誘導バナー */
    .mobile-menu-line-banner {
        background: #06C755;
        margin: 0;
        padding: 0;
    }

    .mobile-menu-line-link {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 16px 20px;
        text-decoration: none;
        color: #FFFFFF;
        font-weight: 700;
        font-size: 16px;
        transition: background 0.2s ease;
    }

    .mobile-menu-line-link:active {
        background: #05B44C;
    }

    .line-banner-text {
        flex: 1;
    }

    .line-banner-arrow {
        font-size: 20px;
        font-weight: 700;
        margin-left: 10px;
    }

    nav#mobileNav ul {
        background: transparent;
        padding: 20px 0;
        margin: 0;
    }

    /* メニュー項目のスタイル調整 */
    nav#mobileNav ul li {
        float: none;
        width: 100%;
        height: auto;
        line-height: normal;
        padding: 0;
        margin: 0;
        background: none;
        border-bottom: 1px solid #e5e5e5;
    }

    nav#mobileNav ul li:first-child {
        border-top: 1px solid #e5e5e5;
    }

    nav#mobileNav ul li a {
        padding: 16px 20px;
        text-align: left;
        display: block;
        color: #3c2f13;
        text-decoration: none;
        font-size: 16px;
        font-weight: 500;
        transition: background 0.3s ease;
    }

    nav#mobileNav ul li a:hover {
        background: #f5f5f5;
        color: #624e24;
    }

    nav#mobileNav ul li a span {
        display: inline-block;
    }

    /* サブメニューの調整 */
    nav#mobileNav ul li:hover ul {
        position: static;
        width: 100%;
        top: auto;
        left: auto;
    }

    nav#mobileNav ul li li {
        width: 100%;
        background: #f8f8f8;
        padding-left: 20px;
    }

    nav#mobileNav ul li li a {
        width: 100%;
        padding: 10px 20px;
    }

    /* フッターの1カラム化 */
    #footerLogo,
    #footer ul {
        float: none;
        width: 100%;
        text-align: center;
    }

    #footerLogo {
        margin-bottom: 20px;
    }

    #footer ul li {
        display: block;
        margin: 10px 0;
        text-align: left;
    }


    /* テーブルのレスポンシブ化 */
    table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* サイドバーウィジェットの調整 */
    section.widget {
        padding: 15px;
        background: #f8f8f8;
        border-radius: 5px;
        margin-bottom: 15px;
    }
}

/* ==========================================================================
   スマートフォン (480px以下)
   ========================================================================== */
@media screen and (max-width: 480px) {
    /* 基本フォントサイズの調整 */
    body {
        font-size: 14px;
        line-height: 1.6;
    }

    /* パディングの調整 */
    #wrapper, .inner {
        padding: 0 8px;
    }

    /* ヘッダーの簡略化 */
    #header .inner h1 {
        font-size: 11px;
        text-align: center;
        margin-bottom: 10px;
    }

    #header .inner h2 {
        text-align: center;
    }

    #header .inner h2 img {
        max-width: 250px;
    }

    #info {
        font-size: 13px;
        line-height: 1.5;
    }

    #info span {
        display: block;
        margin-top: 5px;
    }

    /* タイトルのサイズ調整 */
    h2.title {
        font-size: 18px;
        margin: 15px 0;
        padding: 5px;
    }

    .post h1 {
        font-size: 22px;
    }

    .post h2 {
        font-size: 20px;
    }

    .post h3 {
        font-size: 18px;
        padding-left: 30px;
    }

    h4 {
        width: 100%;
        font-size: 16px;
        text-indent: 25px;
    }


    /* フォームの調整 */
    input[type="text"],
    input[type="email"],
    input[type="tel"],
    textarea {
        width: 100%;
        max-width: 100%;
    }

    /* ボタンの調整 */
    input[type="submit"],
    input[type="reset"],
    input[type="button"] {
        width: 100%;
        padding: 12px;
        font-size: 16px;
    }

    /* トップページのサムネイル調整 */
    .thumbWrap {
        width: 100%;
        margin-right: 0;
    }

    .thumbWrap li {
        float: none;
        width: 100%;
        margin: 0 0 20px 0;
    }

    /* ニュース欄の調整 */
    #news dl dt {
        float: none;
        width: 100%;
        padding-bottom: 5px;
    }

    #news dl dd {
        margin-left: 0;
        padding-left: 20px;
    }

    /* ページナビゲーションの調整 */
    .pagenav {
        margin: 20px 0;
    }

    .prev, .next {
        float: none;
        width: 100%;
        text-align: center;
        margin: 10px 0;
    }

    /* コメントフォームの調整 */
    #commentform p textarea {
        width: 100%;
    }
}

/* ==========================================================================
   レスポンシブ画像（全サイズ共通）
   ========================================================================== */
img {
    max-width: 100%;
    height: auto;
}

/* ==========================================================================
   アクセシビリティとユーザビリティの向上
   ========================================================================== */

/* タッチデバイス用のタップ領域拡大（モバイルのみ） */
@media (hover: none) and (pointer: coarse) and (max-width: 767px) {
    nav#mobileNav ul li a,
    .mobile-menu-toggle,
    input[type="submit"],
    input[type="button"],
    input[type="reset"] {
        min-height: 44px;
        line-height: 44px;
    }

    /* リンクのタップ領域確保 */
    a {
        display: inline-block;
        min-height: 44px;
        min-width: 44px;
        padding: 10px 5px;
    }

    .post p a,
    .post li a {
        display: inline;
        min-height: auto;
        min-width: auto;
        padding: 2px;
    }
}

/* フォーカス時のアウトライン */
a:focus,
input:focus,
textarea:focus,
button:focus {
    outline: 2px solid #624e24;
    outline-offset: 2px;
}

/* スムーススクロール */
html {
    scroll-behavior: smooth;
}

/* プリント用スタイル */
@media print {
    nav#mainNav,
    nav#mobileNav,
    #sidebar,
    #footer ul,
    .mobile-menu-toggle {
        display: none;
    }

    #content_top,
    #content {
        width: 100%;
        float: none;
    }

    a[href]:after {
        content: " (" attr(href) ")";
    }

    .floating-contact-buttons {
        display: none;
    }
}

/* ==========================================================================
   問い合わせ・予約動線（モバイル固定帯）
   ========================================================================== */

/* PC表示では非表示 */
.mobile-contact-bar {
    display: none;
}

/* モバイル対応 (767px以下) */
@media screen and (max-width: 767px) {
    .mobile-contact-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        z-index: 9996;
        background: #FFFFFF;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
        border-top: 1px solid #e5e5e5;
    }

    .mobile-contact-btn {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 14px 16px;
        text-decoration: none;
        transition: all 0.2s ease;
        min-height: 56px;
        font-weight: 700;
        font-size: 16px;
    }

    .mobile-contact-btn:active {
        transform: scale(0.98);
    }

    .mobile-contact-text {
        font-size: 16px;
        font-weight: 700;
        line-height: 1.2;
    }

    /* 電話ボタン */
    .mobile-contact-btn-tel {
        background: #8B7355;
        color: #FFFFFF;
    }

    .mobile-contact-btn-tel:active {
        background: #6D5A42;
    }

    /* LINEボタン */
    .mobile-contact-btn-line {
        background: #06C755;
        color: #FFFFFF;
    }

    .mobile-contact-btn-line:active {
        background: #05B44C;
    }
}

/* モバイル (767px以下) - ヘッダー内は非表示 */
@media screen and (max-width: 767px) {
    #info {
        display: none !important;
    }
}

/* ==========================================================================
   h5の固定幅を削除（レスポンシブ対応）
   ========================================================================== */
h5 {
    width: auto !important;
}

/* ==========================================================================
   コンテンツ内の画像をレスポンシブ対応
   ========================================================================== */
#content img,
#content_top img {
    max-width: 100% !important;
    height: auto !important;
}

/* お問い合わせ画像などの固定幅を上書き */
#content img[width="625"],
#content_top img[width="625"] {
    width: 100% !important;
}

/* ==========================================================================
   テーブルのレスポンシブ対応（モバイルのみ）
   ========================================================================== */
@media screen and (max-width: 767px) {
    /* タイムテーブル以外の通常テーブル */
    #content table:not([style*="font-size: 90%"]),
    #content_top table:not([style*="font-size: 90%"]) {
        width: 100vw !important;
        max-width: 100% !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-top: 15px !important;
        margin-bottom: 15px !important;
        display: table !important;
        table-layout: fixed !important;
    }

    #content table:not([style*="font-size: 90%"]) tbody,
    #content_top table:not([style*="font-size: 90%"]) tbody {
        display: table-row-group;
    }

    #content table:not([style*="font-size: 90%"]) tr,
    #content_top table:not([style*="font-size: 90%"]) tr {
        display: table-row;
    }

    #content table:not([style*="font-size: 90%"]) th,
    #content table:not([style*="font-size: 90%"]) td,
    #content_top table:not([style*="font-size: 90%"]) th,
    #content_top table:not([style*="font-size: 90%"]) td {
        display: table-cell !important;
        box-sizing: border-box;
        word-wrap: break-word;
        vertical-align: middle;
    }

    #content table:not([style*="font-size: 90%"]) th,
    #content_top table:not([style*="font-size: 90%"]) th {
        background: #f5f5f5;
        border-bottom: none;
        padding: 10px 15px;
        font-weight: 700;
        width: 35% !important;
    }

    #content table:not([style*="font-size: 90%"]) td,
    #content_top table:not([style*="font-size: 90%"]) td {
        border-top: none;
        padding: 10px 15px 15px 15px;
        border-bottom: 1px solid #e5e5e5;
        width: 65% !important;
    }

    /* タイムテーブル専用のスタイル */
    #content table[style*="font-size: 90%"],
    #content_top table[style*="font-size: 90%"] {
        width: 100% !important;
        display: block !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        margin: 15px 0 !important;
        font-size: 11px !important;
        border: 1px solid #ddd;
    }

    #content table[style*="font-size: 90%"] tbody,
    #content_top table[style*="font-size: 90%"] tbody {
        display: table !important;
        width: 100% !important;
        min-width: 600px !important;
    }

    #content table[style*="font-size: 90%"] tr,
    #content_top table[style*="font-size: 90%"] tr {
        display: table-row !important;
    }

    #content table[style*="font-size: 90%"] th,
    #content table[style*="font-size: 90%"] td,
    #content_top table[style*="font-size: 90%"] th,
    #content_top table[style*="font-size: 90%"] td {
        display: table-cell !important;
        padding: 6px 4px !important;
        font-size: 11px !important;
        line-height: 1.3 !important;
        border: 1px solid #ddd !important;
        vertical-align: middle !important;
    }

    #content table[style*="font-size: 90%"] th[scope="col"],
    #content_top table[style*="font-size: 90%"] th[scope="col"] {
        background: #f5f5f5 !important;
        font-weight: 700 !important;
        position: sticky !important;
        top: 0 !important;
        z-index: 10 !important;
    }

    #content table[style*="font-size: 90%"] th[scope="row"],
    #content_top table[style*="font-size: 90%"] th[scope="row"] {
        background: #fafafa !important;
        font-weight: 700 !important;
        white-space: nowrap !important;
    }

    /* タイムテーブルのリンク調整 */
    #content table[style*="font-size: 90%"] a,
    #content_top table[style*="font-size: 90%"] a {
        font-size: 11px !important;
        line-height: 1.2 !important;
        display: block !important;
        padding: 2px !important;
    }
}

/* #menuセクションはモバイルでは非表示（305-307行目で設定済み） */

/* ==========================================================================
   Googleマップのレスポンシブ対応
   ========================================================================== */
.map-container {
    position: relative;
    width: 100%;
    max-width: 625px;
    margin: 20px auto;
}

.map-container iframe {
    width: 100% !important;
    height: 400px !important;
    border: 0;
    display: block;
}

@media screen and (max-width: 767px) {
    .map-container {
        max-width: 100%;
        margin: 20px 0;
    }

    .map-container iframe {
        width: 100% !important;
        height: 300px !important;
    }
}

/* ==========================================================================
   .alignright / .alignleft 画像とh3見出しのモバイル対応（スタジオ案内ページ等）
   ========================================================================== */
@media screen and (max-width: 767px) {
    /* .alignright画像をモバイルで中央配置、フロート解除 */
    .alignright {
        float: none !important;
        margin: 0 auto 15px auto !important;
        display: block !important;
    }

    /* .alignleft画像をモバイルで中央配置、フロート解除 */
    .alignleft {
        float: none !important;
        margin: 0 auto 15px auto !important;
        display: block !important;
    }

    /* h3見出しのモバイル調整 */
    #content h3,
    #content_top h3 {
        font-size: 18px !important;
        margin: 20px 0 10px 0 !important;
        padding: 8px 8px 8px 32px !important;
        line-height: 1.4 !important;
        background-size: 860px auto !important;
        background-position: 0px center !important;
        min-height: auto !important;
    }

    .post h3 {
        font-size: 18px !important;
        padding: 8px 8px 8px 32px !important;
        line-height: 1.4 !important;
        background-size: 860px auto !important;
        background-position: 0px center !important;
    }
}

/* ==========================================================================
   #icatch（アイキャッチ）セクションのモバイル対応
   ========================================================================== */
@media screen and (max-width: 767px) {
    #icatch {
        display: flex !important;
        flex-direction: column;
        gap: 20px;
        padding: 0 !important;
        margin: 20px 0 !important;
    }

    #icatch_l,
    #icatch_r {
        width: 100% !important;
        float: none !important;
        margin: 0 !important;
        padding: 0 !important;
        position: relative;
    }

    #icatch_l img,
    #icatch_r img {
        width: 100% !important;
        height: auto !important;
        display: block;
    }

    /* テキストを中央配置 */
    #icatch_l,
    #icatch_r {
        text-align: center;
        padding: 15px 10px !important;
    }

    /* .catchリンクを上下中央に配置（背景画像300×31pxに合わせる） */
    .catch {
        margin: 15px auto 0 auto !important;
        padding: 0 !important;
        text-align: center !important;
        width: 300px !important;
        height: 31px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        background-size: 300px 31px !important;
    }

    .catch a {
        width: 100%;
        height: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
        text-decoration: none;
    }
}

/* ==========================================================================
   CTAセクション（ページ内問い合わせボタン）
   ========================================================================== */

.cta-section {
    width: 100%;
    padding: 60px 20px;
    text-align: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-top: 3px solid #3c2f13;
    border-bottom: 3px solid #3c2f13;
    margin: 40px 0;
}

.cta-container {
    max-width: 800px;
    margin: 0 auto;
}

.cta-heading {
    font-size: 32px;
    font-weight: 700;
    color: #3c2f13;
    margin: 0 0 15px 0;
    line-height: 1.3;
}

.cta-subheading {
    font-size: 18px;
    color: #666;
    margin: 0 0 30px 0;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 18px 40px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 18px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    min-width: 200px;
}

.cta-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.cta-btn:active {
    transform: translateY(-1px);
}

.cta-btn-tel {
    background: #8B7355;
    color: #FFFFFF;
    border: 2px solid #8B7355;
}

.cta-btn-tel:hover {
    background: #6D5A42;
    border-color: #6D5A42;
}

.cta-btn-line {
    background: #A89080;
    color: #FFFFFF;
    border: 2px solid #A89080;
}

.cta-btn-line:hover {
    background: #8B7768;
    border-color: #8B7768;
}

.cta-btn-form {
    background: #9E8B7A;
    color: #FFFFFF;
    border: 2px solid #9E8B7A;
}

.cta-btn-form:hover {
    background: #7E6D5E;
    border-color: #7E6D5E;
}

.cta-text {
    font-size: 18px;
    font-weight: 700;
}

.cta-note {
    font-size: 14px;
    color: #888;
    margin: 15px 0 0 0;
}

/* タブレット (768px以下) */
@media screen and (max-width: 768px) {
    .cta-section {
        padding: 40px 15px;
        margin: 30px 0;
    }

    .cta-heading {
        font-size: 26px;
    }

    .cta-subheading {
        font-size: 16px;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }

    .cta-btn {
        width: 100%;
        max-width: 320px;
        padding: 16px 28px;
        font-size: 17px;
        min-height: 56px;
    }
}

/* モバイル (480px以下) */
@media screen and (max-width: 480px) {
    .cta-section {
        padding: 30px 10px;
        margin: 20px 0;
    }

    .cta-heading {
        font-size: 22px;
    }

    .cta-subheading {
        font-size: 14px;
        margin-bottom: 20px;
    }

    .cta-btn {
        padding: 14px 24px;
        font-size: 16px;
        min-height: 50px;
    }

    .cta-icon {
        font-size: 20px;
    }

    .cta-text {
        font-size: 16px;
    }

    .cta-note {
        font-size: 12px;
    }

    /* 日曜祝日の前に改行 */
    .cta-note-holiday::before {
        content: "\A";
        white-space: pre;
    }
}