/**
 * Avcı Boya - Ürün & Kod Arama Stilleri
 */

/* ==========================================================================
   1. Live Search Dropdown & Header Tags (Inside Header Search Popup)
   ========================================================================== */

.search-quick-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  position: relative;
  z-index: 2;
}

.search-quick-tags .tags-label {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  font-weight: 500;
}

.search-tag-pill {
  display: inline-block;
  padding: 4px 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.25s ease;
}

.search-tag-pill:hover {
  background: #f14c52;
  border-color: #f14c52;
  color: #fff;
  transform: translateY(-1px);
}

.search-tag-pill--accent {
  background: rgba(241, 76, 82, 0.2);
  border-color: rgba(241, 76, 82, 0.4);
  color: #ff8e93;
}

.search-live-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  margin-top: 16px;
  background: #181d28;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.55);
  z-index: 999;
  max-height: 480px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #f14c52 #181d28;
}

.search-live-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.2);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #94a3b8;
  font-weight: 600;
}

.search-live-count {
  color: #f14c52;
}

.search-live-list {
  padding: 8px 0;
}

.search-live-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 22px;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  transition: background 0.18s ease;
}

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

.search-live-item:hover,
.search-live-item.active {
  background: rgba(241, 76, 82, 0.15);
}

.search-live-thumb {
  width: 52px;
  height: 52px;
  border-radius: 8px;
  background: #ffffff;
  padding: 3px;
  object-fit: contain;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}

.search-live-color-swatch {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.search-live-content {
  flex-grow: 1;
  min-width: 0;
}

.search-live-name {
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-live-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-live-brand-badge {
  display: inline-block;
  padding: 2px 8px;
  background: rgba(241, 76, 82, 0.25);
  color: #ff9ca0;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
}

.search-live-footer {
  padding: 12px 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.28);
  text-align: center;
}

.search-live-all-btn {
  color: #f14c52;
  font-weight: 600;
  font-size: 13px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: color 0.2s;
}

.search-live-all-btn:hover {
  color: #ff6b71;
}

.search-live-empty {
  padding: 24px 20px;
  text-align: center;
  color: #94a3b8;
  font-size: 14px;
}

/* ==========================================================================
   2. Dedicated Search Results Page (arama.php)
   ========================================================================== */

.search-page-section {
  background-color: #f8fafc;
  min-height: 600px;
}

.search-page-bar-wrap {
  background: #ffffff;
  padding: 30px 35px;
  border-radius: 20px;
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.05);
  border: 1px solid #eef2f6;
}

