/* DUDI Software - Blog page styles */

* {
  -webkit-tap-highlight-color: transparent;
  box-sizing: border-box;
}

/* ─── Hero ─── */
.blog-hero {
  padding: 100px 24px 48px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.blog-hero .status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 24px;
}

[data-theme="light"] .blog-hero .status-pill {
  border-color: rgba(0, 0, 0, 0.12);
  background: rgba(0, 0, 0, 0.04);
  color: rgba(0, 0, 0, 0.5);
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ade80;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.6;
    transform: scale(0.85);
  }
}

.blog-hero-title {
  font-size: clamp(2.2rem, 6vw, 4.5rem);
  font-weight: 900;
  color: #fbfbfb;
  font-family: 'Space Grotesk', sans-serif;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

[data-theme="light"] .blog-hero-title {
  color: #14141c;
}

.blog-hero-title .gradient-word {
  background: linear-gradient(135deg, #ED1C24, #1E90FF);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  padding-bottom: 0.1em;
  display: inline-block;
}

.blog-hero-sub {
  color: rgba(255, 255, 255, 0.5);
  font-size: 1rem;
  max-width: 480px;
  margin: 0 auto 36px;
  line-height: 1.6;
}

[data-theme="light"] .blog-hero-sub {
  color: rgba(0, 0, 0, 0.55);
}

/* Hero entrance */
.hero-anim {
  opacity: 0;
  transform: translateY(20px);
  will-change: opacity, transform;
  transition: opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1) var(--delay, 0s),
    transform 0.65s cubic-bezier(0.22, 1, 0.36, 1) var(--delay, 0s);
}

.hero-anim.revealed {
  opacity: 1;
  transform: translateY(0);
}

.hero-anim:not(.revealed) {
  transition-delay: 0s !important;
}

/* Robot image — absolute, pinned to bottom-left of hero */
.hero-side-img {
  position: absolute;
  left: 280px;
  bottom: 0;
  height: 100%;
  width: auto;
  object-fit: contain;
  mix-blend-mode: normal;
  pointer-events: none;
  user-select: none;
  z-index: 1;
  opacity: 0;
  transform: translateX(-50px);
  will-change: opacity, transform;
  transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.1s,
    transform 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.1s;
}

.hero-side-img.revealed {
  opacity: 1;
  transform: translateX(0);
}

.hero-side-img:not(.revealed) {
  transition-delay: 0s !important;
}

[data-theme="light"] .hero-side-img {
  mix-blend-mode: multiply;
}

/* Robot right image — absolute, pinned to bottom-right of hero */
.hero-side-img-right {
  position: absolute;
  right: 160px;
  bottom: 0;
  height: 110%;
  width: auto;
  object-fit: contain;
  mix-blend-mode: normal;
  pointer-events: none;
  user-select: none;
  z-index: 1;
  opacity: 0;
  transform: translateX(50px);
  will-change: opacity, transform;
  transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.2s,
    transform 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.2s;
}

.hero-side-img-right.revealed {
  opacity: 1;
  transform: translateX(0);
}

.hero-side-img-right:not(.revealed) {
  transition-delay: 0s !important;
}

[data-theme="light"] .hero-side-img-right {
  mix-blend-mode: normal;
  height: 55%;
  bottom: 0;
  top: auto;
  right: 160px;
  left: auto;
}

@media (max-width: 1680px) {
  .hero-side-img {
    height: 70% !important;
    left: 120px !important;
  }
  .hero-side-img-right {
    height: 70% !important;
    right: 60px !important;
  }
  [data-theme="light"] .hero-side-img-right {
    height: 45% !important;
    right: 60px !important;
  }
}

@media (max-width: 1300px) {
  .hero-side-img {
    height: 55% !important;
    left: 60px !important;
  }
  .hero-side-img-right {
    height: 55% !important;
    right: 30px !important;
  }
  [data-theme="light"] .hero-side-img-right {
    height: 35% !important;
    right: 30px !important;
  }
}

@media (max-width: 1024px) {
  .hero-side-img-right {
    height: 60%;
    right: 16px;
  }

  .hero-side-img {
    height: 60%;
    left: 16px;
  }
}

@media (max-width: 977px) {
  .hero-side-img,
  .hero-side-img-right {
    display: none !important;
  }
}

@media (max-width: 768px) {

  .hero-side-img,
  .hero-side-img-right {
    display: none;
  }
}

/* Đẩy content của hero lên trên ảnh robot */
.blog-hero .status-pill,
.blog-hero-title,
.blog-hero-sub,
.blog-filter-wrap {
  position: relative;
  z-index: 2;
}

/* ─── Category Filter Bar ─── */
.blog-filter-wrap {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 0;
  position: relative;
  z-index: 2;
}

.blog-filter-chip {
  padding: 6px 16px;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: 'Manrope', sans-serif;
  white-space: nowrap;
}

.blog-filter-chip:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fbfbfb;
  border-color: rgba(255, 255, 255, 0.2);
}

