/* GIO NEWS — E-commerce News Hub 24/7 Stylesheet */
:root {
  --news-bg: #090414;
  --news-card-bg: rgba(26, 17, 46, 0.85);
  --news-border: rgba(139, 92, 246, 0.2);
  --news-primary: #ec4899;
  --news-cyan: #06b6d4;
}

.news-hub-container {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  background: var(--news-bg);
  color: #f8fafc;
  overflow-y: auto;
  padding: 16px 24px 60px 24px;
}

/* Breaking News Ticker */
.breaking-ticker-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(90deg, rgba(236, 72, 153, 0.2), rgba(139, 92, 246, 0.15));
  border: 1px solid rgba(236, 72, 153, 0.4);
  border-radius: 10px;
  padding: 8px 16px;
  margin-bottom: 20px;
}

.breaking-badge {
  background: #ef4444;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 6px;
  animation: flashBreaking 1.5s infinite;
}

@keyframes flashBreaking {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.ticker-text {
  flex: 1;
  font-size: 12px;
  font-weight: 700;
  color: #f1f5f9;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* News Controls */
.news-controls-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.news-topic-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.topic-filter-btn {
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--news-border);
  background: rgba(30, 20, 56, 0.6);
  color: #94a3b8;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.topic-filter-btn:hover {
  color: #fff;
  border-color: #a855f7;
}

.topic-filter-btn.active {
  background: linear-gradient(135deg, #7c3aed, #ec4899);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 0 12px rgba(236, 72, 153, 0.3);
}

.news-search-box {
  position: relative;
  min-width: 260px;
}

.news-search-input {
  width: 100%;
  padding: 8px 14px;
  border-radius: 8px;
  background: rgba(20, 13, 40, 0.8);
  border: 1px solid var(--news-border);
  color: #fff;
  font-size: 12px;
  outline: none;
}

/* News Grid Layout */
.news-grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 18px;
}

.news-card {
  background: var(--news-card-bg);
  border: 1px solid var(--news-border);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.news-card:hover {
  transform: translateY(-4px);
  border-color: rgba(236, 72, 153, 0.5);
  box-shadow: 0 8px 25px rgba(236, 72, 153, 0.2);
}

.news-card-thumb {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.news-card-body {
  padding: 14px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.news-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  font-size: 11px;
}

.news-source-tag {
  color: #38bdf8;
  font-weight: 800;
}

.news-time-tag {
  color: #94a3b8;
}

.news-card-title {
  font-size: 14px;
  font-weight: 800;
  color: #fff;
  line-height: 1.4;
  margin-bottom: 10px;
}

.news-ai-summary-box {
  background: rgba(139, 92, 246, 0.1);
  border-left: 3px solid #a855f7;
  padding: 8px 10px;
  border-radius: 4px;
  font-size: 11px;
  color: #cbd5e1;
  margin-bottom: 12px;
  line-height: 1.4;
}

.news-tags-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: auto;
}

.news-tag-badge {
  font-size: 10px;
  font-weight: 700;
  color: #ec4899;
  background: rgba(236, 72, 153, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
}

/* ==========================================================================
   MOBILE & TABLET RESPONSIVE STYLING (News Hub 100% Mobile Fluid)
   ========================================================================== */

@media (max-width: 768px) {
  .news-hub-container {
    padding: 12px 12px 60px 12px;
  }
  .breaking-ticker-bar {
    padding: 6px 12px;
    margin-bottom: 14px;
  }
  .news-controls-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    margin-bottom: 16px;
  }
  .news-topic-filters {
    overflow-x: auto;
    white-space: nowrap;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    gap: 6px;
  }
  .topic-filter-btn {
    flex-shrink: 0;
    font-size: 11px;
    padding: 5px 12px;
  }
  .news-search-box {
    width: 100%;
    min-width: unset;
  }
  .news-grid-cards {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .news-card-thumb {
    height: 140px;
  }
  .news-card-title {
    font-size: 13px;
  }
}

/* Aff TikTok 14/11: thẻ tin là link mở bài gốc */
a.news-card { display: block; text-decoration: none; color: inherit; }
a.news-card:hover .news-card-title { text-decoration: underline; }
