/* Search Page Styles */

/* Search Section */
.search-section {
  margin-bottom: 3rem;
  padding: 2rem;
  background: #185fab1c;
  border: 1px solid #ddd;
  text-align: center;
}

.search-title {
  margin-bottom: 1rem;
  color: #333;
  font-size: 1.75rem;
  font-weight: 700;
}

.search-description {
  margin-bottom: 1.5rem;
  color: #666;
  line-height: 1.6;
  font-size: 1rem;
}

/* Search Bar */
.search-bar-wrapper {
  max-width: 600px;
  margin: 0 auto 1.5rem;
}

.search-bar {
  display: flex;
  align-items: center;
  width: 100%;
  background: #fff;
  border: 2px solid #ddd;
  border-radius: 8px;
  transition: border-color 0.2s;
}

.search-bar:focus-within,
.search-bar:hover {
  border-color: #007cba;
  outline: 0;
}

.search-bar .search-icon {
  margin-left: 1rem;
  color: #666;
  flex-shrink: 0;
}

.search-input {
  flex: 1;
  padding: 1rem 0.5rem;
  border: none;
  background: transparent;
  font-size: 1rem;
  color: #333;
  outline: 0;
}

.search-input::placeholder {
  color: #999;
}

.search-help {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: #666;
  line-height: 1.5;
}

/* Search Results Section */
.search-results-section {
  margin-top: 2rem;
  padding: 1.5rem;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.search-status {
  margin-bottom: 1rem;
  padding: 0.75rem;
  color: #ab183d;
  font-size: 1.4rem;
  font-weight: 600;
  text-align: left;
}

.search-results {
  display: block;
}

.search-results-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.search-result-item {
  border: 1px solid #e5e5e5;
  border-radius: 4px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-result-item:hover {
  border-color: #007cba;
  box-shadow: 0 2px 8px rgba(0, 124, 186, 0.1);
}

.search-result-link {
  display: block;
  padding: 1.25rem;
  text-decoration: none;
  color: inherit;
}

.search-result-title {
  margin-bottom: 1.4rem;
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.4;
  text-align: left;
  color: #333;
}

.search-result-meta {
  display: flex;
  gap: 1rem;
  align-items: center;
  font-size: 0.9rem;
}

.search-result-category {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: #daefff;
  color: #000;
  border-radius: 3px;
  font-weight: 500;
}

.search-result-date {
  color: #666;
}

/* Browse Tags */
.browse-tags {
  margin-bottom: 3rem;
}

.section-title {
  margin-bottom: 1.5rem;
  color: #333;
  font-size: 1.3rem;
  font-weight: 700;
  border-bottom: 1px solid #ddd;
  padding-bottom: 0.5rem;
}

.tags-grid {
  list-style-type: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0.75rem;
}

.tag-link {
  display: block;
  padding: 0.75rem 1rem;
  background: #f5f5f5;
  color: #333;
  border: 1px solid #ddd;
  font-weight: 500;
  text-decoration: none;
  text-align: center;
  transition: all 0.2s;
}

.tag-link:focus,
.tag-link:hover {
  background: #e9e9e9;
  color: #000;
  border-color: #bbb;
}

/* Featured Content */
.featured-content {
  margin-bottom: 3rem;
}

.featured-posts {
  list-style-type: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.featured-posts li {
  display: block;
  padding: 0;
  background: #fff;
  border: 1px solid #ddd;
  transition: border-color 0.2s;
}

.featured-posts li:hover {
  border-color: #bbb;
  background: #fafafa;
}

.featured-post {
  display: block;
  padding: 1rem;
  text-decoration: none;
  color: inherit;
}

.featured-post-content {
  width: 100%;
}

.featured-post-title {
  margin-bottom: 8px;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.3;
  color: #333;
}

.featured-post-meta {
  font-size: 0.95rem;
  color: #666;
}

/* Search Tips */
.search-tips {
  background: #f9f9f9;
  border: 1px solid #ddd;
  padding: 2rem;
  margin-bottom: 3rem;
}

.tips-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.tips-list li {
  padding: 0.75rem 0;
  border-bottom: 1px solid #eee;
  color: #555;
  font-size: 16px;
}

.tips-list li:last-child {
  border-bottom: none;
}

/* Responsive */
@media (max-width: 768px) {
  .search-section {
    padding: 1.5rem 1rem;
  }

  .search-title {
    font-size: 1.5rem;
  }

  .tags-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  }

  .featured-posts {
    grid-template-columns: 1fr;
  }

  .search-result-meta {
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start;
  }
}