/* =============================================
   BLOG / ARTÍCULOS — Estilos externos
   Laboratorios Gaher S.A.
   ============================================= */

/* ===== HERO ===== */
.blog-hero {
  position: relative;
  background: var(--primary-navy, #00173b);
  padding: 56px 0 48px;
  overflow: hidden;
}

.blog-hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.12;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.4'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.blog-hero-title {
  font-size: 2.2rem;
  font-weight: 700;
  color: white;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.blog-hero-desc {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.8);
  max-width: 640px;
  line-height: 1.6;
  margin: 0;
}

/* ===== SEARCH BAR ===== */
.blog-filters-section {
  padding: 24px 0;
  border-bottom: 1px solid #e0e0e0;
  background: white;
}

.blog-filters-bar {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  background: var(--bg-light, #f8f9fa);
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  padding: 12px 16px;
}

.blog-search-wrap {
  flex: 1;
  position: relative;
  min-width: 200px;
}

.blog-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  color: #747780;
}

.blog-search-input {
  width: 100%;
  padding: 12px 16px 12px 44px;
  border: 1px solid #c4c6d0;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.92rem;
  background: white;
  color: var(--text-dark, #1e293b);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.blog-search-input:focus {
  outline: none;
  border-color: #00a8e8;
  box-shadow: 0 0 0 2px rgba(0, 168, 232, 0.12);
}

.blog-btn-clear {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 20px;
  border: 1px solid #c4c6d0;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #44474f;
  text-decoration: none;
  background: white;
  white-space: nowrap;
  transition: background 0.2s;
}

.blog-btn-clear:hover {
  background: #e7e8e9;
}

/* ===== GRID ===== */
.blog-grid-section {
  padding: 40px 0 60px;
}

/* ===== CARD LINK WRAPPER ===== */
.blog-card-link-wrapper {
  display: block;
  text-decoration: none;
  color: inherit;
  height: 100%;
}

.blog-card-link-wrapper:hover {
  text-decoration: none;
  color: inherit;
}

/* ===== ARTICLE CARD ===== */
.blog-card {
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.blog-card:hover {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
  transform: translateY(-4px);
}

.blog-card-img {
  position: relative;
  height: 200px;
  overflow: hidden;
}

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

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

.blog-card-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-light, #f8f9fa);
}

.blog-card-img-placeholder .material-symbols-outlined {
  font-size: 56px;
  color: #c4c6d0;
}

.blog-card-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--secondary, #00658d);
  color: white;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 6px;
  text-transform: capitalize;
  letter-spacing: 0.3px;
}

/* ===== CARD BODY ===== */
.blog-card-body {
  flex: 1;
  padding: 24px;
  display: flex;
  flex-direction: column;
}

.blog-card-date {
  font-size: 0.72rem;
  font-weight: 600;
  color: #747780;
  margin-bottom: 8px;
  display: block;
}

.blog-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  line-height: 1.35;
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card-desc {
  font-size: 0.88rem;
  color: #44474f;
  line-height: 1.6;
  margin-bottom: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex-grow: 1;
}

.blog-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 16px;
  margin-top: auto;
}

.blog-card-author {
  display: flex;
  align-items: center;
  gap: 8px;
}

.blog-card-avatar {
  width: 32px;
  height: 32px;
  background: var(--primary-navy, #00173b);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  flex-shrink: 0;
}

.blog-card-author-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--primary-navy, #00173b);
}

.blog-card-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--secondary, #00658d);
  text-decoration: none;
  transition: gap 0.2s;
}

