* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Microsoft JhengHei', 'SF Pro Display', -apple-system, BlinkMacSystemFont, sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  padding: 20px;
}

.main-container {
  max-width: 1200px;
  margin: 0 auto;
}

.header {
  text-align: center;
  margin-bottom: 40px;
  color: white;
}

.header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 10px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.header p {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 30px;
}

.search-container {
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 30px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
  margin-bottom: 30px;
}

.search-box {
  display: flex;
  gap: 15px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.search-input {
  flex: 1;
  min-width: 300px;
  max-width: 400px;
  padding: 15px 20px;
  border: 2px solid #e1e5e9;
  border-radius: 12px;
  font-size: 16px;
  transition: all 0.3s ease;
  background: white;
}

.search-input:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 3px rgba(0,123,255,0.1);
}

.btn {
  background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
  color: white;
  border: none;
  padding: 15px 30px;
  border-radius: 12px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0,123,255,0.3);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,123,255,0.4);
}

.btn:active {
  transform: translateY(0);
}

.loading {
  text-align: center;
  color: #007bff;
  font-size: 18px;
  padding: 40px;
  background: rgba(255,255,255,0.95);
  border-radius: 15px;
  backdrop-filter: blur(20px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.loading::after {
  content: '';
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid #007bff;
  border-radius: 50%;
  border-top-color: transparent;
  animation: spin 1s ease-in-out infinite;
  margin-left: 10px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.results-container {
  display: grid;
  gap: 20px;
  margin-top: 30px;
}

.content-item {
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(20px);
  border: none;
  border-radius: 20px;
  padding: 25px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.content-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #007bff, #28a745, #ffc107, #dc3545, #6f42c1);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.content-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}

.content-item:hover::before {
  opacity: 1;
}

.platform-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 25px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 15px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.platform-xiaohongshu { background: linear-gradient(135deg, #ff2442 0%, #ff6b6b 100%); color: white; }
.platform-douyin { background: linear-gradient(135deg, #000000 0%, #333333 100%); color: white; }
.platform-youtube { background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%); color: white; }
.platform-instagram { background: linear-gradient(135deg, #833ab4 0%, #fd1d1d 50%, #fcb045 100%); color: white; }
.platform-facebook { background: linear-gradient(135deg, #1877f2 0%, #42a5f5 100%); color: white; }
.platform-google { background: linear-gradient(135deg, #4285f4 0%, #34a853 50%, #fbbc05 75%, #ea4335 100%); color: white; }
.platform-rss { background: linear-gradient(135deg, #ff6600 0%, #ff9900 100%); color: white; }
.platform-ai { background: linear-gradient(135deg, #8a2be2 0%, #9370db 100%); color: white; }
.platform-default { background: linear-gradient(135deg, #6c757d 0%, #495057 100%); color: white; }

.content-title {
  font-size: 20px;
  font-weight: 700;
  margin: 15px 0;
  color: #2c3e50;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.content-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #6c757d;
  font-size: 14px;
  margin: 12px 0;
  font-weight: 500;
}

.author-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, #007bff, #28a745);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 12px;
  font-weight: bold;
}

.content-description {
  color: #495057;
  font-size: 15px;
  line-height: 1.7;
  margin: 20px 0;
  padding: 20px;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: 12px;
  white-space: pre-line;
  max-height: 350px;
  overflow-y: auto;
  border-left: 4px solid #007bff;
  position: relative;
}

.content-description::-webkit-scrollbar {
  width: 6px;
}

.content-description::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.content-description::-webkit-scrollbar-thumb {
  background: #007bff;
  border-radius: 3px;
}

.stats {
  display: flex;
  gap: 15px;
  margin-top: 20px;
  flex-wrap: wrap;
  align-items: center;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #6c757d;
  font-size: 14px;
  background: rgba(0,123,255,0.1);
  padding: 8px 12px;
  border-radius: 20px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.stat-item:hover {
  background: rgba(0,123,255,0.2);
  transform: scale(1.05);
}

.publish-time {
  color: #adb5bd;
  font-size: 13px;
  margin-top: 15px;
  display: flex;
  align-items: center;
  gap: 5px;
  font-weight: 500;
}

.no-results {
  text-align: center;
  color: #6c757d;
  font-size: 18px;
  padding: 60px 40px;
  background: rgba(255,255,255,0.95);
  border-radius: 20px;
  backdrop-filter: blur(20px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
}

.theme-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  background: rgba(255,255,255,0.2);
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  cursor: pointer;
  color: white;
  font-size: 20px;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.theme-toggle:hover {
  background: rgba(255,255,255,0.3);
  transform: scale(1.1);
}

@media (max-width: 768px) {
  .main-container { padding: 10px; }
  .header h1 { font-size: 2rem; }
  .search-box { flex-direction: column; }
  .search-input { min-width: 100%; }
  .content-item { padding: 20px; }
  .stats { gap: 10px; }
}
