/* ===== REVISED BLOG.CSS - ALIGNED WITH MAIN DESIGN SYSTEM ===== */
/* Using CSS variables from main stylesheet */

/* Hero Section - Updated to use main gradients */
.blog-hero {
  background: var(--hero-gradient);
  color: var(--text-inverse);
  padding: 60px 0;
  margin-bottom: 30px;
  border-bottom: 4px solid var(--accent-gold);
  margin-top: 20px;
  position: relative;
}

/* Blog hero typography - using main heading styles */
.blog-hero h1 {
  color: var(--text-inverse);
  font-size: clamp(2rem, 5vw, 2.8rem);
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.blog-hero .lead {
  color: var(--text-inverse);
  font-size: clamp(1rem, 2vw, 1.2rem);
  opacity: 0.95;
  max-width: 600px;
}

.blog-hero p {
  color: var(--text-inverse);
}

/* Welcome badge - using gold accent */
.blog-welcome-badge {
  background: var(--accent-gold);
  color: var(--primary-dark);
  font-size: 0.9rem;
  font-weight: 700;
  padding: 0.5rem 1.5rem;
  border-radius: 50px;
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: var(--shadow-sm);
}

/* Blog search - updated with main button styles */
.blog-search {
  max-width: 500px;
}

.blog-search .input-group {
  box-shadow: var(--shadow-md);
  border-radius: 50px;
  overflow: hidden;
}

.blog-search .form-control {
  border: none;
  padding: 0.8rem 1.5rem;
  font-family: 'Poppins', sans-serif;
}

.blog-search .form-control:focus {
  outline: 3px solid var(--focus-outline);
  outline-offset: 2px;
  box-shadow: none;
}

.blog-search .btn {
  background: var(--primary);
  color: var(--text-inverse);
  border: none;
  padding: 0.8rem 1.8rem;
  font-weight: 600;
  transition: all 0.3s ease;
}

.blog-search .btn:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

/* Section Title - updated to use main accent */
.section-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 600;
  color: var(--primary-dark);
  position: relative;
  padding-bottom: 0.75rem;
  margin-bottom: 1.5rem;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 3px;
  background: var(--accent-gold);
  border-radius: 2px;
}

.text-center .section-title::after {
  left: 50%;
  transform: translateX(-50%);
}

/* Featured Cards - updated with main card styles */
.featured-card {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  height: 250px;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
}

.featured-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.featured-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.featured-no-image {
  width: 100%;
  height: 100%;
  background: var(--hero-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-inverse);
  font-size: 3rem;
}

.featured-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(31, 66, 30, 0.95));
  padding: 1.5rem;
  color: var(--text-inverse);
}

.featured-label {
  background: var(--accent-gold);
  color: var(--primary-dark);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.8rem;
  border-radius: 50px;
  display: inline-block;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.featured-overlay h5 {
  margin-bottom: 0.5rem;
}

.featured-overlay h5 a {
  color: var(--text-inverse);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.featured-overlay h5 a:hover {
  color: var(--accent-gold-light);
  text-decoration: underline;
}

.featured-overlay small {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.85rem;
}

.featured-overlay small i {
  color: var(--accent-gold);
  margin-right: 0.3rem;
}

/* Blog Cards - aligned with main card styling */
.blog-card {
  background: var(--card-bg);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  height: 100%;
  border: none;
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.blog-card-img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

.blog-no-image {
  background: var(--hero-gradient);
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-inverse);
  font-size: 2rem;
}

.blog-card-content {
  padding: 1.5rem;
}

/* Category badge - using secondary color */
.blog-category {
  background: var(--secondary);
  color: var(--text-inverse);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 1rem;
  border-radius: 50px;
  display: inline-block;
  margin-bottom: 0.8rem;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.2s ease;
}

.blog-category:hover {
  background: var(--primary);
  color: var(--text-inverse);
  transform: translateY(-1px);
  text-decoration: none;
}

/* Blog title - using main typography */
.blog-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.8rem;
  line-height: 1.4;
}

.blog-title a {
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.blog-title a:hover {
  color: var(--primary);
  text-decoration: underline;
}

/* Blog meta - using muted text color */
.blog-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-light);
}

.blog-meta i {
  color: var(--accent-gold);
  margin-right: 0.3rem;
}

.blog-meta span {
  margin-right: 1rem;
}

/* Read more button - using main link styles */
.blog-read-more {
  color: var(--secondary);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s ease;
}

.blog-read-more:hover {
  color: var(--primary);
  gap: 0.8rem;
  text-decoration: underline;
}

/* Sidebar - aligned with main sidebar-widget */
.sidebar-box {
  background: var(--sidebar-bg);
  border-radius: 8px;
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--secondary);
  transition: all 0.3s ease;
  margin-bottom: 1.5rem;
}

