/**
 * 搜索功能增强样式
 */

/* 搜索增强功能样式 */

/* 热门搜索标签样式 */
.hot-search-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.search-tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 4px;
  color: #495057;
  text-decoration: none;
  font-size: 12px;
  transition: all 0.2s ease;
  line-height: 1.2;
}

.search-tag:hover {
  background: #e9ecef;
  border-color: #dee2e6;
  color: #212529;
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.search-tag .count {
  margin-left: 4px;
  color: #6c757d;
  font-size: 11px;
  font-weight: 500;
}

/* 无搜索记录提示 */
.no-searches {
  color: #6c757d;
  font-style: italic;
  text-align: center;
  padding: 20px 0;
  margin: 0;
}

/* 头部热门搜索样式 */
.hot-search {
  margin-top: 10px;
  font-size: 13px;
  color: #666;
}

.hot-search span {
  margin-right: 8px;
  font-weight: 500;
}

.hot-search a {
  display: inline-block;
  margin-right: 8px;
  color: #ff6b35;
  text-decoration: none;
  transition: color 0.2s ease;
}

.hot-search a:hover {
  color: #e55a2b;
  text-decoration: underline;
}

/* 搜索建议样式 */
.search-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 1px solid #e0e0e0;
  border-top: none;
  border-radius: 0 0 8px 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  z-index: 1000;
  max-height: 300px;
  overflow-y: auto;
}

.search-suggestion-item {
  padding: 10px 15px;
  border-bottom: 1px solid #f0f0f0;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.search-suggestion-item:last-child {
  border-bottom: none;
}

.search-suggestion-item:hover {
  background-color: #f8f9fa;
}

.search-suggestion-item .title {
  font-weight: 500;
  color: #333;
  margin-bottom: 2px;
}

.search-suggestion-item .excerpt {
  font-size: 12px;
  color: #666;
  line-height: 1.3;
}

/* 搜索高亮样式 */
.search-highlight {
  background-color: #fff3cd;
  padding: 1px 2px;
  border-radius: 2px;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .hot-search-tags {
    gap: 6px;
  }
  
  .search-tag {
    padding: 3px 6px;
    font-size: 11px;
  }
  
  .hot-search {
    font-size: 12px;
  }
  
  .hot-search a {
    margin-right: 6px;
  }
}

/* 搜索表单优化 */
.search-form {
    position: relative;
}

.search-form.has-suggestions .form-control {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}