.blog-filter-chip.active {
  background: rgba(30, 144, 255, 0.12);
  border: 1px solid rgba(30, 144, 255, 0.4);
  color: #ffffff;
  box-shadow: 0 0 15px rgba(30, 144, 255, 0.25);
}

[data-theme="light"] .blog-filter-chip {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.1);
  color: rgba(0, 0, 0, 0.6);
}

[data-theme="light"] .blog-filter-chip:hover {
  background: rgba(0, 0, 0, 0.07);
  color: #14141c;
}

[data-theme="light"] .blog-filter-chip.active {
  background: rgba(30, 144, 255, 0.08);
  border-color: rgba(30, 144, 255, 0.35);
  color: #1E90FF;
}

/* ─── Main ─── */
.blog-main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 40px 24px 80px;
}

/* Section bar */
.section-bar {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 28px;
  gap: 12px;
  flex-wrap: wrap;
}

.section-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fbfbfb;
  font-family: 'Space Grotesk', sans-serif;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-title svg {
  width: 20px;
  height: 20px;
  color: inherit;
  flex-shrink: 0;
}

[data-theme="light"] .section-title {
  color: #14141c;
}

.section-sub {
  color: rgba(255, 255, 255, 0.35);
  font-size: 0.78rem;
  margin-top: 3px;
}

[data-theme="light"] .section-sub {
  color: rgba(0, 0, 0, 0.45);
}

.data-badge {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.05);
  padding: 6px 12px;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  white-space: nowrap;
}

[data-theme="light"] .data-badge {
  color: rgba(0, 0, 0, 0.4);
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.08);
}

/* ─── Search Bar ─── */
.blog-search-wrap {
  position: relative;
  max-width: 400px;
  width: 100%;
}

.blog-search-wrap svg {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 15px;
  height: 15px;
  color: rgba(255, 255, 255, 0.3);
}

[data-theme="light"] .blog-search-wrap svg {
  color: rgba(0, 0, 0, 0.35);
}

.blog-search-wrap input {
  width: 100%;
  padding: 9px 16px 9px 40px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 40px;
  color: #fbfbfb;
  font-size: 0.82rem;
  font-family: 'Manrope', sans-serif;
  outline: none;
  transition: all 0.25s ease;
}

[data-theme="light"] .blog-search-wrap input {
  background: rgba(255, 255, 255, 0.8);
  border-color: rgba(0, 0, 0, 0.12);
  color: #14141c;
}

.blog-search-wrap input::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

[data-theme="light"] .blog-search-wrap input::placeholder {
  color: rgba(0, 0, 0, 0.35);
}

.blog-search-wrap input:focus {
  border-color: rgba(30, 144, 255, 0.5);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 12px rgba(30, 144, 255, 0.15);
}

/* ─── Blog Grid ─── */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

@media (max-width: 1024px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .blog-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* Featured post — span 2 cols on desktop */
.blog-card.featured {
  grid-column: span 2;
}

@media (max-width: 1024px) {
  .blog-card.featured {
    grid-column: span 1;
  }
}

/* ─── Blog Card ─── */
.blog-card {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.3s ease, border-color 0.3s ease,
    opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform, opacity;
  text-decoration: none;
  color: inherit;
}

[data-theme="light"] .blog-card {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.24);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
  border-color: rgba(30, 144, 255, 0.25);
}

