/*
 * Copyright © 2025 JQIT. All rights reserved.
 */

/* パスワード関連 */
.password-wrapper {
  position: relative;
  width: 100%;
}

.password-wrapper .form-control,
.password-wrapper input[type="password"] {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 40px 10px 12px;
  font-size: 16px;
  line-height: 1.2;
}

.toggle-password {
  position: absolute;
  top: 0;
  right: 8px;
  bottom: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  cursor: pointer;
}

.toggle-password .icon {
  width: 20px;
  height: 20px;
  display: block;
  opacity: 0.8;
  transition: opacity .15s ease;
}

.toggle-password:hover .icon {
  opacity: 1;
}

/* サイドバー */
#sidebar {
  background-color: #5BADF0;
}

/* サイドバーのリンク全体 */
.sidebar-link {
  color: white; /* 通常の文字色 */
  text-decoration: none;
  transition: color 0.2s ease, background-color 0.2s ease;
}

/* ホバー時 */
.sidebar-link:hover {
  background-color: #138CF0;
  color: #ffffff;
}

/* 現在ページを強調表示 */
.sidebar-link.active {
  color: #003366;
  font-weight: bold;
}

#closeSidebarBtn {
  color: #D1D5DB;
}

#closeSidebarBtn:hover {
  background-color: #138CF0;
  color: #ffffff;
}

/* サイドバー背景オーバーレイ（モバイル用） */
.sidebar-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 15; /* サイドバー(z-20)の背面 */
  transition: opacity 0.3s ease;
}

.sidebar-overlay.hidden {
  display: none;
}

/* ===============================================
   モバイル: レイアウト修正
   =============================================== */
@media (max-width: 768px) {
  /* mainをフレックス内で確実にスクロール可能にする */
  #mainContent > main {
    flex: 1 1 0%;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6rem;
  }
}
