/* ===== ENHANCEMENTS STYLESHEET ===== */

/* Dark Mode Base */
:root {
  --bg-primary: #ffffff;
  --bg-secondary: #f9fafb;
  --text-primary: #1f2937;
  --text-secondary: #6b7280;
  --border-color: #e5e7eb;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

html.dark {
  --bg-primary: #1f2937;
  --bg-secondary: #111827;
  --text-primary: #f9fafb;
  --text-secondary: #d1d5db;
  --border-color: #374151;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
}

/* Better tap targets for mobile */
@media (max-width: 768px) {
  button, a, input[type="submit"], [role="button"] {
    min-height: 44px;
    min-width: 44px;
  }
}

/* ===== SEARCH & FILTER STYLES ===== */
.search-enhanced {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  animation: slideDown 0.3s ease-out;
  border-radius: 12px;
  padding: 1rem;
  box-shadow: var(--shadow-md);
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.search-enhanced input,
.search-enhanced select {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  border-color: var(--border-color);
  transition: all 0.3s ease;
}

.search-enhanced input:focus,
.search-enhanced select:focus {
  background-color: var(--bg-primary);
  color: var(--text-primary);
}

#search-input::placeholder {
  color: var(--text-secondary);
}

.search-results-container {
  animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.search-result-item {
  background: var(--bg-primary);
  color: var(--text-primary);
  border-left: 4px solid #2563eb;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.search-result-item:hover {
  transform: translateX(4px);
  box-shadow: var(--shadow-md);
}

.search-result-item .badge {
  background: #dbeafe;
  color: #1e40af;
  font-weight: 600;
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
}

html.dark .search-result-item .badge {
  background: #1e3a8a;
  color: #bfdbfe;
}

.search-result-item a {
  color: #2563eb;
  text-decoration: none;
  font-weight: 600;
}

html.dark .search-result-item a {
  color: #60a5fa;
}

/* ===== BOOKMARK SYSTEM STYLES ===== */
.bookmark-btn {
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border: 1px solid transparent;
}

.bookmark-btn:hover {
  color: #ef4444;
  background-color: rgba(239, 68, 68, 0.1);
}

.bookmark-btn.active {
  color: #ef4444;
  fill: currentColor;
}

.bookmark-btn.active svg {
  fill: currentColor;
}

/* ===== PAGINATION STYLES ===== */
.pagination,
.pagination-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin: 2rem 0;
  flex-wrap: wrap;
}

.page-btn,
.prev-btn,
.next-btn {
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border: 1px solid var(--border-color);
  background-color: var(--bg-secondary);
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.2s ease;
  font-weight: 500;
}

.page-btn:hover:not(:disabled),
.prev-btn:hover:not(:disabled),
.next-btn:hover:not(:disabled) {
  background-color: #2563eb;
  color: white;
  border-color: #2563eb;
}

.page-btn.active {
  background-color: #2563eb;
  color: white;
  border-color: #2563eb;
}

.page-btn:disabled,
.prev-btn:disabled,
.next-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ===== BREADCRUMB STYLES ===== */
.breadcrumb {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.breadcrumb a {
  color: #2563eb;
  text-decoration: none;
  transition: color 0.2s ease;
}

html.dark .breadcrumb a {
  color: #60a5fa;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

/* ===== RELATED CONTENT STYLES ===== */
.related-content {
  background: var(--bg-secondary);
  padding: 2rem;
  border-radius: 1rem;
  margin-top: 3rem;
}

.related-content h3 {
  color: var(--text-primary);
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.related-content a {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  padding: 1rem;
  border-radius: 0.5rem;
  text-decoration: none;
  transition: all 0.3s ease;
  display: block;
}

.related-content a:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: #2563eb;
}

.related-content h4 {
  color: #2563eb;
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

html.dark .related-content h4 {
  color: #60a5fa;
}

.related-content p {
  color: var(--text-secondary);
  font-size: 0.875rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ===== ACTIVE FILTERS BADGE ===== */
#active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.filter-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #dbeafe;
  color: #1e40af;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
}

html.dark .filter-badge {
  background: #1e3a8a;
  color: #bfdbfe;
}

.filter-badge button {
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  padding: 0;
  font-weight: bold;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.search-result-item {
  animation: fadeInUp 0.3s ease-out forwards;
}

.search-result-item:nth-child(1) { animation-delay: 0s; }
.search-result-item:nth-child(2) { animation-delay: 0.05s; }
.search-result-item:nth-child(3) { animation-delay: 0.1s; }
.search-result-item:nth-child(n+4) { animation-delay: 0.15s; }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .search-enhanced {
    padding: 1rem;
  }

  .search-enhanced > div {
    flex-direction: column;
  }

  .search-enhanced select,
  .search-enhanced button {
    width: 100%;
  }

  .related-content {
    padding: 1rem;
  }

  .related-content {
    grid-template-columns: 1fr;
  }

  .pagination-controls {
    flex-direction: column;
    gap: 1rem;
  }
}

/* ===== THEME TOGGLE BUTTON ===== */
#theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
}

#theme-toggle button {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  padding: 0.5rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

#theme-toggle button:hover {
  background: #2563eb;
  color: white;
  border-color: #2563eb;
}

/* ===== UTILITY CLASSES ===== */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.animated-card {
  animation: slideUp 0.4s ease-out;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== LOADING STATE ===== */
.loading {
  opacity: 0.6;
  pointer-events: none;
}

.spinner {
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 2px solid var(--border-color);
  border-top-color: #2563eb;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;

/* ===== NEWS CARD STYLES ===== */
.news-card {
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  will-change: transform;
  border: 1px solid transparent;
}

.news-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

/* Visible focus for keyboard users */
.news-card:focus {
  outline: none;
}

.news-card:focus-visible {
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.18), var(--shadow-md);
  transform: translateY(-2px);
  border-color: rgba(99, 102, 241, 0.35);
}

/* Thumbnail placed on the right */
.news-card .thumb-wrapper {
  flex: 0 0 160px;
  max-width: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.news-card .thumb-wrapper img {
  width: 140px;
  height: 96px;
  object-fit: cover;
  border-radius: 0.5rem;
  display: block;
}

.news-card .source-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: transparent;
  color: var(--text-secondary);
  font-size: 0.75rem;
}

.news-card .source-badge img {
  width: 28px;
  height: 28px;
  object-fit: contain;
  border-radius: 9999px;
  background: rgba(255,255,255,0.04);
  padding: 2px;
}

@media (max-width: 768px) {
  .news-card .thumb-wrapper {
    flex: 0 0 96px;
    max-width: 96px;
  }

  .news-card .thumb-wrapper img {
    width: 88px;
    height: 60px;
  }
}
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ===== BLOG ENHANCEMENTS ===== */

/* Blog article cards */
.content-card {
  transition: all 0.3s ease;
}

.content-card:hover {
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Read more button states */
.read-more-btn {
  position: relative;
  overflow: hidden;
}

.read-more-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.read-more-btn:hover::before {
  left: 100%;
}

.read-more-btn.active {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  transform: scale(1.02);
}

.read-more-btn.active:hover {
  background: linear-gradient(135deg, #b91c1c, #991b1b);
}

/* Expanded footer spacing */
.item-footer.expanded {
  margin-top: 2rem !important;
  padding-top: 1.5rem !important;
  border-top: 2px solid #e5e7eb !important;
  animation: expandFooter 0.3s ease-out;
}

@keyframes expandFooter {
  from {
    margin-top: 1.5rem;
    padding-top: 1rem;
    opacity: 0.8;
  }
  to {
    margin-top: 2rem;
    padding-top: 1.5rem;
    opacity: 1;
  }
}

/* Content preview styling */
.content-preview {
  animation: fadeInContent 0.3s ease-out;
}

@keyframes fadeInContent {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Prose styling for blog content */
.prose {
  color: var(--text-primary);
}

.prose p {
  margin-bottom: 1rem;
  line-height: 1.7;
}

.prose strong {
  font-weight: 600;
  color: var(--text-primary);
}

/* Line clamp utility */
.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.6;
}

/* Improved prose styling for blog content */
.prose {
  color: #374151;
  font-size: 1rem;
  line-height: 1.75;
}

.prose p {
  margin-bottom: 1.25rem;
  line-height: 1.75;
}

.prose p:last-child {
  margin-bottom: 0;
}

.prose strong, .prose b {
  font-weight: 600;
  color: #111827;
}

.prose em, .prose i {
  font-style: italic;
  color: #4b5563;
}

.prose code {
  background-color: #f3f4f6;
  padding: 0.125rem 0.25rem;
  border-radius: 0.25rem;
  font-size: 0.875em;
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  color: #dc2626;
}

.prose pre {
  background-color: #f3f4f6;
  padding: 1rem;
  border-radius: 0.5rem;
  overflow-x: auto;
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  font-size: 0.875em;
  line-height: 1.5;
  margin: 1.25rem 0;
}

.prose pre code {
  background: none;
  padding: 0;
  border-radius: 0;
  color: inherit;
}

.prose blockquote {
  border-left: 4px solid #e5e7eb;
  padding-left: 1rem;
  margin: 1.5rem 0;
  color: #6b7280;
  font-style: italic;
}

.prose ul, .prose ol {
  margin: 1.25rem 0;
  padding-left: 1.5rem;
}

.prose li {
  margin-bottom: 0.5rem;
  line-height: 1.6;
}

.prose h1, .prose h2, .prose h3, .prose h4, .prose h5, .prose h6 {
  color: #111827;
  font-weight: 600;
  margin: 1.5rem 0 1rem 0;
}

.prose h1 {
  font-size: 1.875rem;
  line-height: 2.25rem;
}

.prose h2 {
  font-size: 1.5rem;
  line-height: 2rem;
}

.prose h3 {
  font-size: 1.25rem;
  line-height: 1.75rem;
}

.prose a {
  color: #4f46e5;
  text-decoration: underline;
  transition: color 0.2s ease;
}

.prose a:hover {
  color: #3730a3;
}

/* Content preview container */
.content-preview-text {
  font-size: 1rem;
  line-height: 1.75;
  color: #374151;
}

/* Better spacing for blog content */
.content-preview {
  background: #fafafa;
  border-radius: 0.5rem;
  padding: 1.5rem;
  margin-top: 1rem;
}

/* Fix for line-clamp in different browsers */
@supports (-webkit-line-clamp: 3) {
  .line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
}

@supports not (-webkit-line-clamp: 3) {
  .line-clamp-3 {
    display: block;
    max-height: calc(1.6em * 3 * 1.2);
    overflow: hidden;
    position: relative;
  }

  .line-clamp-3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1.2em;
    background: linear-gradient(to bottom, transparent, white);
  }
}
.blog-spinner {
  justify-content: center;
  padding: 2rem;
}

/* Responsive blog layout */
@media (max-width: 768px) {
  .content-card {
    margin-bottom: 1rem;
  }

  .item-footer {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 1rem;
  }

  .read-more-btn {
    width: 100%;
    justify-content: center;
  }
}

/* Blog search and filter enhancements */
.blog-filters {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 1rem;
  padding: 2rem;
  margin-bottom: 2rem;
  color: white;
}

.blog-filters input,
.blog-filters select {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  border-radius: 0.5rem;
}

.blog-filters input::placeholder {
  color: rgba(255, 255, 255, 0.7);
}

.blog-filters input:focus,
.blog-filters select:focus {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

/* Blog statistics */
.blog-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.blog-stat-card {
  background: white;
  border-radius: 1rem;
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
}

.blog-stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
}

.blog-stat-number {
  font-size: 2.5rem;
  font-weight: bold;
  color: #4f46e5;
  margin-bottom: 0.5rem;
}

.blog-stat-label {
  color: #6b7280;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ===== MODERN BLOG STYLES ===== */

/* Hero Section */
.blog-hero {
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 50%, #1e40af 100%);
    position: relative;
    overflow: hidden;
}

.blog-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.03"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.03"/><circle cx="50" cy="10" r="0.5" fill="white" opacity="0.02"/><circle cx="90" cy="40" r="0.5" fill="white" opacity="0.02"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    pointer-events: none;
}

/* Category Filters */
.category-filter {
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.category-filter:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Blog Post Cards */
.blog-post {
    transition: all 0.3s ease;
    border-radius: 12px;
}

.blog-post:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.blog-post img {
    transition: transform 0.3s ease;
}

.blog-post:hover img {
    transform: scale(1.05);
}

/* Search Bar */
#blog-search {
    transition: all 0.3s ease;
}

#blog-search:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Newsletter Section */
.newsletter-section {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

/* Responsive Design */
@media (max-width: 768px) {
    .blog-hero h1 {
        font-size: 2.5rem !important;
    }

    .category-filter {
        padding: 0.5rem 1rem;
        font-size: 0.875rem;
    }

    #blog-posts {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

@media (max-width: 640px) {
    .blog-hero {
        padding: 3rem 0;
    }

    .blog-hero h1 {
        font-size: 2rem !important;
    }

    .category-filter {
        padding: 0.375rem 0.75rem;
        font-size: 0.8rem;
    }
}

/* ===== BLOG ENHANCEMENTS ===== */

/* Blog Content Enhancements */
.blog-content {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.7;
    color: #374151;
}

.blog-content h1,
.blog-content h2,
.blog-content h3,
.blog-content h4,
.blog-content h5,
.blog-content h6 {
    color: #1f2937;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.blog-content h1 { font-size: 2.25rem; }
.blog-content h2 { font-size: 1.875rem; }
.blog-content h3 { font-size: 1.5rem; }
.blog-content h4 { font-size: 1.25rem; }
.blog-content h5 { font-size: 1.125rem; }
.blog-content h6 { font-size: 1rem; }

.blog-content p {
    margin-bottom: 1.5rem;
    text-align: justify;
}

.blog-content ul,
.blog-content ol {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.blog-content li {
    margin-bottom: 0.5rem;
}

.blog-content blockquote {
    border-left: 4px solid #e5e7eb;
    padding-left: 1rem;
    margin: 2rem 0;
    font-style: italic;
    color: #6b7280;
}

.blog-content code {
    background-color: #f3f4f6;
    padding: 0.125rem 0.25rem;
    border-radius: 0.25rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875em;
}

.blog-content pre {
    background-color: #f3f4f6;
    padding: 1rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin: 1.5rem 0;
}

.blog-content pre code {
    background-color: transparent;
    padding: 0;
}

.blog-content a {
    color: #3b82f6;
    text-decoration: underline;
}

.blog-content a:hover {
    color: #1d4ed8;
}

.blog-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1.5rem 0;
}

.blog-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}

.blog-content th,
.blog-content td {
    border: 1px solid #e5e7eb;
    padding: 0.75rem;
    text-align: left;
}

.blog-content th {
    background-color: #f9fafb;
    font-weight: 600;
}

/* Enhanced line-clamp utilities */
.line-clamp-2 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.line-clamp-3 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
}

.line-clamp-4 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  line-clamp: 4;
}

/* ===== MODAL STYLES ===== */

/* Modal backdrop */
#blog-article-modal {
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

/* Modal content styling */
#blog-article-modal .prose {
    max-width: none;
    font-size: 1.1rem;
    line-height: 1.8;
}

#blog-article-modal .prose p {
    margin-bottom: 1.5rem;
}

#blog-article-modal .prose h1,
#blog-article-modal .prose h2,
#blog-article-modal .prose h3,
#blog-article-modal .prose h4,
#blog-article-modal .prose h5,
#blog-article-modal .prose h6 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #1f2937;
}

#blog-article-modal .prose h1 {
    font-size: 2rem;
    line-height: 2.5rem;
}