[data-theme="light"] .blog-card:hover {
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.12);
}

/* Card image */
.blog-card-img-wrap {
  width: 100%;
  height: 200px;
  overflow: hidden;
  position: relative;
  background: rgba(255, 255, 255, 0.03);
  flex-shrink: 0;
  border-top-left-radius: 19px;
  border-top-right-radius: 19px;
  background-clip: padding-box;
}

.blog-card.featured .blog-card-img-wrap {
  height: 260px;
}

.blog-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  display: block;
}

.blog-card:hover .blog-card-img {
  transform: scale(1.05);
}

/* Placeholder thumbnail khi không có ảnh */
.blog-card-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(106, 13, 173, 0.15), rgba(30, 144, 255, 0.1));
}

.blog-card-img-placeholder svg {
  width: 48px;
  height: 48px;
  color: rgba(255, 255, 255, 0.15);
}

[data-theme="light"] .blog-card-img-placeholder {
  background: linear-gradient(135deg, rgba(106, 13, 173, 0.06), rgba(30, 144, 255, 0.05));
}

[data-theme="light"] .blog-card-img-placeholder svg {
  color: rgba(0, 0, 0, 0.12);
}

/* Card body */
.blog-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 10px;
}

.blog-card.featured .blog-card-body {
  padding: 24px;
}

/* Meta row: category + read time */
.blog-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.blog-cat-chip {
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 10px;
  border-radius: 20px;
  background: rgba(30, 144, 255, 0.12);
  color: #60a5fa;
  border: 1px solid rgba(30, 144, 255, 0.2);
  white-space: nowrap;
  font-family: 'Manrope', sans-serif;
}

[data-theme="light"] .blog-cat-chip {
  background: rgba(30, 144, 255, 0.08);
  color: #1E90FF;
  border-color: rgba(30, 144, 255, 0.2);
}

/* Category color variants */
.blog-cat-chip.cat-tech {
  background: rgba(30, 144, 255, 0.12);
  color: #60a5fa;
  border-color: rgba(30, 144, 255, 0.2);
}

.blog-cat-chip.cat-design {
  background: rgba(255, 77, 158, 0.12);
  color: #f472b6;
  border-color: rgba(255, 77, 158, 0.2);
}

.blog-cat-chip.cat-business {
  background: rgba(106, 13, 173, 0.15);
  color: #c084fc;
  border-color: rgba(106, 13, 173, 0.25);
}

.blog-cat-chip.cat-news {
  background: rgba(237, 28, 36, 0.12);
  color: #f87171;
  border-color: rgba(237, 28, 36, 0.2);
}

.blog-cat-chip.cat-tutorial {
  background: rgba(74, 222, 128, 0.12);
  color: #4ade80;
  border-color: rgba(74, 222, 128, 0.2);
}

[data-theme="light"] .blog-cat-chip.cat-tech {
  background: rgba(30, 144, 255, 0.08);
  color: #1E90FF;
}

[data-theme="light"] .blog-cat-chip.cat-design {
  background: rgba(255, 77, 158, 0.08);
  color: #ec4899;
}

[data-theme="light"] .blog-cat-chip.cat-business {
  background: rgba(106, 13, 173, 0.08);
  color: #7c3aed;
}

[data-theme="light"] .blog-cat-chip.cat-news {
  background: rgba(237, 28, 36, 0.08);
  color: #ED1C24;
}

[data-theme="light"] .blog-cat-chip.cat-tutorial {
  background: rgba(22, 163, 74, 0.08);
  color: #16a34a;
}

.blog-read-time {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.35);
  font-family: 'Manrope', sans-serif;
}

[data-theme="light"] .blog-read-time {
  color: rgba(0, 0, 0, 0.4);
}

/* Card title */
.blog-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fbfbfb;
  font-family: 'Space Grotesk', sans-serif;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.blog-card.featured .blog-card-title {
  font-size: 1.3rem;
  -webkit-line-clamp: 3;
}

.blog-card:hover .blog-card-title {
  color: #60a5fa;
}

[data-theme="light"] .blog-card-title {
  color: #14141c;
}