.blog-card-link:hover {
  gap: 8px;
  color: var(--secondary, #00658d);
}

/* ===== PAGINATION ===== */
.blog-pagination {
  margin-top: 40px;
  display: flex;
  justify-content: center;
}

.blog-pagination nav {
  background: white;
  padding: 8px 12px;
  border-radius: 50px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  border: 1px solid #e0e0e0;
}

.blog-pagination .pagination {
  display: flex;
  gap: 4px;
  margin: 0;
  padding: 0;
  align-items: center;
}

.blog-pagination .page-item .page-link {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  border: none;
  background: transparent;
  transition: all 0.3s ease;
  text-decoration: none;
}

.blog-pagination .page-item .page-link:focus {
  box-shadow: none;
  outline: none;
  background: #f1f5f9;
}

.blog-pagination .page-item:not(.active):not(.disabled) .page-link:hover {
  background: #f1f5f9;
  transform: translateY(-2px);
}

.blog-pagination .page-item.active .page-link,
.blog-pagination .page-item.active .page-link:hover {
  background: var(--accent-yellow, #fbc02d);
  color: #1e293b;
  box-shadow: 0 4px 12px rgba(251, 192, 45, 0.4);
  transform: scale(1.05);
  z-index: 2;
}

.blog-pagination .page-item.disabled .page-link {
  opacity: 0.3;
  cursor: not-allowed;
  background: transparent;
}

/* ===== EMPTY STATE ===== */
.blog-empty {
  text-align: center;
  padding: 72px 0;
}

.blog-empty h4 {
  font-weight: 700;
  margin-top: 16px;
  margin-bottom: 6px;
}

.blog-empty p {
  color: #747780;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 767.98px) {
  .blog-hero {
    padding: 36px 0 32px;
  }

  .blog-hero-title {
    font-size: 1.6rem;
  }

  .blog-hero-desc {
    font-size: 0.9rem;
  }

  .blog-filters-bar {
    flex-direction: column;
  }

  .blog-search-wrap {
    min-width: 100%;
  }

  .blog-btn-clear {
    width: 100%;
    justify-content: center;
  }

  .blog-pagination nav {
    padding: 8px 12px;
  }

  .blog-pagination .page-item .page-link {
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    font-size: 0.85rem;
  }
}

/* ===== DETAIL — Breadcrumb ===== */
.blog-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
}

.blog-breadcrumb a {
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  transition: color 0.2s;
}

.blog-breadcrumb a:hover {
  color: white;
}

.blog-breadcrumb span:last-child {
  color: white;
  font-weight: 600;
}

/* ===== DETAIL — Section ===== */
.blog-detail-section {
  padding: 48px 0 64px;
}

/* ===== DETAIL — Header ===== */
.blog-detail-header {
  margin-bottom: 40px;
}

.blog-detail-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  line-height: 1.2;
  margin-bottom: 20px;
}

.blog-detail-meta {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  padding-bottom: 24px;
  border-bottom: 1px solid #e0e0e0;
  margin-bottom: 32px;
}

.blog-detail-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  color: #747780;
}

.blog-detail-meta-item .material-symbols-outlined {
  color: #747780;
}

.blog-detail-hero-img {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

.blog-detail-hero-item {
  flex: 1 1 0;
  min-width: 180px;
  max-width: 320px;
  height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-light, #f8f9fa);
  border: 1px solid #e0e0e0;
}

.blog-detail-hero-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

/* ===== DETAIL — Body ===== */
.blog-detail-body {
  font-size: 1rem;
  color: var(--text-dark, #1e293b);
  line-height: 1.8;
}

.blog-detail-h2 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  margin-top: 36px;
  margin-bottom: 14px;
}

.blog-detail-paragraph {
  margin-bottom: 20px;
  color: #44474f;
}

.blog-detail-paragraph strong {
  color: var(--primary-navy, #00173b);
  font-weight: 700;
}

/* ===== SIDEBAR ===== */
.blog-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.blog-sidebar-card {
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  padding: 24px;
}

.blog-sidebar-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e0e0e0;
}

.blog-sidebar-search {
  position: relative;
}

.blog-sidebar-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  color: #747780;
}

