/* ハンバーガーメニュー：8項目をタブで開閉 */

/* ヘッダー右側ボタン群（メニュー＋言語を縦並び） */
header .container > .clearfix {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

header .header-buttons {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}

/* ハンバーガーボタン（横線3本を縦に並べる） */
#nav-toggle {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 8px 12px;
  background: transparent;
  color: #333;
  border: none;
  cursor: pointer;
  font-size: 16px;
}

#nav-toggle:hover {
  color: #428bca;
}

#nav-toggle .icon-bar {
  display: block;
  width: 22px;
  height: 2px;
  background-color: currentColor;
  margin: 2px 0;
  border-radius: 1px;
}

/* 言語ボタン（地球アイコン＋JP/EN） */
a#language.lang-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 6px 10px;
  border: none;
  background: transparent;
  color: #333;
  font-size: 12px;
  text-decoration: none;
}

a#language.lang-btn:hover {
  color: #428bca;
  background: transparent;
}

a#language.lang-btn .glyphicon-globe {
  font-size: 20px;
}

/* ナビドロップダウン */
nav.nav-dropdown {
  margin-top: 0;
  border: none;
  position: relative;
  min-height: 0;
}

nav.nav-dropdown #menu {
  display: none;
  position: absolute;
  top: 0;
  left: auto;
  right: 15px;
  min-width: 280px;
  z-index: 1000;
  background: white;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
  padding: 10px 0;
  margin-top: 10px;
  flex-direction: column;
}

nav.nav-dropdown #menu.open {
  display: flex;
}

nav.nav-dropdown #menu > div {
  flex: none;
  width: 100%;
  min-width: 0;
  border: none;
}

nav.nav-dropdown #menu a {
  display: block;
  padding: 12px 20px;
  margin: 0;
  border: none;
  border-bottom: 1px solid #eee;
  text-align: left;
  font-size: 16px;
}

nav.nav-dropdown #menu a:last-child {
  border-bottom: none;
}

nav.nav-dropdown #menu a:hover {
  background: #f5f5f5;
}

/* オーバーレイ（メニュー外クリックで閉じる） */
#nav-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 999;
  background: rgba(0, 0, 0, 0.3);
}

#nav-overlay.open {
  display: block;
}