[data-theme="light"] .blog-card:hover .blog-card-title {
  color: #1E90FF;
}

/* Card excerpt */
.blog-card-excerpt {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

[data-theme="light"] .blog-card-excerpt {
  color: rgba(0, 0, 0, 0.55);
}

/* Card footer */
.blog-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  margin-top: auto;
}

[data-theme="light"] .blog-card-footer {
  border-top-color: rgba(0, 0, 0, 0.07);
}

.blog-card-date {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.3);
  font-family: 'Manrope', sans-serif;
}

[data-theme="light"] .blog-card-date {
  color: rgba(0, 0, 0, 0.35);
}

.blog-card-arrow {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.blog-card:hover .blog-card-arrow {
  background: none !important;
  border-color: transparent;
}

.blog-card:hover .blog-card-arrow::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #ED1C24, #1E90FF);
  z-index: -1;
  border-radius: inherit;
}

.blog-card-arrow svg {
  width: 13px;
  height: 13px;
  color: rgba(255, 255, 255, 0.4);
  transition: transform 0.2s ease, color 0.2s ease;
  position: relative;
  z-index: 2;
}

.blog-card:hover .blog-card-arrow svg {
  color: #fff;
  transform: translateX(2px);
}

[data-theme="light"] .blog-card-arrow {
  border-color: rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .blog-card-arrow svg {
  color: rgba(0, 0, 0, 0.3);
}

/* ─── Empty / No results ─── */
.blog-empty {
  text-align: center;
  padding: 64px 24px;
  color: rgba(255, 255, 255, 0.35);
  font-family: 'Manrope', sans-serif;
  grid-column: 1 / -1;
}

[data-theme="light"] .blog-empty {
  color: rgba(0, 0, 0, 0.35);
}

.blog-empty svg {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  display: block;
  opacity: 0.3;
}

.blog-empty p {
  font-size: 0.9rem;
}

/* ─── Pagination ─── */
.pagination-nav {
  margin-top: 48px;
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.page-number {
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.6);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.18s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-family: 'Manrope', sans-serif;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

[data-theme="light"] .page-number {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.12);
  color: rgba(0, 0, 0, 0.65);
}

.page-number:hover,
.page-number.active-page {
  color: white;
  border-color: transparent;
  background: none !important;
}

.page-number:hover::before,
.page-number.active-page::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #ED1C24, #1E90FF);
  z-index: -1;
  border-radius: inherit;
}

.page-number.active-page {
  box-shadow: 0 2px 12px rgba(237, 28, 36, 0.4);
}

.page-number.disabled-page {
  opacity: 0.25;
  cursor: default;
  pointer-events: none;
}

/* ─── Scroll reveal ─── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

.reveal:not(.revealed) {
  transition-delay: 0s !important;
}

/* ─── Mobile ─── */
@media (max-width: 768px) {
  .blog-hero {
    padding: 120px 16px 36px;
  }

  .blog-main {
    padding: 28px 16px 60px;
  }

  .blog-card.featured {
    grid-column: span 1;
  }
}

/* ─── Filter Drawer & Custom Dropdown Styles (Đồng bộ với Projects) ─── */

#filterDrawerOverlay {
  transition: opacity 0.3s ease;
  will-change: opacity;
}

#filterDrawer {
  will-change: transform;
  box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s ease-in-out;
}

html[data-theme="light"] #filterDrawer {
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.filter-sort-wrap {
  position: relative;
  width: 100%;
  flex-shrink: 0;
}

/* Sửa lỗi góc vuông ở các nút tròn bằng pseudo-element ::before */
#openFilterDrawerBtn {
  background: none !important;
  overflow: hidden;
  isolation: isolate;
}

#openFilterDrawerBtn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top right, #ED1C24, #1E90FF);
  z-index: -1;
  border-radius: inherit;
}

.chips-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}

.chip {
  padding: 6px 14px;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Manrope', sans-serif;
  overflow: hidden;
  background-clip: padding-box;
}

[data-theme="light"] .chip {
  background: rgba(255, 255, 255, 0.7);
  border-color: rgba(0, 0, 0, 0.12);
  color: rgba(0, 0, 0, 0.65);
}

