/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family:
    Inter, Roboto, "Helvetica Neue", "Arial Nova", "Nimbus Sans", Arial,
    sans-serif;
  line-height: 1.6;
  color: #333;
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
}

/* Navigation */
nav {
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

nav a {
  margin-right: 1rem;
  text-decoration: none;
  color: #007acc;
}

nav a:hover {
  text-decoration: underline;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  margin-bottom: 1rem;
  line-height: 1.2;
}

h1 {
  font-size: 2rem;
}

h2 {
  font-size: 1.5rem;
}

p {
  margin-bottom: 1rem;
}

/* Post previews */
.post-preview {
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

.post-link {
  display: block;
  text-decoration: none;
  color: inherit;
  transition: background-color 0.2s ease;
  padding: 1rem;
  margin: -1rem;
  border-radius: 8px;
}

.post-link:hover {
  background-color: #f8f9fa;
}

.post-link h2 {
  color: #333;
  transition: color 0.2s ease;
}

.post-link:hover h2 {
  color: #007acc;
}

.read-more {
  color: #007acc;
  font-weight: 600;
  margin-top: 0.5rem;
  margin-bottom: 0 !important;
}

/* Post meta */
.meta {
  color: #666;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.reading-time:before {
  content: " • ";
}

/* Tags */
.tags {
  margin: 0.5rem 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  display: inline-block;
  background: #f0f7ff;
  color: #0066cc;
  padding: 0.2rem 0.5rem;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 500;
  border: 1px solid #cce7ff;
}

/* Post content */
.post-content,
.page-content {
  line-height: 1.7;
}

.post-content h1,
.post-content h2,
.post-content h3,
.page-content h1,
.page-content h2,
.page-content h3 {
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.post-content code,
.page-content code {
  background: #f5f5f5;
  padding: 0.2rem 0.4rem;
  border-radius: 3px;
  font-family:
    ui-monospace, "Cascadia Code", "Source Code Pro", Menlo, Consolas,
    "DejaVu Sans Mono", monospace;
}

.post-content pre,
.page-content pre {
  background: #f5f5f5;
  padding: 1rem;
  border-radius: 5px;
  overflow-x: auto;
  margin: 1rem 0;
}

.post-content blockquote,
.page-content blockquote {
  border-left: 4px solid #007acc;
  margin: 1rem 0;
  padding-left: 1rem;
  color: #666;
}

/* Post navigation */
.post-nav {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
}

.post-nav a {
  text-decoration: none;
  color: #007acc;
}

/* Images */
.post-content img,
.page-content img {
  max-width: 300px;
  height: auto;
  float: right;
  margin: 0 0 1rem 1.5rem;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.post-content img:hover,
.page-content img:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Ensure proper text flow around floated images */
.post-content::after,
.page-content::after {
  content: "";
  display: table;
  clear: both;
}

/* Responsive: stack images on smaller screens */
@media (max-width: 600px) {
  .post-content img,
  .page-content img {
    float: none;
    display: block;
    margin: 1rem auto;
    max-width: 100%;
  }
}

/* Footer */
footer {
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
  text-align: center;
  color: #666;
  font-size: 0.9rem;
}
