/* search.css - Specific styles for search.html page */

/* Modify header to accommodate search container */
.header {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  height: auto;
  min-height: 70px;
}

/* Hide the search container in its original location */
.main-container .search-container {
  display: none;
}

/* Create a new search container in the header */
.header .search-container {
  flex: 1;
  max-width: 600px;
  margin: 0 20px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.header .search-box-wrapper {
  width: 100%;
}

.header .search-box {
  width: 100%;
  display: flex;
  position: relative;
  height: 50px;
  border-radius:10px;
  background-color: #f5f5f5;
  overflow: hidden;
  transition: all 0.3s;
}

.header .search-input {
  flex: 1;
  height: 100%;
  border: none;
  padding: 0 15px;
  font-size: 14px;
  background: transparent;
  outline: none;
  border-radius: 10px !important;
  padding: 10px 110px 10px 10px;
}

/* 图片搜索按钮样式 - 与index.css保持一致 */
.header .image-search-button {
  position: absolute;
  right: 60px;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 8px; /* 改为方形带圆角 */
  background-color: #1e88e5;
  border: none;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 2;
  text-decoration: none;
}

.header .image-search-button:hover {
  background-color: #1565c0;
}

.header .image-search-button i {
  font-size: 20px;
}

/* 搜索按钮样式 */
.header .search-button {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--primary-color);
  border: none;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.header .search-button:hover {
  background-color: var(--primary-color-dark);
}

.header .search-button svg {
  width: 18px;
  height: 18px;
}

/* Adjust header-left and header-right to accommodate the search box */
.header .header-left {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
}

.header .header-right {
  flex: 0 0 auto;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .header {
    flex-direction: column;
    padding: 10px;
  }
  
  .header .search-container {
    margin: 10px 0;
    max-width: 100%;
  }
  
  .header .header-left,
  .header .header-right {
    width: 100%;
    justify-content: space-between;
  }
}

/* 分页器样式 */
.pagination-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 20px 0;
  padding: 15px 20px;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  flex-wrap: wrap;
  gap: 15px;
}

.pagination-info {
  display: flex;
  gap: 20px;
  color: #666;
  font-size: 14px;
}

.pagination-info span {
  display: flex;
  align-items: center;
  gap: 5px;
}

.pagination-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pagination-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid #ddd;
  background-color: #fff;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s;
  color: #666;
}

.pagination-btn:hover:not(:disabled) {
  border-color: var(--primary-color);
  color: var(--primary-color);
  background-color: rgba(21, 117, 64, 0.05);
}

.pagination-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pagination-btn i {
  font-size: 16px;
}

.pagination-numbers {
  display: flex;
  gap: 5px;
}

.pagination-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid #ddd;
  background-color: #fff;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s;
  color: #666;
  font-size: 14px;
}

.pagination-number:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
  background-color: rgba(21, 117, 64, 0.05);
}

.pagination-number.active {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
}

.pagination-jump {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #666;
  font-size: 14px;
}

.jump-input {
  width: 60px;
  height: 36px;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 0 8px;
  text-align: center;
  font-size: 14px;
  outline: none;
  transition: border-color 0.3s;
}

.jump-input:focus {
  border-color: var(--primary-color);
}

.jump-btn {
  padding: 8px 12px;
  border: 1px solid #ddd;
  background-color: #fff;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s;
  color: #666;
  font-size: 14px;
}

.jump-btn:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
  background-color: rgba(21, 117, 64, 0.05);
}

/* 分页器响应式设计 */
@media (max-width: 768px) {
  .pagination-container {
    flex-direction: column;
    gap: 15px;
  }
  
  .pagination-info {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }
  
  .pagination-controls {
    order: 2;
  }
  
  .pagination-jump {
    order: 3;
  }
}

/* 搜索高亮样式 */
.search-highlight {
  background: linear-gradient(135deg, #ff4757, #ff3742);
  color: white;
  padding: 1px 3px;
  border-radius: 3px;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(255, 71, 87, 0.3);
  animation: highlightPulse 1.5s ease-in-out infinite alternate;
}

@keyframes highlightPulse {
  0% {
    box-shadow: 0 1px 3px rgba(255, 71, 87, 0.3);
  }
  100% {
    box-shadow: 0 2px 6px rgba(255, 71, 87, 0.5);
  }
} 