/* 搜索弹窗分类标签横向布局优化 */
.search-modal .modal-dialog {
  max-width: 900px;
  margin: 1rem auto;
}

.search-modal .modal-content {
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  border: none;
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.search-modal .modal-body {
  padding: 2.5rem;
  position: relative;
}

/* 搜索框样式优化 */
.search-modal .super-search-fm {
  position: relative;
  margin-bottom: 2rem;
}

.search-modal #m_search-text {
  width: 100%;
  height: 65px;
  border-radius: 16px;
  border: 2px solid rgba(126, 126, 126, 0.15);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  padding: 0 1.5rem;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

.search-modal #m_search-text:focus {
  border-color: #f1404b;
  box-shadow: 0 0 0 3px rgba(241, 64, 75, 0.15), 0 12px 30px rgba(0, 0, 0, 0.12);
  background: rgba(255, 255, 255, 1);
  transform: translateY(-2px);
}

.search-modal .super-search-fm button {
  position: absolute;
  right: 8px;
  top: 8px;
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: linear-gradient(135deg, #f1404b 0%, #f1417c 100%);
  border: none;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(241, 64, 75, 0.3);
}

.search-modal .super-search-fm button:hover {
  background: linear-gradient(135deg, #e03545 0%, #e13670 100%);
  transform: scale(1.05) translateY(-2px);
  box-shadow: 0 6px 20px rgba(241, 64, 75, 0.4);
}

/* 分类标签横向布局优化 - 完全重写 */
.search-modal #search-list {
  position: relative;
  margin-bottom: 2rem;
}

/* 移除原来的竖排样式 */
.search-modal .s-type {
  position: static;
  width: 100%;
}

.search-modal .s-type > span {
  display: none;
}

.search-modal .s-type-list {
  display: flex !important;
  position: static !important;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  padding: 0;
  margin: 0;
  width: 100%;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 0;
}

.search-modal .s-type-list:before {
  display: none;
}

.search-modal .s-type-list label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 25px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.4s ease;
  border: 2px solid transparent;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  position: relative;
  overflow: hidden;
  min-width: 80px;
  text-align: center;
}

.search-modal .s-type-list label::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
  transition: left 0.5s ease;
}

.search-modal .s-type-list label:hover::before {
  left: 100%;
}

.search-modal .s-type-list label:hover {
  background: rgba(255, 255, 255, 0.95);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border-color: rgba(241, 64, 75, 0.2);
}

.search-modal .s-type-list label.active {
  background: linear-gradient(135deg, #f1404b 0%, #f1417c 100%);
  color: white;
  border-color: #f1404b;
  box-shadow: 0 8px 25px rgba(241, 64, 75, 0.3);
  transform: translateY(-2px);
}

/* 搜索引擎选项样式优化 */
.search-modal .search-group {
  margin-top: 1.5rem;
  padding: 0;
  animation: fadeInUp 0.5s ease;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.search-modal .type-text {
  display: none;
}

.search-modal .search-type {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 15px;
  margin: 0;
  padding: 0;
}

.search-modal .search-type li {
  list-style: none;
  margin: 0;
}

.search-modal .search-type label {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 12px;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
  min-height: 60px;
}

.search-modal .search-type label:hover {
  background: rgba(255, 255, 255, 0.95);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
  border-color: rgba(241, 64, 75, 0.2);
}

.search-modal .search-type input:checked + label {
  background: linear-gradient(135deg, #f1404b 0%, #f1417c 100%);
  color: white;
  border-color: #f1404b;
  box-shadow: 0 8px 25px rgba(241, 64, 75, 0.3);
  transform: translateY(-2px);
}

/* 关闭按钮样式优化 */
.search-modal .icon-close-circle {
  color: rgba(255, 255, 255, 0.9) !important;
  transition: all 0.3s ease;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.search-modal .icon-close-circle:hover {
  color: white !important;
  transform: scale(1.15) rotate(90deg);
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.4));
}

/* 响应式优化 */
@media (max-width: 768px) {
  .search-modal .modal-dialog {
    margin: 0.5rem;
    max-width: calc(100vw - 1rem);
  }
  
  .search-modal .modal-body {
    padding: 1.5rem 1rem;
  }
  
  .search-modal #m_search-text {
    height: 55px;
    padding: 0 1rem;
    font-size: 1rem;
  }
  
  .search-modal .super-search-fm button {
    width: 42px;
    height: 42px;
    top: 6px;
    right: 6px;
  }
  
  .search-modal .s-type-list label {
    padding: 10px 16px;
    font-size: 0.85rem;
    min-width: 70px;
  }
  
  .search-modal .search-type {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
  }
  
  .search-modal .search-type label {
    padding: 12px 15px;
    min-height: 50px;
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .search-modal .s-type-list {
    gap: 6px;
  }
  
  .search-modal .s-type-list label {
    padding: 8px 12px;
    font-size: 0.8rem;
    min-width: 60px;
  }
  
  .search-modal .search-type {
    grid-template-columns: 1fr;
  }
}

/* 暗色模式适配 */
.io-black-mode .search-modal .modal-content {
  background: linear-gradient(135deg, #2c2e2f 0%, #1b1d1f 100%);
}

.io-black-mode .search-modal #m_search-text {
  background: rgba(54, 55, 56, 0.9);
  border-color: rgba(126, 126, 126, 0.3);
  color: #c6c9cf;
}

.io-black-mode .search-modal #m_search-text:focus {
  background: rgba(54, 55, 56, 1);
}

.io-black-mode .search-modal .s-type-list label,
.io-black-mode .search-modal .search-type label {
  background: rgba(54, 55, 56, 0.8);
  color: #c6c9cf;
}

.io-black-mode .search-modal .s-type-list label:hover,
.io-black-mode .search-modal .search-type label:hover {
  background: rgba(54, 55, 56, 0.9);
}

.io-black-mode .search-modal .s-type-list label.active {
  background: linear-gradient(135deg, #f1404b 0%, #f1417c 100%);
  color: white;
}