.chip:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fbfbfb;
  border-color: rgba(255, 255, 255, 0.15);
}

[data-theme="light"] .chip:hover {
  background: rgba(0, 0, 0, 0.05);
  color: #14141c;
  border-color: rgba(0, 0, 0, 0.18);
}

.chip svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: rgba(255, 255, 255, 0.45);
  transition: color 0.2s ease, transform 0.2s ease;
}

[data-theme="light"] .chip svg {
  color: rgba(0, 0, 0, 0.45);
}

.chip:hover svg {
  color: rgba(255, 255, 255, 0.8);
  transform: scale(1.05);
}

[data-theme="light"] .chip:hover svg {
  color: rgba(0, 0, 0, 0.7);
}

.chip.active {
  position: relative;
  background: rgba(30, 144, 255, 0.12) !important;
  border: 1px solid rgba(30, 144, 255, 0.4) !important;
  color: #ffffff !important;
  box-shadow: 0 0 15px rgba(30, 144, 255, 0.25), 0 0 2px rgba(106, 13, 173, 0.45) !important;
  overflow: hidden;
}

.chip.active::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 30px;
  padding: 1px;
  background: linear-gradient(135deg, rgba(30, 144, 255, 0.8), rgba(106, 13, 173, 0.8));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  z-index: 1;
}

[data-theme="light"] .chip.active {
  background: rgba(30, 144, 255, 0.08) !important;
  border: 1px solid rgba(30, 144, 255, 0.35) !important;
  color: #1E90FF !important;
  box-shadow: 0 0 10px rgba(30, 144, 255, 0.15) !important;
}

[data-theme="light"] .chip.active::before {
  background: linear-gradient(135deg, rgba(30, 144, 255, 0.5), rgba(106, 13, 173, 0.5));
}

.chip .chip-count {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 9999px;
  padding: 0 6px;
  min-width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.65);
  margin-left: 2px;
  transition: all 0.2s ease;
}

[data-theme="light"] .chip .chip-count {
  background: rgba(0, 0, 0, 0.08);
  color: rgba(0, 0, 0, 0.6);
}

.chip.active .chip-count {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
}

[data-theme="light"] .chip.active .chip-count {
  background: rgba(30, 144, 255, 0.15);
  color: #1E90FF;
}

/* ─── Dải mờ ngang full màn hình ngăn cách Hero ─── */
.section-bar-wrap {
  padding: 10px 24px;
  background: rgba(20, 20, 28, 0.2);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
  transition: all 0.3s ease;

  /* Hiệu ứng mờ dần (fade out) hai bên rìa màn hình */
  mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
}

[data-theme="light"] .section-bar-wrap {
  background: rgba(255, 255, 255, 0.45);
  border-top-color: rgba(0, 0, 0, 0.22);
  border-bottom-color: rgba(0, 0, 0, 0.22);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.04);
}

.section-bar-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2px;
}

@media (max-width: 768px) {
  .section-bar-wrap {
    padding: 10px 16px;
  }
}

/* ─── Sforum Style Upgrade ─── */

.section-title-custom {
  font-size: 1.15rem;
  font-weight: 800;
  color: #fbfbfb;
  font-family: 'Space Grotesk', sans-serif;
  letter-spacing: 0.05em;
  margin-bottom: 20px;
  position: relative;
  display: inline-flex;
  align-items: center;
}

.section-title-custom::after {
  content: "";
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 32px;
  height: 3px;
  background: #ED1C24;
  border-radius: 2px;
}

[data-theme="light"] .section-title-custom {
  color: #14141c;
}

/* ─── Chủ đề hot ─── */
.hot-topics-section {
  margin-top: -64px;
  /* Dịch lên cao để che vết cắt robot */
  margin-bottom: 32px;
  overflow: hidden;
  position: relative;
  z-index: 10;
  width: 100%;

  /* Thanh mờ kéo dài full màn hình - chỉ border trên dưới, không bo góc */
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
  border-left: none;
  border-right: none;
  border-radius: 0;
  padding: 14px 0 6px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}

.hot-topics-section .section-title-custom {
  margin-bottom: 10px;
  font-size: 0.9rem;
  text-align: center;
}