#blog-article-modal .prose h2 {
    font-size: 1.75rem;
    line-height: 2.25rem;
}

#blog-article-modal .prose h3 {
    font-size: 1.5rem;
    line-height: 2rem;
}

#blog-article-modal .prose blockquote {
    border-left: 4px solid #3b82f6;
    background-color: #f8fafc;
    padding: 1rem 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: #475569;
}

#blog-article-modal .prose code {
    background-color: #f1f5f9;
    color: #dc2626;
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem;
    font-size: 0.9em;
}

#blog-article-modal .prose pre {
    background-color: #1e293b;
    color: #e2e8f0;
    padding: 1.5rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin: 2rem 0;
}

#blog-article-modal .prose pre code {
    background: none;
    color: inherit;
    padding: 0;
}

#blog-article-modal .prose ul,
#blog-article-modal .prose ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

#blog-article-modal .prose li {
    margin-bottom: 0.75rem;
    line-height: 1.7;
}

#blog-article-modal .prose a {
    color: #2563eb;
    text-decoration: underline;
    font-weight: 500;
}

#blog-article-modal .prose a:hover {
    color: #1d4ed8;
}

/* Modal animations */
#blog-article-modal .bg-white {
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Close button hover effects */
#close-modal:hover {
    background-color: #f3f4f6;
    transform: rotate(90deg);
    transition: all 0.2s ease;
}

/* Responsive modal adjustments */
@media (max-width: 768px) {
    #blog-article-modal .max-w-4xl {
        margin: 1rem;
        max-height: 95vh;
    }

    #blog-article-modal .p-6 {
        padding: 1rem;
    }

    #blog-article-modal .prose {
        font-size: 1rem;
    }

    #blog-article-modal .prose h1 {
        font-size: 1.75rem;
    }

    #blog-article-modal .prose h2 {
        font-size: 1.5rem;
    }
}

/* ===== LOAD MORE ANIMATIONS ===== */

/* Hidden posts animation */
.blog-post.hidden {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.blog-post:not(.hidden) {
    opacity: 1;
    transform: translateY(0);
}

/* Load more button animations */
#load-more-btn {
    transition: all 0.3s ease;
}

#load-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(59, 130, 246, 0.4);
}

#load-more-btn:active {
    transform: translateY(0);
}
