/* Sticky navigation styles */
#headernav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
  margin-bottom: 2rem;
}

.navbar {
  padding: 0.5rem 0;
}

.nav-link {
  padding: 0.75rem 1rem !important;
  border-radius: 8px;
  transition: all 0.3s ease !important;
  margin: 0 0.25rem;
  position: relative;
  color: #212529 !important;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  line-height: 1.2;
  min-width: 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: #fd7e14;
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.nav-link:hover::after {
  width: calc(100% - 2rem);
}

.nav-link:hover {
  color: #fd7e14 !important;
  transform: translateY(-2px);
}

.nav-link.active {
  background: linear-gradient(135deg, #fd7e14 0%, #ff922b 100%) !important;
  color: white !important;
  box-shadow: none;
}

.nav-link.active::after {
  display: none;
}

.nav-link i {
  margin-right: 0.375rem;
  transition: transform 0.3s ease;
  font-size: 0.9rem;
  min-width: 1rem;
  text-align: center;
  flex-shrink: 0;
}

.nav-link:hover i {
  transform: scale(1.1);
}

.nav-text {
  position: relative;
  z-index: 1;
  white-space: nowrap;
  font-size: 0.9rem;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.navbar-nav {
  width: 100%;
  justify-content: center;
  gap: 0.125rem;
  position: relative;
}

.navbar-nav .nav-item {
  margin: 0;
  position: relative;
  z-index: 2;
}

/* モバイル用フッターナビゲーション - デフォルト非表示（PC時） */
.mobile-nav {
  display: none;
}

/* スライドインジケーター */
.nav-slider-indicator {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  height: calc(100% - 8px);
  background: linear-gradient(135deg, #fd7e14 0%, #ff922b 100%);
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  z-index: 1;
  transition: left 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              width 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              opacity 0.2s ease;
  /* フレックスレイアウトから除外 */
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-slider-indicator.visible {
  opacity: 1;
}

/* ホバー時のスタイル調整（スライダー使用時） */
.navbar-nav.has-slider .nav-link {
  background: transparent !important;
  color: #212529 !important;
  transition: color 0.25s ease !important;
}

.navbar-nav.has-slider .nav-link.nav-hover-active {
  color: white !important;
}

.navbar-nav.has-slider .nav-link:hover {
  transform: none;
}

.navbar-nav.has-slider .nav-link.active:not(.nav-hover-active) {
  background: transparent !important;
  color: #212529 !important;
  box-shadow: none;
}

.navbar-nav.has-slider .nav-link:hover i,
.navbar-nav.has-slider .nav-link.active i {
  transform: none;
}

.navbar-nav.has-slider .nav-link::after {
  display: none;
}

@media (max-width: 991px) {
  #headernav {
    background: none;
    box-shadow: none;
  }

  .navbar {
    padding: 0;
  }

  .container-fluid {
    padding: 0;
  }

  /* モバイル用フッターナビゲーション */
  .mobile-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #ffffff;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    z-index: 1050;
    padding: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .mobile-nav-btn {
    border: none;
    background: none;
    padding: 0.5rem;
    color: #6c757d;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    transition: color 0.3s ease;
    text-decoration: none;
    flex: 1;
  }

  .mobile-nav-btn i {
    font-size: 1.25rem;
    margin-bottom: 0.125rem;
  }

  .mobile-nav-btn.active {
    color: #fd7e14;
    font-weight: 600;
  }

  /* メインコンテンツのパディング調整 */
  main {
    padding-bottom: 4rem;
  }
}

@media (max-width: 576px) {
  .mobile-nav {
    padding: 0.375rem;
  }

  .mobile-nav-btn {
    padding: 0.375rem;
    font-size: 0.7rem;
  }

  .mobile-nav-btn i {
    font-size: 1.125rem;
  }
}

@media (max-width: 360px) {
  .mobile-nav {
    padding: 0.25rem;
  }

  .mobile-nav-btn {
    padding: 0.25rem;
    font-size: 0.65rem;
  }

  .mobile-nav-btn i {
    font-size: 1rem;
  }
} 