/*----------------------------------
  メンバー専用ページ 共通スタイル
----------------------------------*/
.site-body {
  min-height: 500px;
}

/* サイドバー外枠 */
.member-sidebar-fixed {
  width: 240px;
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  background: #2c3e50;
  box-shadow: 2px 0 5px rgba(0,0,0,0.05);
  color: #fff;
  overflow-y: auto;
  flex-shrink: 0;
}

/* サイドバーメニュー本体 */
.member-sidebar-menu {
  width: 240px;
  list-style: none;
  padding: 0;
  margin: 0;
  background-color: #2c3e50;
}

/* メニュー項目 */
.member-sidebar-menu li {
  margin: 0;
}

.member-sidebar-menu a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  color: #fff;
  background: #2c3e50;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.2s ease;
  font-size: 0.9rem;
}

.member-sidebar-menu a:hover {
  background: #f0f0f0;
  color: #2c3e50;
  border-radius: 0;
}

/* 現在ページハイライト */
.member-sidebar-menu .current-menu-item > a,
.member-sidebar-menu .current_page_item > a {
  background-color: #337ab7;
  color: #fff;
  position: relative;
  border-radius: 0;
}

/* サイドバー内タイトル（PCのみ表示） */
.member-menu-title {
  text-align: center;
  margin: 0;
  color: #fff;
  border: none;
}

/* パンくずリスト */
.vk_breadcrumb_list {
  list-style: none;
  margin: 0;
  padding: 6px 0;
  display: flex;
  flex-wrap: wrap;
  font-size: 12px;
}

.vk_breadcrumb_item {
  display: inline-block;
  margin: 0;
  font-size: 12px;
  list-style: none;
}

.vk_breadcrumb_item::before {
  content: "/";
  margin: 0 .5em;
}

.vk_breadcrumb_item:first-child::before {
  content: none;
}

.vk_breadcrumb_item a {
  text-decoration: none;
  color: #0073aa;
}

.vk_breadcrumb_item a:hover {
  text-decoration: underline;
}

/* 初期状態ではアコーディオン用ボタンを隠す */
.member-menu-toggle {
  display: none;
}


/*----------------------------------
  レイアウト調整（PC）
----------------------------------*/
@media (min-width: 992px) {
  .site-body {
    display: flex;
    align-items: stretch;
  }

  /* 本文エリアをサイドバー分だけ右にマージン */
  .site-body-container.container {
    margin-left: 240px;
    max-width: calc(100% - 240px);
    padding: 0 15px;
  }

  /* サイトボディ内 wrapper 幅制限 */
  .site-body-inner.with-member-sidebar {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 15px;
  }
}


/*----------------------------------
  レイアウト調整（スマホ：アコーディオン用）
----------------------------------*/
@media (max-width: 991px) {

  /* 全体 block レイアウトに切替 */
  .site-body {
    display: block;
  }

  .site-body {
  padding-top: 0 !important;
  }

  
  /* サイドバー外枠は全幅、背景をなしに */
  .member-sidebar-fixed {
    width: 100%;
    position: relative;
    background: none;
    box-shadow: none;
    margin-bottom: 4%;
    }

  /* アコーディオン開閉ボタン表示 */
  .member-menu-toggle {
    display: block;
    width: 100%;
    padding: 1rem;
    background: #1f3d5b;
    color: #fff;
    font-weight: bold;
    font-size: 1rem;
    border: none;
    text-align: left;
    cursor: pointer;
  }

  /* メニュー本体（初期は非表示） */
  .member-sidebar-nav {
    display: none;
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    width: 100%;
  }

  /* アコーディオン開いた状態 */
   .member-sidebar-nav.open {
    display: block;
    background-color: #1f3d5b;
  }

  /* 展開時の「会員専用MENU」タイトルは隠す */
  .member-menu-title {
    display: none;
  }

  /* ul メニューも全幅 */
  .member-sidebar-menu {
    width: 100%;
    background: none;
  }

  .member-sidebar-menu li a {
    padding: 12px 16px;
    color: #fff;
    background: none;
    border-radius: 0;
    font-weight: normal;
  }

  .member-sidebar-menu .current-menu-item > a,
  .member-sidebar-menu .current_page_item > a {
    background-color: #337ab7;
    color: #fff;
  }

  /* 本文エリアは横幅いっぱい＆左右余白 */
  .site-body-container.container,
  .breadcrumb > .container,
  .page-header-inner.container {
    margin: 0 auto;
    max-width: 100%;
    padding: 0 1rem;
  }
}