.hot-topics-section .section-title-custom::after {
  bottom: -4px;
  height: 2px;
  width: 24px;
  left: 50%;
  transform: translateX(-50%);
}

[data-theme="light"] .hot-topics-section {
  background: rgba(255, 255, 255, 0.45);
  border-top-color: rgba(0, 0, 0, 0.22);
  border-bottom-color: rgba(0, 0, 0, 0.22);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.04);
}

.hot-topics-track-wrapper {
  width: 100%;
  overflow: hidden;
  position: relative;
  /* Làm mờ cố định ở hai đầu biên màn hình */
  -webkit-mask-image: linear-gradient(to right, transparent, white 10%, white 90%, transparent);
  mask-image: linear-gradient(to right, transparent, white 10%, white 90%, transparent);
}

.hot-topics-track {
  display: flex;
  gap: 12px;
  width: fit-content;
  animation: slideHotTopics 30s linear infinite;
  padding-bottom: 6px;
}

.hot-topics-track:hover {
  animation-play-state: paused;
}

@keyframes slideHotTopics {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-25%);
  }
}

.hot-topic-card {
  flex: 0 0 auto;
  position: relative;
  min-width: 140px;
  height: 52px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.03);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 12px;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
  isolation: isolate;
}

.hot-topic-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(30, 144, 255, 0.1), rgba(106, 13, 173, 0.05));
  opacity: 0;
  z-index: -1;
  transition: opacity 0.25s ease;
}

.hot-topic-card:hover {
  transform: translateY(-2px);
  border-color: rgba(30, 144, 255, 0.35);
  box-shadow: 0 8px 24px rgba(30, 144, 255, 0.12);
}

.hot-topic-card:hover::before {
  opacity: 1;
}

[data-theme="light"] .hot-topic-card {
  background: rgba(0, 0, 0, 0.02);
  border-color: rgba(0, 0, 0, 0.24);
}

[data-theme="light"] .hot-topic-card:hover {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(30, 144, 255, 0.3);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.05);
}

.hot-topic-tag {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
}

[data-theme="light"] .hot-topic-tag {
  color: #14141c;
}

.hot-topic-views {
  font-size: 0.65rem;
  color: rgba(255, 255, 255, 0.4);
  margin-top: 1px;
  font-weight: 500;
}

[data-theme="light"] .hot-topic-views {
  color: rgba(0, 0, 0, 0.45);
}

/* ─── Spotlight Section (Nổi bật nhất) ─── */
.spotlight-section {
  margin-bottom: 40px;
}

.spotlight-grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 24px;
}

@media (max-width: 1024px) {
  .spotlight-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

/* Cột trái: Bài viết lớn */
.spotlight-left {
  width: 100%;
}

.spotlight-large-card {
  position: relative;
  height: 380px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 32px;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  isolation: isolate;
}

.spotlight-large-card:hover {
  transform: translateY(-4px);
  border-color: rgba(237, 28, 36, 0.25);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.6);
}

[data-theme="light"] .spotlight-large-card {
  border-color: rgba(0, 0, 0, 0.24);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .spotlight-large-card:hover {
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.spotlight-large-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  transition: transform 0.5s ease;
}

.spotlight-large-card:hover .spotlight-large-bg {
  transform: scale(1.03);
}

.spotlight-large-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(20, 20, 28, 0.95) 0%, rgba(20, 20, 28, 0.4) 60%, transparent 100%);
  z-index: -1;
}

[data-theme="light"] .spotlight-large-overlay {
  background: linear-gradient(to top, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.5) 60%, transparent 100%);
}

.spotlight-badge {
  position: absolute;
  top: 24px;
  left: 24px;
  background: #ED1C24;
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(237, 28, 36, 0.4);
}

.spotlight-large-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.5);
  font-weight: 500;
}

[data-theme="light"] .spotlight-large-meta {
  color: rgba(0, 0, 0, 0.5);
}

