/* Blog-specific styles */

/* Article content styling */
.article-content {
  line-height: 1.7;
  font-size: 1.1rem;
}

.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6 {
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-weight: 600;
  line-height: 1.3;
}

.article-content h1 {
  font-size: 2rem;
}

.article-content h2 {
  font-size: 1.75rem;
}

.article-content h3 {
  font-size: 1.5rem;
}

.article-content h4 {
  font-size: 1.25rem;
}

.article-content p {
  margin-bottom: 1.5rem;
}

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

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

.article-content blockquote {
  border-left: 4px solid var(--bs-primary);
  padding-left: 1.5rem;
  margin: 2rem 0;
  font-style: italic;
  color: var(--bs-secondary);
}

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

.article-content pre {
  background-color: var(--bs-gray-100);
  border-radius: 0.5rem;
  padding: 1rem;
  overflow-x: auto;
  margin: 2rem 0;
}

.article-content code {
  background-color: var(--bs-gray-100);
  padding: 0.2rem 0.4rem;
  border-radius: 0.25rem;
  font-size: 0.9rem;
}

.article-content pre code {
  background-color: transparent;
  padding: 0;
}

/* Table of contents */
.toc {
  font-size: 0.9rem;
}

.toc ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.toc li {
  margin-bottom: 0.5rem;
}

.toc a {
  color: var(--bs-gray-700);
  text-decoration: none;
  padding: 0.25rem 0;
  display: block;
  border-radius: 0.25rem;
  transition: all 0.2s ease;
}

.toc a:hover {
  color: var(--bs-primary);
  background-color: var(--bs-primary-bg-subtle);
  padding-left: 0.5rem;
}

.toc ul ul {
  padding-left: 1.5rem;
  margin-top: 0.5rem;
}

/* Blog card hover effects */
.card-hover {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

/* Zoom effect for images */
.zoom-effect-wrapper {
  overflow: hidden;
  border-radius: inherit;
}

.zoom-effect-img {
  transition: transform 0.5s ease;
}

.zoom-effect:hover .zoom-effect-img {
  transform: scale(1.05);
}

/* Breadcrumb styling */
.breadcrumb {
  background-color: transparent;
  padding: 0;
  margin: 0;
}

.breadcrumb-item + .breadcrumb-item::before {
  content: "›";
  color: var(--bs-gray-500);
}

/* Tag badges */
.badge {
  font-size: 0.75rem;
  font-weight: 500;
}

/* Pagination styling */
.pagination .page-link {
  border: none;
  margin: 0 2px;
  border-radius: 0.5rem;
  color: var(--bs-gray-700);
  transition: all 0.2s ease;
}

.pagination .page-link:hover {
  background-color: var(--bs-primary);
  color: white;
  transform: translateY(-1px);
}

.pagination .page-item.active .page-link {
  background-color: var(--bs-primary);
  border-color: var(--bs-primary);
}

/* Category and tag pages */
.category-header,
.tag-header {
  background: linear-gradient(135deg, var(--bs-primary) 0%, var(--bs-primary-dark) 100%);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .article-content {
    font-size: 1rem;
  }
  
  .article-content h1 {
    font-size: 1.75rem;
  }
  
  .article-content h2 {
    font-size: 1.5rem;
  }
  
  .article-content h3 {
    font-size: 1.25rem;
  }
}

/* Dark mode adjustments */
[data-bs-theme="dark"] .article-content pre {
  background-color: var(--bs-gray-800);
}

[data-bs-theme="dark"] .article-content code {
  background-color: var(--bs-gray-800);
}

[data-bs-theme="dark"] .toc a {
  color: var(--bs-gray-300);
}

[data-bs-theme="dark"] .toc a:hover {
  color: var(--bs-primary);
  background-color: rgba(var(--bs-primary-rgb), 0.1);
}

/* Blog hero section adjustments */
.blog-hero {
  position: relative;
  overflow: hidden;
}

.blog-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.6) 100%);
  z-index: 1;
}

.blog-hero .container {
  position: relative;
  z-index: 2;
}

/* Reading progress indicator */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background-color: var(--bs-primary);
  z-index: 9999;
  transition: width 0.2s ease;
}

/* Social share buttons */
.social-share .btn {
  transition: all 0.2s ease;
}

.social-share .btn:hover {
  transform: translateY(-2px);
}

/* Related posts */
.related-posts .card {
  transition: all 0.3s ease;
}

.related-posts .card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

/* Search styling */
.search-form {
  position: relative;
}

.search-form input {
  padding-right: 3rem;
}

.search-form button {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: none;
  color: var(--bs-gray-500);
}

/* Loading state */
.loading {
  opacity: 0.6;
  pointer-events: none;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Focus styles for accessibility */
.btn:focus,
.card:focus,
a:focus {
  outline: 2px solid var(--bs-primary);
  outline-offset: 2px;
}

/* Print styles */
@media print {
  .navbar,
  .footer,
  .sidebar,
  .social-share,
  .pagination,
  .btn-scroll-top {
    display: none !important;
  }
  
  .article-content {
    font-size: 12pt;
    line-height: 1.4;
  }
  
  .article-content a {
    color: inherit !important;
    text-decoration: underline;
  }
}