@charset "utf-8";
/* =====================================================================
   Apple House — レスポンシブ追加レイヤー
   旧 common.css は無改変。これだけで SP対応を実現。
   PC（>=901px）= 旧 1020px 固定レイアウト維持
   タブレット（768-900px）= 軽い縮小
   SP（<=767px）= 1カラム化＋カード2列
   ===================================================================== */

/* ---- iOS Safari 共通対策 ---- */
input, textarea, select, button { font-size: 16px; } /* iOS ズーム防止 */

/* ---- PC含む全画面: sidebar 内画像が幅突破するのを防ぐ ---- */
#sidebar { width: 230px; box-sizing: border-box; }
#sidebar img { max-width: 100%; height: auto; }
#sidebar p.hpBnr { width: 100%; }
#sidebar p.hpBnr img { width: 100%; height: auto; display: block; }
/* main float:right を明示的に強化（HTML順序が sidebar 先になったため） */
#main { float: right; width: 760px; margin-right: 5px; box-sizing: border-box; }
#sidebar { float: left; }
#container::after { content: ""; display: block; clear: both; }

/* ===== タブレット（901px 以下）= シェイプそのまま中央寄せ ===== */
@media (max-width: 1100px) {
  body { min-width: auto !important; }
  #header,
  #hdrSd,
  #nvCo,
  #mainSdBg,
  #container,
  #footer #ftr {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box;
  }
  #mainSdBg { background-size: cover; background-position: center; }
}