.sidebar-box:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.sidebar-box h4 {
  color: var(--primary-dark);
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  margin-bottom: 1.25rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--accent-gold);
  font-weight: 600;
}

/* Sidebar lists */
.sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-list li {
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border-light);
  transition: all 0.2s ease;
}

.sidebar-list li:last-child {
  border-bottom: none;
}

.sidebar-list li:hover {
  background-color: var(--active-bg);
  padding-left: 8px;
  margin-left: -8px;
  border-radius: 4px;
}

.sidebar-list a {
  color: var(--text-secondary);
  text-decoration: none;
  display: block;
  transition: color 0.2s ease;
}

.sidebar-list a:hover {
  color: var(--primary);
}

/* Popular items - aligned with main design */
.popular-item {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-light);
  transition: all 0.2s ease;
}

.popular-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.popular-item:hover {
  transform: translateX(4px);
}

.popular-link {
  color: var(--text-primary);
  font-weight: 500;
  text-decoration: none;
  display: block;
  margin-bottom: 0.25rem;
  transition: color 0.2s ease;
}

.popular-link:hover {
  color: var(--primary);
  text-decoration: underline;
}

.popular-item small {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.popular-item small i {
  color: var(--accent-gold);
  margin-right: 0.3rem;
}

/* Pagination - using main button styles */
.pagination {
  margin-top: 2rem;
  gap: 0.25rem;
}

.pagination .page-link {
  color: var(--secondary);
  border: 1px solid var(--border-medium);
  margin: 0;
  border-radius: 6px;
  padding: 0.5rem 1rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.pagination .page-link:hover {
  background-color: var(--active-bg);
  color: var(--primary);
  border-color: var(--secondary);
  transform: translateY(-2px);
}

.pagination .page-link:focus {
  outline: 3px solid var(--focus-outline);
  outline-offset: 2px;
  box-shadow: none;
}

.pagination .active .page-link {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--text-inverse);
}

.pagination .active .page-link:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

/* Blog single post styles (if needed) */
.blog-post {
  background: var(--card-bg);
  border-radius: 10px;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}

.blog-post h1 {
  color: var(--primary-dark);
  margin-bottom: 1rem;
}

.blog-post-meta {
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 1rem;
  margin-bottom: 1.5rem;
}

.blog-post-content {
  color: var(--text-primary);
  line-height: 1.8;
}

.blog-post-content img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 1.5rem 0;
}

.blog-post-content blockquote {
  border-left: 4px solid var(--accent-gold);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  background: var(--accent-gold-soft);
  font-style: italic;
  border-radius: 0 8px 8px 0;
}

/* Responsive Design - aligned with main breakpoints */
@media (max-width: 768px) {
  .blog-hero {
    padding: 40px 0;
    text-align: center;
  }
  
  .blog-hero .lead {
    margin-left: auto;
    margin-right: auto;
  }
  
  .featured-card {
    height: 200px;
  }
  
  .blog-card-img,
  .blog-no-image {
    height: 180px;
  }
  
  .blog-card-content {
    padding: 1.25rem;
  }
  
  .blog-post {
    padding: 1.25rem;
  }
  
  .sidebar-box {
    padding: 1.25rem;
  }
}

@media (max-width: 576px) {
  .blog-card-img,
  .blog-no-image {
    height: auto;
  }
  
  .blog-title {
    font-size: 1.1rem;
  }
  
  .pagination .page-link {
    padding: 0.4rem 0.8rem;
    font-size: 0.9rem;
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  .blog-card,
  .featured-card,
  .sidebar-box,
  .blog-category,
  .popular-item {
    transition: none;
  }
  
  .blog-card:hover,
  .featured-card:hover,
  .sidebar-box:hover {
    transform: none;
  }
}

/* Dark mode support for blog */
@media (prefers-color-scheme: dark) {
  .blog-card {
    background: var(--card-bg);
  }
  
  .blog-card-content {
    background: var(--card-bg);
  }
  
  .sidebar-box {
    background: var(--sidebar-bg);
  }
  
  .blog-post {
    background: var(--card-bg);
  }
  
  .blog-post-content blockquote {
    background: rgba(184, 141, 58, 0.1);
  }
}

/* Print styles for blog */
@media print {
  .blog-hero,
  .blog-search,
  .sidebar-box,
  .pagination {
    display: none;
  }
  
  .blog-card {
    box-shadow: none;
    border: 1px solid #ddd;
    break-inside: avoid;
  }
  
  .blog-post {
    padding: 0;
    box-shadow: none;
  }
  
  .blog-read-more {
    display: none;
  }
}