/* 
 * Blogs Page Styles
 * Contains all styles specific to the blogs listing and single blog pages
 */

/* Blogs hero section */
.blogs-hero {
  background-color: #f8f9fa;
  padding: 5rem 0;
  text-align: center;
}

.blogs-hero h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.blogs-hero p {
  font-size: 1.25rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 2rem;
}

/* Blog listing section */
.blog-listing {
  padding: 5rem 0;
}

.blog-filters {
  margin-bottom: 3rem;
}

.blog-filters .form-select {
  width: auto;
  display: inline-block;
  margin-right: 1rem;
  margin-bottom: 1rem;
}

.blog-filters .search-form {
  display: flex;
  max-width: 400px;
}

.blog-filters .search-form .form-control {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.blog-filters .search-form .btn {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

/* Blog card */
.blog-card {
  margin-bottom: 2rem;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.blog-card:hover {
  transform: translateY(-5px);
}

.blog-card .blog-image {
  height: 200px;
  overflow: hidden;
}

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

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

.blog-card .blog-content {
  padding: 1.5rem;
}

.blog-card .blog-category {
  display: inline-block;
  background-color: #e9ecef;
  color: #495057;
  font-size: 0.8rem;
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  margin-bottom: 1rem;
}

.blog-card .blog-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.blog-card .blog-excerpt {
  color: #6c757d;
  margin-bottom: 1.5rem;
}

.blog-card .blog-meta {
  display: flex;
  justify-content: space-between;
  color: #6c757d;
  font-size: 0.9rem;
}

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

.blog-card .blog-author img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  margin-right: 0.5rem;
}

/* Pagination */
.blog-pagination {
  margin-top: 3rem;
  display: flex;
  justify-content: center;
}

.blog-pagination .page-item.active .page-link {
  background-color: #0056b3;
  border-color: #0056b3;
}

.blog-pagination .page-link {
  color: #0056b3;
}

/* Single blog post */
.single-blog {
  padding: 5rem 0;
}

.blog-header {
  margin-bottom: 3rem;
}

.blog-header .blog-category {
  display: inline-block;
  background-color: #e9ecef;
  color: #495057;
  font-size: 0.9rem;
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  margin-bottom: 1rem;
}

.blog-header .blog-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.blog-header .blog-meta {
  display: flex;
  align-items: center;
  color: #6c757d;
}

.blog-header .blog-author {
  display: flex;
  align-items: center;
  margin-right: 2rem;
}

.blog-header .blog-author img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin-right: 0.75rem;
}

.blog-featured-image {
  margin-bottom: 3rem;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.blog-featured-image img {
  width: 100%;
}

.blog-content {
  margin-bottom: 3rem;
}

.blog-content h2 {
  margin-top: 2.5rem;
  margin-bottom: 1.5rem;
}

.blog-content h3 {
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.blog-content p {
  margin-bottom: 1.5rem;
  line-height: 1.8;
}

.blog-content blockquote {
  border-left: 4px solid #0056b3;
  padding-left: 1.5rem;
  font-style: italic;
  margin: 2rem 0;
}

.blog-content ul, .blog-content ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.blog-content li {
  margin-bottom: 0.5rem;
}

.blog-content img {
  max-width: 100%;
  border-radius: 0.5rem;
  margin: 2rem 0;
}

.blog-tags {
  margin-bottom: 3rem;
}

.blog-tags .tag {
  display: inline-block;
  background-color: #e9ecef;
  color: #495057;
  font-size: 0.9rem;
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.blog-tags .tag:hover {
  background-color: #dee2e6;
}

.blog-share {
  margin-bottom: 3rem;
}

.blog-share h4 {
  margin-bottom: 1rem;
}

.blog-share .social-links {
  display: flex;
  gap: 1rem;
}

.blog-share .social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #e9ecef;
  color: #495057;
  font-size: 1.25rem;
  transition: all 0.2s ease;
}

.blog-share .social-links a:hover {
  background-color: #0056b3;
  color: #fff;
}

.blog-author-bio {
  background-color: #f8f9fa;
  padding: 2rem;
  border-radius: 0.5rem;
  margin-bottom: 3rem;
  display: flex;
  align-items: center;
}

.blog-author-bio img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  margin-right: 2rem;
}

.blog-author-bio .author-info h4 {
  margin-bottom: 0.5rem;
}

.blog-author-bio .author-info p {
  margin-bottom: 1rem;
}

.blog-author-bio .author-info .social-links {
  display: flex;
  gap: 1rem;
}

.blog-author-bio .author-info .social-links a {
  color: #0056b3;
  font-size: 1.25rem;
}

.related-posts {
  margin-bottom: 3rem;
}

.related-posts h3 {
  margin-bottom: 2rem;
  text-align: center;
}

/* Comments section */
.blog-comments {
  margin-bottom: 3rem;
}

.blog-comments h3 {
  margin-bottom: 2rem;
}

.comment {
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid #e9ecef;
}

.comment:last-child {
  border-bottom: none;
}

.comment .comment-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.comment .comment-author {
  display: flex;
  align-items: center;
}

.comment .comment-author img {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  margin-right: 1rem;
}

.comment .comment-author h5 {
  margin-bottom: 0.25rem;
}

.comment .comment-author .comment-date {
  color: #6c757d;
  font-size: 0.9rem;
}

.comment .comment-content {
  margin-bottom: 1rem;
}

.comment .comment-actions a {
  color: #0056b3;
  margin-right: 1rem;
  text-decoration: none;
}

.comment .comment-actions a:hover {
  text-decoration: underline;
}

.comment-replies {
  margin-left: 3rem;
  margin-top: 2rem;
}

.comment-form {
  background-color: #f8f9fa;
  padding: 2rem;
  border-radius: 0.5rem;
}

.comment-form h4 {
  margin-bottom: 1.5rem;
}

.comment-form .form-group {
  margin-bottom: 1.5rem;
}

.comment-form textarea.form-control {
  min-height: 150px;
}

/* Social Share Sidebar - Fixed positioning without overflow */
.social-share-sidebar {
  position: sticky;
  top: 120px;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 10;
  max-width: 60px;
  margin-left: auto;
  margin-right: auto;
}

.social-share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  margin-bottom: 10px;
  border-radius: 50%;
  transition: all 0.3s ease;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.social-share-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  text-decoration: none;
}

.social-share-btn.linkedin {
  background: #0077b5;
  color: white;
}

.social-share-btn.linkedin:hover {
  background: #005885;
  color: white;
}

.social-share-btn.facebook {
  background: #1877f2;
  color: white;
}

.social-share-btn.facebook:hover {
  background: #166fe5;
  color: white;
}

.social-share-btn.twitter {
  background: #000000;
  color: white;
}

.social-share-btn.twitter:hover {
  background: #333333;
  color: white;
}

/* Mobile Social Share - Inline positioning to prevent overflow */
.social-share-mobile {
  display: flex;
  gap: 15px;
  margin-top: 15px;
  justify-content: flex-start;
  flex-wrap: wrap;
}

.social-share-btn-mobile {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  transition: all 0.3s ease;
  text-decoration: none;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.social-share-btn-mobile:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
  text-decoration: none;
}

.social-share-btn-mobile.linkedin {
  background: #0077b5;
  color: white;
}

.social-share-btn-mobile.linkedin:hover {
  background: #005885;
  color: white;
}

.social-share-btn-mobile.facebook {
  background: #1877f2;
  color: white;
}

.social-share-btn-mobile.facebook:hover {
  background: #166fe5;
  color: white;
}

.social-share-btn-mobile.twitter {
  background: #000000;
  color: white;
}

.social-share-btn-mobile.twitter:hover {
  background: #333333;
  color: white;
}

/* Responsive styles */
@media (max-width: 991.98px) {
  .blog-author-bio {
    flex-direction: column;
    text-align: center;
  }
  
  .blog-author-bio img {
    margin-right: 0;
    margin-bottom: 1.5rem;
  }
  
  .blog-author-bio .author-info .social-links {
    justify-content: center;
  }
  
  /* Hide desktop social sidebar on tablets and mobile */
  .social-share-sidebar {
    display: none;
  }
}

@media (max-width: 767.98px) {
  .blogs-hero h1 {
    font-size: 2.5rem;
  }
  
  .blogs-hero p {
    font-size: 1.1rem;
  }
  
  .blog-header .blog-title {
    font-size: 2rem;
  }
  
  .blog-header .blog-meta {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .blog-header .blog-author {
    margin-right: 0;
    margin-bottom: 0.5rem;
  }
  
  .comment .comment-header {
    flex-direction: column;
  }
  
  .comment-replies {
    margin-left: 1.5rem;
  }
  
  /* Mobile social icons adjustments */
  .social-share-mobile {
    justify-content: center;
    margin-top: 20px;
    padding: 15px 0;
    border-top: 1px solid #e9ecef;
  }
  
  .social-share-btn-mobile {
    width: 45px;
    height: 45px;
  }
  
  /* Ensure social icons don't cause horizontal scroll */
  .social-share-mobile, .social-share-sidebar {
    max-width: 100%;
    overflow: hidden;
  }
}