/* ===== SP（767px 以下）= 1カラム化 ===== */
@media (max-width: 767px) {
  body { font-size: 14px; line-height: 1.6; }

  /* ヘッダー */
  #header h1 {
    width: auto !important;
    font-size: 10px !important;
    padding: 8px 12px !important;
    line-height: 1.4 !important;
  }
  #header .ln { position: static !important; padding: 4px 12px; text-align: right; }
  #header .ln li { float: none !important; display: inline-block; margin-left: 8px !important; }

  /* グローバルナビ（画像ナビ）→ 2列で並ぶように */
  #nvCo { height: auto !important; padding: 8px 0; background: #fff; }
  #nvCo ul#nv,
  #nvCo ul#topnav {
    width: 100% !important;
    height: auto !important;
    background: none !important;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 4px;
    padding: 0 4px;
  }
  #nvCo ul#nv li,
  #nvCo ul#topnav li {
    float: none !important;
    width: 100% !important;
    margin: 0 !important;
    height: auto !important;
  }
  #nvCo ul#nv li a,
  #nvCo ul#topnav li a {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    background-image: none !important;
    text-indent: 0 !important;
  }
  #nvCo ul#nv li img {
    width: 100% !important;
    height: auto !important;
    display: block;
  }

  /* メインスライダー */
  #mainSdBg,
  #mainSd,
  #mainSd .apple-slider {
    width: 100% !important;
    height: auto !important;
    padding-top: 0 !important;
    background-size: cover !important;
  }
  #mainSd .apple-slider li,
  #mainSd .apple-slider img {
    width: 100% !important;
    height: auto !important;
  }
  #mainSd .apple-slider { position: relative; aspect-ratio: 1020 / 260; }

  /* メイン＋サイドバー → 1カラム積み上げ（メインが先・サイドバー後） */
  #container {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 8px !important;
    box-sizing: border-box !important;
    overflow: visible !important;
  }
  #main { float: none !important; width: 100% !important; max-width: 100% !important; margin: 0 0 24px 0 !important; order: 1; box-sizing: border-box !important; }
  #sidebar { float: none !important; width: 100% !important; max-width: 100% !important; padding: 0 !important; order: 2; box-sizing: border-box !important; }
  /* 画像系 全部 overflow させない */
  #main img, #sidebar img, .wallBox img, .indexMain img { max-width: 100% !important; height: auto !important; }
  /* テーブル類は overflow scroll しないと崩れる場合があるので block 化＋スクロール */
  #main table { display: block; width: 100% !important; max-width: 100% !important; overflow-x: auto; }
  /* ナビ 画像が幅超えないよう */
  #nvCo, #nvCo ul, #nvCo li { max-width: 100% !important; box-sizing: border-box !important; }

  /* H2/H3 見出し：旧テーマの背景画像（heading.png 等のリンゴアイコン含む）はSPで縦伸び事故が出るため
                  背景画像を切って緑グラデのCSS帯に置き換える */
  #main h2 {
    background: linear-gradient(135deg, #1A5E0A 0%, #2c8a16 100%) !important;
    background-image: linear-gradient(135deg, #1A5E0A 0%, #2c8a16 100%) !important;
    color: #fff !important;
    font-size: 16px !important;
    line-height: 1.5 !important;
    padding: 10px 14px !important;
    margin: 18px 0 12px !important;
    border-radius: 3px !important;
    height: auto !important;
    border-left: 4px solid #fff !important;
    box-sizing: border-box !important;
  }
  #main h3, #main h4 {
    background: #f3faf0 !important;
    background-image: none !important;
    color: #1A5E0A !important;
    font-size: 15px !important;
    line-height: 1.5 !important;
    padding: 8px 12px !important;
    margin: 14px 0 10px !important;
    border-left: 4px solid #1A5E0A !important;
    border-bottom: 1px solid #1A5E0A33 !important;
    height: auto !important;
    box-sizing: border-box !important;
  }

  /* 物件カード（wallBox）= 2列グリッド */
  .wallCo.wall3Co.bukkenCo,
  .wallCo.wall3Co,
  .wallCo.wall5Co {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    margin: 0 0 16px 0 !important;
    padding: 0 4px;
  }
  .wallCo .wallBox {
    float: none !important;
    width: 100% !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 8px !important;
    box-sizing: border-box;
  }
  .wallCo .wallBox img {
    width: 100% !important;
    height: auto !important;
    max-width: none !important;
  }
  .wallCo .wallBox dl { margin: 6px 0 0 0 !important; }
  .wallCo .wallBox dt { font-size: 13px !important; margin-bottom: 4px !important; line-height: 1.4 !important; }
  .wallCo .wallBox dd { font-size: 11px !important; line-height: 1.5 !important; word-break: break-all; }
  .wallCo .wallBox .price { font-size: 14px !important; }
  .wallCo .wallBox .newIcon { font-size: 10px !important; padding: 1px 4px !important; }

  /* お知らせ whatsnew */
  .whatsnew dl { margin: 0 !important; padding: 8px 4px !important; }
  .whatsnew dt { font-size: 12px !important; color: #060; }
  .whatsnew dd { font-size: 13px !important; line-height: 1.5 !important; }
  .whatsnew a { display: block; text-decoration: none; }

  /* 投稿詳細・固定ページの本文 */
  #main .post, #main .detailCo, #main p { font-size: 14px !important; line-height: 1.7 !important; padding: 0 8px; word-break: break-word; }
  #main img { max-width: 100% !important; height: auto !important; }
  #main table { max-width: 100% !important; font-size: 12px !important; }
  #main .detailTb,
  #main .outlineTb,
  #main .outlineTb2,
  #main .qandaDl,
  #main .qandaDl2,
  #main .h3Co1Bg,
  #main .box,
  #main .parkingTb,
  #main .inqTb {
    width: 100% !important;
    margin: 0 0 16px 0 !important;
    box-sizing: border-box;
  }
  #main .detailTb th, #main .detailTb td,
  #main .outlineTb th, #main .outlineTb td,
  #main .outlineTb2 th, #main .outlineTb2 td {
    display: block !important;
    width: 100% !important;
    padding: 8px 10px !important;
    box-sizing: border-box;
    border-bottom: none !important;
  }
  #main .detailTb th, #main .outlineTb th, #main .outlineTb2 th {
    border-bottom: 1px solid #ddd !important;
    font-weight: bold;
  }

  /* 写真テーブル系（outlinePhotoP2Tb / P3Tb / P4Tb など）→ 縦並びの画像ギャラリーに */
  #main .outlinePhotoUl,
  #main .outlinePhotoP2Ul,
  #main .outlinePhotoP3Ul,
  #main .outlinePhotoP2Tb,
  #main .outlinePhotoP3Tb,
  #main .outlinePhotoP2Tb2,
  #main .outlinePhotoP3Tb2,
  #main .outlinePhotoP4Tb {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 0 16px 0 !important;
    padding: 0 !important;
    border-collapse: collapse;
  }
  #main .outlinePhotoP2Tb tbody,
  #main .outlinePhotoP3Tb tbody,
  #main .outlinePhotoP2Tb2 tbody,
  #main .outlinePhotoP3Tb2 tbody,
  #main .outlinePhotoP4Tb tbody { display: block !important; width: 100% !important; }
  #main .outlinePhotoP2Tb tr,
  #main .outlinePhotoP3Tb tr,
  #main .outlinePhotoP2Tb2 tr,
  #main .outlinePhotoP3Tb2 tr,
  #main .outlinePhotoP4Tb tr {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    margin-bottom: 10px;
  }
  /* 1個だけの行はフル幅 */
  #main .outlinePhotoP2Tb tr:has(th:only-of-type),
  #main .outlinePhotoP3Tb tr:has(th:only-of-type) {
    grid-template-columns: 1fr !important;
  }
  #main .outlinePhotoP2Tb th,
  #main .outlinePhotoP2Tb td,
  #main .outlinePhotoP3Tb th,
  #main .outlinePhotoP3Tb td,
  #main .outlinePhotoP2Tb2 th,
  #main .outlinePhotoP2Tb2 td,
  #main .outlinePhotoP3Tb2 th,
  #main .outlinePhotoP3Tb2 td,
  #main .outlinePhotoP4Tb th,
  #main .outlinePhotoP4Tb td {
    display: block !important;
    width: 100% !important;
    padding: 0 !important;
    border: none !important;
    text-align: center !important;
    font-weight: normal !important;
  }
  #main .outlinePhotoP2Tb img,
  #main .outlinePhotoP3Tb img,
  #main .outlinePhotoP2Tb2 img,
  #main .outlinePhotoP3Tb2 img,
  #main .outlinePhotoP4Tb img,
  #main .outlinePhotoUl img,
  #main .outlinePhotoP2Ul img,
  #main .outlinePhotoP3Ul img {
    width: 100% !important;
    height: auto !important;
    max-width: 100% !important;
    display: block;
    margin: 0 auto;
    padding: 2px !important;
    box-sizing: border-box;
  }
  /* ulベース ギャラリー（li を縦並びに） */
  #main .outlinePhotoUl li,
  #main .outlinePhotoP2Ul li,
  #main .outlinePhotoP3Ul li {
    display: block !important;
    float: none !important;
    width: 100% !important;
    margin: 0 0 10px 0 !important;
  }

  /* サイドバー */
  #sidebar p.hpBnr { margin: 6px 0 !important; }
  #sidebar p.hpBnr img { width: 100% !important; height: auto !important; max-width: 320px; }
  #sidebar h3 {
    background-size: 100% 100% !important;
    background-repeat: no-repeat !important;
    padding: 6px 14px !important;
    margin: 12px 0 8px !important;
    font-size: 14px !important;
  }
  #sidebar ul { padding: 0 !important; margin: 0 0 16px 0 !important; }
  #sidebar li { padding: 6px 8px !important; }

  /* フッター */
  #footer { height: auto !important; padding: 20px 0 12px !important; background-size: cover !important; }
  #footer #ftr { width: 100% !important; height: auto !important; padding: 0 12px !important; }
  #footer #fw { position: static !important; }
  #footer .ftrLn { position: static !important; text-align: center; margin: 12px 0; }
  #footer .ftrLn li { float: none !important; display: inline-block; font-size: 11px !important; }
  #footer .gaiyou { position: static !important; padding: 12px !important; font-size: 11px !important; text-align: center; }
  #footer .menu { width: 100% !important; margin: 0 0 12px 0 !important; }
  #footer .menu li { float: none !important; width: 100% !important; padding: 4px 8px !important; }
  #footer address { padding: 16px 0 8px !important; font-size: 10px !important; }
}

