/* shikinguri_responsive.css — モバイル対応レスポンシブ上書き (UTF-8)
   ----------------------------------------------------------------
   HomepageBuilder固定幅（900px）レイアウトをスマホ対応に変換する。
   container_7C_2c_middle.css の後に読み込むこと。
   ---------------------------------------------------------------- */

/* ── 全幅の画像・テーブル対応（全画面幅共通） ── */
img {
  max-width: 100%;
  height: auto;
}
table {
  max-width: 100%;
  word-break: break-word;
}

/* ── モバイル対応ブレークポイント: 768px以下 ──────────── */
@media screen and (max-width: 768px) {

  /* コンテナ・ヘッダー・インナー: 固定幅→全幅 */
  #hpb-header,
  #hpb-inner,
  #hpb-footer {
    width: 100% !important;
    box-sizing: border-box;
  }

  /* ヘッダー高さをコンテンツに合わせる */
  #hpb-header {
    height: auto !important;
    padding: 8px 10px;
  }

  /* ヘッダー内パーツ */
  #hpb-headerMain,
  #hpb-headerLogo,
  #hpb-headerExtra1 {
    width: 100% !important;
    float: none !important;
    display: block;
    text-align: center;
  }

  /* ナビゲーション: 横並び→縦積み */
  #hpb-nav {
    position: static !important;
    width: 100% !important;
    height: auto !important;
    overflow: visible !important;
    background-image: none !important;
    background-color: #1a3a5c;
  }
  #hpb-nav ul {
    width: 100% !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    display: flex;
    flex-wrap: wrap;
  }
  #hpb-nav li {
    width: 50% !important;
    float: none !important;
    box-sizing: border-box;
    border-right: none !important;
    border-bottom: 1px solid rgba(255,255,255,0.2) !important;
  }
  #hpb-nav li a {
    width: 100% !important;
    box-sizing: border-box;
    padding: 8px 6px;
    font-size: 0.82em;
    text-align: center;
    display: block;
  }

  /* インナーのナビ用padding解除 */
  .hpb-layoutset-02 #hpb-inner {
    padding-top: 0 !important;
  }

  /* ラッパー・メイン・アサイド: float解除→縦積み */
  #hpb-wrapper,
  #hpb-main {
    width: 100% !important;
    float: none !important;
    box-sizing: border-box;
    padding: 0 10px;
  }

  #hpb-aside {
    width: 100% !important;
    float: none !important;
    box-sizing: border-box;
    padding: 0 10px;
    margin-top: 20px;
    border-top: 2px solid #ddd;
  }

  #shopinfo {
    width: 100% !important;
  }

  /* タイトルエリア */
  #hpb-title {
    width: 100% !important;
    height: auto !important;
    padding: 10px;
    box-sizing: border-box;
  }
  #hpb-title h2 {
    font-size: 1em !important;
    overflow: visible !important;
  }

  /* バナーリスト */
  #banner ul {
    display: flex;
    flex-wrap: wrap;
    padding: 0;
    margin: 0;
  }
  #banner ul li {
    width: 48%;
    box-sizing: border-box;
    margin: 1%;
  }

  /* フッター */
  #hpb-footer {
    padding: 20px 10px;
    clear: both;
  }
  #hpb-footerMain,
  #hpb-footerExtra1 {
    width: 100% !important;
    float: none !important;
    box-sizing: border-box;
  }

  /* テーブル: スクロール対応 */
  table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* 横幅指定のある画像を強制リサイズ */
  img[width] {
    width: 100% !important;
    height: auto !important;
  }

  /* フォント調整: 固定pxを相対に */
  body {
    font-size: 14px;
  }
  p {
    font-size: 115% !important;
    line-height: 175% !important;
  }
}

/* ── 超小画面: 480px以下 ──────────────────────────── */
@media screen and (max-width: 480px) {

  #hpb-nav li {
    width: 50% !important;
  }
  #hpb-nav li a {
    font-size: 0.75em;
    padding: 7px 4px;
  }

  #banner ul li {
    width: 98%;
    margin: 1% 1%;
  }

  p {
    font-size: 108% !important;
  }
}