.blog-sidebar-search-input {
  width: 100%;
  padding: 10px 14px 10px 40px;
  border: 1px solid #c4c6d0;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.85rem;
  background: var(--bg-light, #f8f9fa);
  color: var(--text-dark, #1e293b);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.blog-sidebar-search-input:focus {
  outline: none;
  border-color: #00a8e8;
  box-shadow: 0 0 0 2px rgba(0, 168, 232, 0.12);
}

/* Sidebar — Related Articles */
.blog-sidebar-articles {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.blog-sidebar-article {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 8px;
  border-radius: 8px;
  text-decoration: none;
  transition: background 0.2s;
}

.blog-sidebar-article:hover {
  background: var(--bg-light, #f8f9fa);
}

.blog-sidebar-article-img {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  overflow: hidden;
  background: var(--bg-light, #f8f9fa);
  border: 1px solid #e0e0e0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.blog-sidebar-article-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-sidebar-article-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  margin: 0 0 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.3;
}

.blog-sidebar-article-date {
  font-size: 0.72rem;
  color: #747780;
}

/* Sidebar — Featured Articles */
.blog-sidebar-featured {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.blog-featured-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 10px;
  border-radius: 10px;
  text-decoration: none;
  border: 1px solid #e0e0e0;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.blog-featured-item:hover {
  border-color: #00a8e8;
  box-shadow: 0 2px 8px rgba(0, 168, 232, 0.1);
}

.blog-featured-img {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  background: var(--bg-light, #f8f9fa);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.blog-featured-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-featured-body {
  flex: 1;
  min-width: 0;
}

.blog-featured-tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.65rem;
  font-weight: 700;
  color: #e65100;
  background: rgba(230, 81, 0, 0.08);
  padding: 2px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 6px;
}

.blog-featured-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  margin: 0 0 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.3;
}

.blog-featured-date {
  font-size: 0.7rem;
  color: #747780;
}

.blog-sidebar-empty {
  font-size: 0.82rem;
  color: #747780;
  margin: 0;
  text-align: center;
  padding: 12px 0;
}

/* Sidebar — Products */
.blog-sidebar-products {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.blog-sidebar-product {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 8px;
  border-radius: 8px;
  text-decoration: none;
  transition: background 0.2s;
}

.blog-sidebar-product:hover {
  background: var(--bg-light, #f8f9fa);
}

.blog-sidebar-product-img {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  overflow: hidden;
  background: var(--bg-light, #f8f9fa);
  border: 1px solid #e0e0e0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  padding: 4px;
}

.blog-sidebar-product-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.blog-sidebar-product-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  margin: 0 0 2px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.3;
}

.blog-sidebar-product-unit {
  font-size: 0.7rem;
  color: #747780;
}

/* ===== BOTTOM — Featured Articles ===== */
.blog-bottom-featured {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid #e0e0e0;
}

.blog-bottom-featured-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  margin-bottom: 20px;
}

.blog-bottom-card {
  display: block;
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.blog-bottom-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  transform: translateY(-4px);
}

.blog-bottom-card-img {
  height: 140px;
  overflow: hidden;
  background: var(--bg-light, #f8f9fa);
  display: flex;
  align-items: center;
  justify-content: center;
}

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

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

.blog-bottom-card-body {
  padding: 14px;
}

.blog-bottom-card-date {
  font-size: 0.7rem;
  color: #747780;
  display: block;
  margin-bottom: 6px;
}

.blog-bottom-card-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary-navy, #00173b);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.3;
}

/* ===== DETAIL — Responsive ===== */
@media (max-width: 991.98px) {
  .blog-detail-title {
    font-size: 1.5rem;
  }

  .blog-detail-hero-item {
    max-width: 260px;
    height: 200px;
  }
}

@media (max-width: 575.98px) {
  .blog-detail-hero-img {
    flex-direction: column;
  }

  .blog-detail-hero-item {
    max-width: 100%;
    height: auto;
  }

  .blog-detail-hero-item img {
    height: auto;
  }
}