/* ===== 横スクロール完全防止（iOS sticky 壊さない） ===== */
html, body { max-width: 100%; overflow-x: clip; }
img { max-width: 100%; height: auto; }

/* ===== SP用 強制 100% 幅化（あらゆる旧本文要素・CF7・テーブルを潰す） ===== */
@media (max-width: 767px) {
  /* 旧本文の box/dl/table 系 全部 100%幅・余白リセット */
  #main .ptBoxTb, #main .box, #main .box1, #main .box2, #main .box3, #main .box4, #main .box5,
  #main .h3Co1Bg, #main .h3Co1Bg2, #main .h3Co1,
  #main .outlineCo, #main .outlineCo2, #main .outlineTb, #main .outlineTb2,
  #main .qandaDl, #main .qandaDl2, #main .tSttDl, #main .tSttDl2, #main .tSttDl3, #main .tSttTb,
  #main .qandaSlideCo1, #main .qandaSlideCo2, #main .qandaSlideCo3, #main .qandaSlideCo4,
  #main .caseTb, #main .detailTb, #main .parkingTb, #main .parkingTb2, #main .voiceCo, #main .privacyCo,
  #main .mapCo, #main .arconix-tabs-horizontal, #main .arconix-panes,
  #main .boxCo, #main .tb, #main .inqTb, #main .introTxtCo,
  #main .indexBnrUl, #main .indexIconsUl, #main .indexTagUl, #main .yoyakuUl,
  #main #ln, #main #map, #main .pCo, #main .madoriCo,
  #main .chintaiKensakuCo, #main .baibaiKensakuCo, #main .feas-submit-button,
  #main .post {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 6px !important;
    padding-right: 6px !important;
    box-sizing: border-box !important;
  }
  /* テーブル全て縦並び化（CF7含む） */
  #main table { display: block !important; width: 100% !important; max-width: 100% !important; }
  #main tbody, #main thead, #main tfoot, #main tr { display: block !important; width: 100% !important; }
  #main th, #main td {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    word-break: break-word;
  }
  /* CF7 フォーム要素を強制 100%幅 */
  .apple-cf7-form,
  .apple-cf7-form *,
  form.wpcf7-form,
  form.wpcf7-form * {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  form.wpcf7-form input:not([type=submit]):not([type=checkbox]):not([type=radio]):not([type=file]),
  form.wpcf7-form textarea,
  form.wpcf7-form select {
    width: 100% !important;
  }
  form.wpcf7-form p { word-break: break-word; }
  /* 旧本文の画像・iframe・embed・video */
  #main img, #main iframe, #main embed, #main video, #main object {
    max-width: 100% !important;
    height: auto;
  }
  /* tap.png バナー */
  #main .apple-tap-tel img { max-width: 240px !important; }
  /* 旧本文の段落・dl・dd・dt も padding 制限 */
  #main p, #main dl, #main dt, #main dd, #main ul, #main ol, #main li {
    max-width: 100% !important;
    box-sizing: border-box !important;
    word-break: break-word;
  }
  /* （注）h3 は上の方で緑色帯に置換済み・背景画像なし） */
  /* qandaSlideCo3 内テーブル */
  #main .qandaSlideCo3 table { width: 100% !important; max-width: 100% !important; }
  /* whatsnew 要素 */
  #main .whatsnew dl { margin-left: 0 !important; margin-right: 0 !important; }
  /* sitemap2 リスト */
  #main .html-sitemap ul, #main .html-sitemap li { margin-left: 0 !important; padding-left: 6px !important; }
  /* indexMain（TOPバナー画像） */
  #main .indexMain { width: 100% !important; max-width: 100% !important; padding: 0 !important; margin: 0 0 12px 0 !important; }
  #main .indexMain img { width: 100% !important; height: auto !important; }
}