.spotlight-large-title {
  font-size: 1.45rem;
  font-weight: 800;
  color: #ffffff;
  font-family: 'Space Grotesk', sans-serif;
  line-height: 1.3;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.spotlight-large-card:hover .spotlight-large-title {
  color: #60a5fa;
}

[data-theme="light"] .spotlight-large-title {
  color: #14141c;
}

[data-theme="light"] .spotlight-large-card:hover .spotlight-large-title {
  color: #1E90FF;
}

.spotlight-large-desc {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

[data-theme="light"] .spotlight-large-desc {
  color: rgba(0, 0, 0, 0.6);
}

/* Cột phải: 3 bài viết nhỏ */
.spotlight-right {
  display: flex;
  flex-direction: column;
  gap: 16px;
  justify-content: space-between;
}

.spotlight-row-card {
  display: flex;
  gap: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  padding: 12px;
  border-radius: 18px;
  cursor: pointer;
  transition: all 0.25s ease;
}

.spotlight-row-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
}

[data-theme="light"] .spotlight-row-card {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.24);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .spotlight-row-card:hover {
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.1);
}

.spotlight-row-img-wrap {
  width: 110px;
  height: 76px;
  flex-shrink: 0;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
}

.spotlight-row-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.spotlight-row-card:hover .spotlight-row-img {
  transform: scale(1.04);
}

.spotlight-row-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex: 1;
}

.spotlight-row-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #fbfbfb;
  font-family: 'Space Grotesk', sans-serif;
  line-height: 1.35;
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.spotlight-row-card:hover .spotlight-row-title {
  color: #60a5fa;
}

[data-theme="light"] .spotlight-row-title {
  color: #14141c;
}

[data-theme="light"] .spotlight-row-card:hover .spotlight-row-title {
  color: #1E90FF;
}

.spotlight-row-meta {
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.35);
  font-weight: 500;
}

[data-theme="light"] .spotlight-row-meta {
  color: rgba(0, 0, 0, 0.45);
}

/* ─── Main Content Split Layout ─── */
.blog-main-container {
  margin-bottom: 60px;
}

.blog-main-split {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 32px;
}

