/* Custom styles for the blog */

/* Consistent grey background color for all pages */
body {
  background: #f8f9fa !important;
}

/* Override theme variables to ensure grey background everywhere */
:root {
  --theme: #f8f9fa !important;
  --entry: #f8f9fa !important;
}


/* Ensure main content areas have consistent background */
.main,
article,
.post-single,
.post-content {
  background: #f8f9fa !important;
}

/* Improve readability of body text */
.post-content {
  font-size: 1.1rem;
  line-height: 1.8;
}

/* Style blockquotes */
.post-content blockquote {
  border-left: 4px solid var(--tertiary, #4a6cf7);
  padding-left: 1.25rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: var(--secondary, #555);
}

/* Math blocks styling */
.katex-display {
  overflow-x: auto;
  overflow-y: hidden;
  padding: 1rem 0;
}

/* Inline code */
.post-content code:not([class*="language-"]) {
  background: var(--code-bg, #f5f5f5);
  padding: 0.2em 0.4em;
  border-radius: 4px;
  font-size: 0.9em;
}

/* Code blocks */
.post-content pre {
  border-radius: 8px;
  padding: 1rem;
  overflow-x: auto;
}

/* Images */
.post-content img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 1.5rem 0;
}

/* Figure captions */
.post-content figcaption {
  text-align: center;
  font-size: 0.9rem;
  color: var(--secondary, #666);
  margin-top: 0.5rem;
}

/* Tables */
.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}

.post-content th,
.post-content td {
  border: 1px solid var(--border, #ddd);
  padding: 0.75rem;
  text-align: left;
}

.post-content th {
  background: var(--code-bg, #f5f5f5);
  font-weight: 600;
}

.post-content tr:hover {
  background: var(--code-bg, #f9f9f9);
}

/* Horizontal rules */
.post-content hr {
  border: none;
  border-top: 2px solid var(--border, #eee);
  margin: 2rem 0;
}


/* Footnotes */
.post-content .footnotes {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border, #eee);
  font-size: 0.9rem;
}


/* Animation for page load */
.main {
  animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Homepage entry footer styling */
.entry-footer {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 0.5rem;
  font-size: 0.9rem;
}

.entry-date {
  color: var(--secondary, #666);
}

/* Tag links styling for homepage */
.tag-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag-links a {
  background: var(--code-bg, #f5f5f5);
  color: var(--primary, #333);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  text-decoration: none;
  font-size: 0.85rem;
  transition: background-color 0.2s ease;
}

.tag-links a:hover {
  background: var(--tertiary, #e8e8e8);
}

