/**
 * NEXUS 多言語対応 (i18n) スタイル
 * 言語スイッチャーとドロップダウンメニューのスタイル
 */

/* 言語スイッチャーボタン */
.lang-switch {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--glass, rgba(255, 255, 255, 0.03));
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.08));
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  color: var(--gray-300, #cbd5e1);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  user-select: none;
}

.lang-switch:hover {
  background: var(--glass-hover, rgba(255, 255, 255, 0.06));
  border-color: var(--purple, #7c3aed);
  color: var(--white, #ffffff);
}

.lang-switch i {
  font-size: 14px;
}

.lang-switch i:first-child {
  color: var(--cyan, #22d3ee);
}

/* ドロップダウンメニュー */
.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 140px;
  background: var(--nebula-1, #1a0a2e);
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.08));
  border-radius: 16px;
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.2s ease;
  z-index: 1000;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.lang-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* ドロップダウンオプション */
.lang-option {
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 14px;
  color: var(--gray-300, #cbd5e1);
  cursor: pointer;
  transition: all 0.2s ease;
}

.lang-option:hover {
  background: var(--glass, rgba(255, 255, 255, 0.03));
  color: var(--white, #ffffff);
}

.lang-option.active {
  background: linear-gradient(135deg, var(--purple, #7c3aed), var(--pink, #ec4899));
  color: var(--white, #ffffff);
}

/* モバイル対応 */
@media (max-width: 768px) {
  .lang-switch {
    padding: 6px 12px;
    font-size: 12px;
  }

  .lang-dropdown {
    min-width: 120px;
    right: -10px;
  }
}

/* 言語に応じたフォント調整 */
html[lang="zh"] body,
html[lang="ko"] body {
  font-family: 'Inter', -apple-system, 'Noto Sans SC', 'Noto Sans KR', sans-serif;
}

html[lang="en"] body {
  font-family: 'Inter', -apple-system, sans-serif;
}

/* RTL言語対応（将来的な拡張用） */
html[dir="rtl"] .lang-switch {
  flex-direction: row-reverse;
}

html[dir="rtl"] .lang-dropdown {
  right: auto;
  left: 0;
}