@media (max-width: 1024px) {
  .blog-main-split {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

.blog-left-content {
  width: 100%;
}

.blog-list-view {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Row card (List view) */
.blog-row-card {
  display: flex;
  gap: 20px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 20px;
  padding: 16px;
  cursor: pointer;
  transition: all 0.25s ease;
}

.blog-row-card:hover {
  transform: translateY(-3px);
  border-color: rgba(30, 144, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

[data-theme="light"] .blog-row-card {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.24);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .blog-row-card:hover {
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.1);
}

.blog-row-img-wrap {
  width: 220px;
  height: 140px;
  flex-shrink: 0;
  border-radius: 14px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
}

@media (max-width: 640px) {
  .blog-row-card {
    flex-direction: column;
    gap: 12px;
  }

  .blog-row-img-wrap {
    width: 100%;
    height: 160px;
  }
}

.blog-row-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-row-card:hover .blog-row-img {
  transform: scale(1.03);
}

.blog-row-body {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex: 1;
}

.blog-row-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.blog-row-title {
  font-size: 1.12rem;
  font-weight: 700;
  color: #ffffff;
  font-family: 'Space Grotesk', sans-serif;
  line-height: 1.35;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.blog-row-card:hover .blog-row-title {
  color: #60a5fa;
}

[data-theme="light"] .blog-row-title {
  color: #14141c;
}

[data-theme="light"] .blog-row-card:hover .blog-row-title {
  color: #1E90FF;
}

.blog-row-desc {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.45);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 12px;
}

[data-theme="light"] .blog-row-desc {
  color: rgba(0, 0, 0, 0.55);
}

.blog-row-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.3);
}

[data-theme="light"] .blog-row-footer {
  border-top-color: rgba(0, 0, 0, 0.06);
  color: rgba(0, 0, 0, 0.4);
}

/* ─── Sidebar ─── */
.blog-sidebar {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.sidebar-widget {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 20px;
  padding: 24px;
}

[data-theme="light"] .sidebar-widget {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.24);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
}

.widget-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
  font-family: 'Space Grotesk', sans-serif;
  letter-spacing: 0.04em;
  margin-bottom: 18px;
  position: relative;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.widget-title::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 24px;
  height: 2px;
  background: #ED1C24;
}

[data-theme="light"] .widget-title {
  color: #14141c;
  border-bottom-color: rgba(0, 0, 0, 0.06);
}

/* Widget 1: Trending 24h */
.trending-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.trending-item {
  display: flex;
  gap: 14px;
  cursor: pointer;
}

.trending-num {
  font-size: 1.5rem;
  font-weight: 800;
  font-family: 'Space Grotesk', sans-serif;
  color: rgba(255, 255, 255, 0.12);
  line-height: 1;
  transition: color 0.2s ease;
}

.trending-item:hover .trending-num {
  color: #ED1C24;
}

.trending-item-content {
  flex: 1;
}

.trending-item-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.4;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.trending-item:hover .trending-item-title {
  color: #60a5fa;
}

[data-theme="light"] .trending-item-title {
  color: rgba(0, 0, 0, 0.8);
}

[data-theme="light"] .trending-item:hover .trending-item-title {
  color: #1E90FF;
}

[data-theme="light"] .trending-num {
  color: rgba(0, 0, 0, 0.08);
}

.trending-item-views {
  font-size: 0.65rem;
  color: rgba(255, 255, 255, 0.3);
}

[data-theme="light"] .trending-item-views {
  color: rgba(0, 0, 0, 0.45);
}

/* Widget 2: Newsletter */
.newsletter-widget {
  background: linear-gradient(135deg, rgba(30, 144, 255, 0.04), rgba(106, 13, 173, 0.02));
  border-color: rgba(30, 144, 255, 0.12);
}

.widget-desc {
  font-size: 0.76rem;
  color: rgba(255, 255, 255, 0.45);
  line-height: 1.5;
  margin-bottom: 16px;
}

[data-theme="light"] .widget-desc {
  color: rgba(0, 0, 0, 0.55);
}

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.newsletter-input {
  width: 100%;
  padding: 10px 16px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.78rem;
  color: #ffffff;
  outline: none;
  transition: all 0.2s ease;
}

.newsletter-input:focus {
  border-color: rgba(30, 144, 255, 0.4);
  background: rgba(255, 255, 255, 0.08);
}

[data-theme="light"] .newsletter-input {
  background: rgba(0, 0, 0, 0.02);
  border-color: rgba(0, 0, 0, 0.1);
  color: #14141c;
}

[data-theme="light"] .newsletter-input:focus {
  background: #ffffff;
  border-color: rgba(30, 144, 255, 0.4);
}

.newsletter-submit-btn {
  background: linear-gradient(135deg, #ED1C24, #1E90FF);
  color: white;
  padding: 10px;
  border-radius: 12px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: opacity 0.2s ease;
}

.newsletter-submit-btn:hover {
  opacity: 0.9;
}

/* Widget 3: Services Banner */
.services-widget {
  background: radial-gradient(circle at 10% 20%, rgba(26, 26, 46, 0.9) 0%, rgba(45, 31, 61, 0.8) 90%);
  border-color: rgba(255, 255, 255, 0.08);
  padding: 24px;
}

[data-theme="light"] .services-widget {
  background: radial-gradient(circle at 10% 20%, rgba(245, 247, 250, 0.95) 0%, rgba(228, 233, 240, 0.9) 90%);
}

.services-banner-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.banner-badge {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #60a5fa;
  margin-bottom: 8px;
}

[data-theme="light"] .banner-badge {
  color: #1E90FF;
}

.banner-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
  font-family: 'Space Grotesk', sans-serif;
  line-height: 1.35;
  margin-bottom: 8px;
}

[data-theme="light"] .banner-title {
  color: #14141c;
}

.banner-desc {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.45;
  margin-bottom: 18px;
}

[data-theme="light"] .banner-desc {
  color: rgba(0, 0, 0, 0.55);
}

.banner-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: white;
  color: #14141c;
  font-size: 0.74rem;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.banner-btn:hover {
  transform: translateX(2px);
  background: rgba(255, 255, 255, 0.9);
}

[data-theme="light"] .banner-btn {
  background: #14141c;
  color: white;
}

[data-theme="light"] .banner-btn:hover {
  background: rgba(20, 20, 28, 0.9);
}