/* ===== スマホ固定フッター（SP のみ表示） ===== */
#sp-fixed-footer { display: none; }
@media (max-width: 767px) {
  #sp-fixed-footer {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    position: fixed;
    bottom: 0; left: 0; right: 0;
    width: 100%;
    background: linear-gradient(180deg, #ffffff 0%, #f3faf0 100%);
    border-top: 2px solid #1A5E0A;
    z-index: 9999;
    box-shadow: 0 -3px 14px rgba(26,94,10,.18);
    padding-bottom: env(safe-area-inset-bottom, 0);
  }
  #sp-fixed-footer a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 7px 2px 8px;
    text-decoration: none;
    text-align: center;
    color: #2a6f1a;
    font-size: 10.5px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
    transition: transform .15s ease, color .15s ease, background .15s ease;
    position: relative;
  }
  #sp-fixed-footer a + a::before {
    content: "";
    position: absolute;
    left: 0; top: 22%; bottom: 22%;
    width: 1px;
    background: rgba(26,94,10,.12);
  }
  #sp-fixed-footer a svg {
    width: 22px; height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform .2s ease;
  }
  #sp-fixed-footer a:hover svg,
  #sp-fixed-footer a:active svg { transform: translateY(-1px) scale(1.08); }
  #sp-fixed-footer a:active { color: #1A5E0A; }

  /* 電話だけ緑グラデ＋アクセント */
  #sp-fixed-footer a.cta-tel {
    background: linear-gradient(180deg, #2c8a16 0%, #1A5E0A 100%);
    color: #fff;
    font-weight: 800;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.25);
  }
  #sp-fixed-footer a.cta-tel svg { stroke-width: 2; }
  #sp-fixed-footer a.cta-tel::before { display: none; }
  #sp-fixed-footer a.cta-tel:active {
    background: linear-gradient(180deg, #1A5E0A 0%, #0f3d05 100%);
    color: #fff;
  }

  /* フッター分の余白を body 下部に確保（固定フッター高さ + 余裕 + safe-area） */
  body { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)) !important; }
  /* コピーライトと固定フッターが視覚的に被らないよう、address の周りも余白 */
  #footer address { margin-bottom: 12px !important; padding-bottom: 12px !important; }
  /* 固定フッターは不透明背景＋上端ボーダーで本文との視覚的境界を明確化（既存 + 強化） */
  #sp-fixed-footer { background: #fff !important; }
}
