/* Unified sidebar layout for post and home pages */
.layout--post .page-with-sidebar,
.layout--home .page-with-sidebar {
  display: flex !important;
  margin: 2rem auto 0 !important;
  width: 100% !important;
  padding: 0 !important;
  gap: 2rem !important;
  flex-direction: row !important;
  margin-top: 2rem;
}

.layout--post .content-area,
.layout--home .content-area {
  flex: 1 1 auto !important;
  min-width: 0 !important;
}

.layout--post .custom-sidebar-wrapper,
.layout--home .custom-sidebar-wrapper {
  flex: 0 0 300px !important;
  position: relative !important;
}

.layout--post .custom-sidebar,
.layout--home .custom-sidebar {
  position: sticky !important;
  top: 2em !important;
  width: 300px !important;
}

/* Home page sidebar positioning */
.layout--home .sidebar {
  float: right !important;
  width: 300px !important;
  padding-left: 2rem !important;
}

.layout--home .archive {
}

/* Fix for YAML front matter on home */
.layout--home .archive > hr,
.layout--home .archive > p:first-of-type {
  display: none !important;
}

/* Post sidebar styling (used by both layouts) */
.post-sidebar { font-size: 0.85rem; } /* Sidebar dates font size */
.post-sidebar h3 { margin-top: 0; }
.post-sidebar .ps-years, .post-sidebar .ps-months, .post-sidebar .ps-posts { list-style: none; margin: 0; padding-left: 0.5rem; }
.post-sidebar details summary { cursor: pointer; }
.post-sidebar .ps-post a { color: inherit; text-decoration: none; font-size: 0.70rem; } /* Sidebar posts names font size */
.post-sidebar .ps-post a:hover { text-decoration: underline; }

/* Responsive: stack on narrow viewports */
@media (max-width: 880px) {
  .layout--post .page-with-sidebar, .layout--home .page-with-sidebar { display: block !important; }
  .layout--post .custom-sidebar-wrapper, .layout--home .custom-sidebar-wrapper { width: auto !important; }
  .layout--post .custom-sidebar, .layout--home .custom-sidebar { position: relative !important; top: auto; margin-left: 0 !important; }
}


#main {
  max-width: none !important;
  padding: 0 5rem !important;
}

/* Bio Sidebar Styles */
.custom-bio-sidebar-wrapper {
  flex: 0 0 200px; /* Adjust width as needed */
}

.sidebar-author {
  text-align: left;
}

.author__avatar {
  border-radius: 50%;
  width: 100px;
  height: 100px;
  object-fit: cover;
  margin-bottom: 1rem;
}

.author__name {
  margin: 0;
  font-size: 1.2rem;
  font-weight: bold;
}

.author__bio {
  font-size: 0.9rem;
  color: #666;
}

/* Author Links */
.author__urls {
  list-style-type: none;
  margin: 0.5rem 0 0;
  padding: 0;
}

.author__url a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: inherit;
  text-decoration: none;
  font-size: 0.75rem;
}

.author__url a:hover {
  text-decoration: underline;
}

.author__url {
  margin-bottom: 0.1rem;
}