/* WzSLinker 高亮样式 - 参考 Multi Find 实现 */

/* 基础高亮样式 - 只定义布局和交互，颜色由 JavaScript 动态设置 */
stock-highlight {
  cursor: pointer !important;
  display: inline !important;
  font-style: normal !important;
  transition: all 0.2s ease !important;
  border-radius: 3px !important;
  padding: 1px 2px !important;
}

/* 悬停效果 - 只调整透明度，保持用户设置的颜色 */
stock-highlight:hover {
  opacity: 0.8 !important;
  text-decoration: underline !important;
}

/* 表格中的股票高亮 */
.stock-table-highlight {
  background-color: rgba(255, 0, 0, 0.1) !important;
  border: 1px solid rgba(255, 0, 0, 0.3) !important;
}

/* 代码块中的股票高亮 */
.stock-code-highlight {
  background-color: rgba(255, 255, 0, 0.2) !important;
  border-left: 3px solid #ff0000 !important;
  padding-left: 5px !important;
}

/* 增强功能指示器 */
.wzslinker-enhanced-indicator {
  position: fixed;
  top: 10px;
  right: 10px;
  background: rgba(0, 255, 0, 0.8);
  color: white;
  padding: 5px 10px;
  border-radius: 5px;
  font-size: 12px;
  z-index: 1000000;
  display: none;
  animation: fadeInOut 3s ease-in-out;
}

@keyframes fadeInOut {
  0%, 100% { opacity: 0; }
  50% { opacity: 1; }
}

/* 防止样式冲突 */
stock-highlight * {
  color: inherit !important;
  background-color: inherit !important;
}

/* ==================== 价格指示器样式 ==================== */

/* 价格指示器基础样式 */
.stock-price-indicator {
  position: absolute !important;
  top: -7px !important;
  right: -12px !important;
  font-size: 10px !important;
  font-weight: bold !important;
  padding: 0 !important;
  margin: 0 !important;
  border: none !important;
  border-radius: 0 !important;
  white-space: nowrap !important;
  z-index: 2147483647 !important;
  cursor: default !important;
  background: none !important;
  background-color: transparent !important;
  box-shadow: none !important;
  transition: none !important;
  user-select: none !important;
  pointer-events: none !important;
  outline: none !important;
}

/* 加载中状态 */
.stock-price-indicator.loading {
  color: #999999 !important;
  background: none !important;
  background-color: transparent !important;
  animation: pulse 1.5s ease-in-out infinite;
}

/* 上涨状态 - 粉色 */
.stock-price-indicator.positive {
  color: #ff69b4 !important;
  background: none !important;
  background-color: transparent !important;
}

/* 下跌状态 - 绿色 */
.stock-price-indicator.negative {
  color: #00ff00 !important;
  background: none !important;
  background-color: transparent !important;
}

/* 平盘状态 - 灰色 */
.stock-price-indicator.neutral {
  color: #666666 !important;
  background: none !important;
  background-color: transparent !important;
}

/* 错误状态 */
.stock-price-indicator.error {
  color: #ff6b6b !important;
  background: none !important;
  background-color: transparent !important;
  cursor: default !important;
}

/* 悬停效果 - 已禁用（不可点击） */
/* .stock-price-indicator:hover 样式已移除 */

/* 脉冲动画 */
@keyframes pulse {
  0%, 100% { 
    opacity: 1; 
  }
  50% { 
    opacity: 0.5; 
  }
}

/* 确保stock-highlight元素可以作为定位容器 */
stock-highlight {
  position: relative !important;
  display: inline-block !important;
}