/*
 * Android输入法修复样式
 * 用于解决Android设备上触发输入法时抽屉内容重绘导致失败的问题
 */

/* 保护状态下的抽屉样式 */
.mobile-drawer.input-protected {
  /* 添加视觉指示器，表明抽屉处于保护状态 */
  border-top: 2px solid var(--primary-color);
}

/* 保护状态下的搜索框样式 */
.mobile-drawer.input-protected .mobile-drawer-search {
  /* 添加视觉指示器，表明搜索框处于保护状态 */
  border-bottom: 1px solid var(--primary-color);
}

/* 保护遮罩样式 */
#drawer-protection-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  z-index: 1060;
  display: none;
}

/* Android设备特殊处理 */
.android-device .mobile-drawer-search .form-control:focus {
  /* 确保输入框获得焦点时不会触发重绘 */
  outline: none;
  box-shadow: 0 0 0 2px var(--primary-color);
}

/* Toast提示样式 */
#android-input-toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 8px 16px;
  border-radius: 20px;
  z-index: 9999;
  font-size: 14px;
  max-width: 80%;
  text-align: center;
  transition: opacity 0.3s ease;
  opacity: 0;
  pointer-events: none;
}

/* 深色模式下的Toast样式 */
.dark-mode #android-input-toast {
  background: rgba(255, 255, 255, 0.8);
  color: black;
}
