:root {
  --blue-light: #87ceeb;
  --dark-green-black: #0d1b1e;
  --text-light: #ffffff;
  --orange: #ff5722;
}

body {
  font-family: "Open Sans", sans-serif;
  background: #f5f5f5;
  margin: 0;
  color: #222;
}

/* ===== Header ===== */
.site-header {
  background: var(--dark-green-black);
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: auto;
}

.flex-between {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 24px;
  font-weight: 700;
  color: var(--blue-light);
}

.logo span {
  color: var(--text-light);
}

.menu {
  list-style: none;
  display: flex;
  gap: 20px;
}

.menu a {
  text-decoration: none;
  font-weight: 600;
  color: var(--text-light);
  transition: 0.3s;
}

.menu a:hover {
  color: var(--blue-light);
}

.menu-toggle {
  display: none;
  font-size: 24px;
  background: var(--blue-light);
  color: var(--dark-green-black);
  border: none;
  padding: 6px 12px;
  border-radius: 4px;
  cursor: pointer;
}

/* ===== Breadcrumb ===== */
.breadcrumb {
  font-size: 0.9rem;
  margin: 20px auto;
  width: 90%;
  max-width: 1200px;
  color: #555;
}

.breadcrumb a {
  text-decoration: none;
  color: var(--blue-light);
}

/* ===== Layout ===== */
.content {
  display: flex;
  gap: 30px;
  margin: 20px auto 40px;
  width: 90%;
  max-width: 1200px;
}

.main-column {
  flex: 0 0 70%;
}

.sidebar {
  flex: 0 0 30%;
}

/* ===== Bài viết danh mục ===== */
.post-card {
  display: flex;
  gap: 20px;
  background: #fff;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  margin-bottom: 25px;
  transition: transform 0.3s, box-shadow 0.3s;
}

.post-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.post-content {
  flex: 1;
}

.post-content h2 {
  margin-bottom: 10px;
}

.post-content p {
  margin-bottom: 10px;
}

.read-more {
  display: inline-block;
  margin-top: 8px;
  color: var(--blue-light);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
}

.read-more:hover {
  color: #3498db;
  transform: translateY(-3px);
  text-decoration: underline;
}

/* ===== Sidebar ===== */
.sidebar-box {
  background: #fff;
  padding: 15px;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  margin-bottom: 20px;
}

.sidebar-box h3 {
  font-size: 1.1rem;
  margin-bottom: 15px;
  color: var(--orange);
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
  .content {
    flex-direction: column;
  }
  .main-column,
  .sidebar {
    flex: 0 0 100%;
    max-width: 100%;
  }
}

@media (max-width: 768px) {
  .menu {
    display: none;
    flex-direction: column;
    background: var(--dark-green-black);
    position: absolute;
    top: 60px;
    right: 20px;
    width: 200px;
    padding: 15px;
    border-radius: 6px;
  }

  .menu.show {
    display: flex;
  }

  .menu-toggle {
    display: inline-block;
  }

  .post-card {
    flex-direction: column;
  }
}

/* ================================
   Ảnh bài viết vuông và nhỏ gọn
   ================================ */
.post-card .thumb {
  flex: 0 0 auto;
  width: 130px;          /* kích thước ảnh nhỏ gọn */
  aspect-ratio: 1 / 1;   /* giữ tỉ lệ vuông */
  overflow: hidden;
  border-radius: 10px;
  max-width: none;
}

.post-card .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Co nhỏ hơn trên mobile */
@media (max-width: 768px) {
  .post-card .thumb {
    width: 100px;
  }
}
/* ===== Sidebar: sản phẩm gợi ý chuẩn đẹp ===== */
.sidebar-box .suggest-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 8px;
  transition: background 0.3s;
}
.sidebar-box .suggest-item:hover {
  background: #f0f8ff;
}

.sidebar-box .suggest-item img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}

.sidebar-box .product-name {
  flex: 1;
  font-size: 0.9rem;
  font-weight: 600;
  color: #333;
  line-height: 1.2;
}

.sidebar-box .btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: var(--orange);
  color: #fff !important;
  font-size: 0.8rem;
  padding: 6px 10px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
  transition: background 0.3s, transform 0.2s;
}
.sidebar-box .btn-cta:hover {
  background: #e64a19;
  transform: translateY(-2px);
}
/* Căn lề phần tiêu đề danh mục */
.category-header {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto 20px;
  padding-left: 20px; /* đẩy qua phải nhẹ */
}

.category-header h1 {
  font-size: 1.8rem;
  color: var(--dark-green-black);
  margin-bottom: 6px;
}

.category-header .tagline {
  color: #666;
  font-size: 0.95rem;
}
/* Mặc định desktop: chỉ hiện ảnh đầu */
.thumb img.extra-img {
  display: none;
}

/* Mobile: hiển thị 3 ảnh nhỏ cạnh nhau */
@media (max-width: 600px) {
  .thumb {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }

  .thumb img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 6px;
  }

  .thumb img.extra-img {
    display: block;
  }

  .thumb img.main-img {
    display: block;
  }
}
@media (max-width: 750px) {
  .post-card .thumb {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    width: 100%;
    aspect-ratio: auto;
  }

  .post-card .thumb img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 8px;
  }
}