.search-page-input-group {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.search-page-input-group .search-page-icon {
  position: absolute !important;
  left: 22px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  font-size: 20px !important;
  line-height: 1 !important;
  color: #94a3b8 !important;
  pointer-events: none !important;
  z-index: 5 !important;
}

.search-page-input-group input.search-page-field,
input.search-page-field {
  width: 100% !important;
  height: 60px !important;
  padding-left: 60px !important;
  padding-right: 155px !important;
  padding-top: 10px !important;
  padding-bottom: 10px !important;
  font-size: 16px !important;
  line-height: 1.5 !important;
  border: 2px solid #e2e8f0 !important;
  border-radius: 14px !important;
  background: #f8fafc !important;
  color: #1e293b !important;
  outline: none !important;
  box-shadow: none !important;
  transition: all 0.25s ease !important;
}

.search-page-input-group input.search-page-field:focus,
input.search-page-field:focus {
  border-color: #f14c52 !important;
  background: #ffffff !important;
  box-shadow: 0 0 0 4px rgba(241, 76, 82, 0.12) !important;
}

.search-page-input-group .search-page-clear {
  position: absolute !important;
  right: 145px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  background: none !important;
  border: none !important;
  color: #94a3b8 !important;
  font-size: 18px !important;
  cursor: pointer !important;
  padding: 8px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  z-index: 5 !important;
  transition: color 0.2s !important;
}

.search-page-input-group .search-page-clear:hover {
  color: #f14c52 !important;
}

.search-page-input-group .search-page-submit-btn {
  position: absolute !important;
  right: 8px !important;
  top: 8px !important;
  bottom: 8px !important;
  background: #f14c52 !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 10px !important;
  padding: 0 24px !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  cursor: pointer !important;
  z-index: 5 !important;
  transition: all 0.25s ease !important;
}

.search-page-input-group .search-page-submit-btn:hover {
  background: #d9383e !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 6px 16px rgba(241, 76, 82, 0.35) !important;
}

.search-page-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.search-page-tags .tags-label {
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
}

.search-page-tag {
  display: inline-block;
  padding: 5px 14px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 50px;
  color: #475569;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
}

.search-page-tag:hover,
.search-page-tag.active {
  background: #f14c52;
  border-color: #f14c52;
  color: #ffffff;
}

.search-page-tag--color {
  background: #fef2f2;
  border-color: #fecaca;
  color: #b91c1c;
}

/* Results Meta Bar */
.search-results-meta {
  padding: 16px 24px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
  border: 1px solid #eef2f6;
}

.search-results-summary {
  font-size: 15px;
  color: #334155;
}

.search-query-badge {
  display: inline-block;
  padding: 2px 10px;
  background: #fee2e2;
  color: #b91c1c;
  border-radius: 6px;
  font-weight: 600;
}

.search-brand-tabs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.search-brand-pill {
  padding: 5px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 50px;
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.search-brand-pill:hover,
.search-brand-pill.active {
  background: #1e293b;
  border-color: #1e293b;
  color: #ffffff;
}

/* Product Search Cards */
.search-product-card {
  background: #ffffff;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid #eef2f6;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  transition: all 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.search-product-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.09);
  border-color: #fecdd3;
}

.search-product-thumb-wrap {
  position: relative;
  background: #f8fafc;
  padding: 24px;
  text-align: center;
  overflow: hidden;
  height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.search-product-thumb-wrap img {
  max-width: 100%;
  max-height: 170px;
  object-fit: contain;
  transition: transform 0.35s ease;
}

.search-product-card:hover .search-product-thumb-wrap img {
  transform: scale(1.08);
}

.search-zoom-overlay {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  font-size: 14px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.25s ease;
}

.search-product-card:hover .search-zoom-overlay {
  opacity: 1;
  transform: scale(1);
}

.search-brand-badge {
  position: absolute;
  bottom: 12px;
  left: 14px;
  background: #f14c52;
  color: #ffffff;
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.search-product-info {
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.search-product-category {
  font-size: 12px;
  color: #64748b;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
}

.search-product-title {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.45;
  margin-bottom: 18px;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.search-product-actions {
  margin-top: auto;
}

.btn-catalog-view {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 10px 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  color: #0f172a;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-catalog-view:hover {
  background: #f14c52;
  border-color: #f14c52;
  color: #ffffff;
}

.btn-catalog-view i {
  font-size: 12px;
  transition: transform 0.2s ease;
}

.btn-catalog-view:hover i {
  transform: translateX(4px);
}

/* NCS Color Cards in Search */
.search-ncs-card {
  background: #ffffff;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  text-align: center;
  transition: all 0.25s ease;
}

.search-ncs-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
}

.search-ncs-color {
  height: 80px;
  width: 100%;
}

.search-ncs-body {
  padding: 10px 12px;
}

.search-ncs-code {
  display: block;
  font-size: 13px;
  color: #0f172a;
  margin-bottom: 2px;
}

.search-ncs-hex {
  display: block;
  font-size: 11px;
  color: #94a3b8;
  font-family: monospace;
}

/* Highlighting */
mark.search-highlight {
  background: #fef08a;
  color: #854d0e;
  padding: 1px 4px;
  border-radius: 3px;
  font-weight: 700;
}

/* Initial and Empty States */
.search-category-tile {
  display: block;
  background: #ffffff;
  padding: 30px 24px;
  border-radius: 18px;
  border: 1px solid #eef2f6;
  text-align: center;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.04);
}

.search-category-tile:hover {
  transform: translateY(-6px);
  border-color: #f14c52;
  box-shadow: 0 16px 36px rgba(241, 76, 82, 0.12);
}

.search-category-tile .tile-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  background: #fef2f2;
  border-radius: 50%;
  font-size: 24px;
  margin-bottom: 16px;
}

.search-category-tile h6 {
  color: #0f172a;
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
}

.empty-icon-wrap i {
  font-size: 72px;
  color: #cbd5e1;
}

@media (max-width: 767px) {
  .search-page-bar-wrap {
    padding: 20px 16px;
  }
  .search-page-input-group .search-page-icon {
    left: 16px !important;
    font-size: 18px !important;
  }
  .search-page-input-group input.search-page-field,
  input.search-page-field {
    height: 52px !important;
    padding-left: 48px !important;
    padding-right: 110px !important;
    font-size: 14px !important;
  }
  .search-page-input-group .search-page-clear {
    right: 92px !important;
    font-size: 16px !important;
    padding: 6px !important;
  }
  .search-page-input-group .search-page-submit-btn {
    padding: 0 16px !important;
    font-size: 13px !important;
  }
  .search-brand-tabs {
    justify-content: flex-start !important;
  }
}
