/* Blogs / journal listing page (from "Blog list redesign") */

body.listing-page,
body.listing-page html {
  background-color: var(--bg);
}

html:has(body.listing-page) {
  background-color: var(--bg);
}

.listing-page .page-wrapper {
  background: var(--bg);
  font-family: var(--sans);
  letter-spacing: -0.02em;
}

.listing-page #Navbar-home,
.listing-page #Navbar-blogs,
.listing-page #Navbar-diary,
.listing-page .links {
  color: var(--body);
}

.listing-page #Navbar-blogs:hover,
.listing-page #Navbar-diary:hover {
  color: var(--title);
}

/* Hero */
.listing-hero {
  position: relative;
  height: 356px;
  background-color: var(--bg);
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
}

.listing-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 40%, var(--bg) 100%);
}

.listing-hero-blogs {
  background-image: url('/assets/images/Laptop_keyboard-1.jpg');
  background-position: center bottom;
}

.listing-hero-journal {
  background-image: url('/assets/images/IMG_3334.jpg');
}

.listing-title {
  position: absolute;
  z-index: 2;
  left: 94px;
  bottom: 6px;
  margin: 0;
  font-size: 72px;
  line-height: 1;
  font-weight: 800;
  color: var(--accent);
}

.listing-description {
  margin: 4px 0 0;
  padding: 0 94px;
  font-size: 24px;
  font-weight: 600;
  color: var(--body);
}

/* Post list */
.listing-posts {
  list-style: none;
  margin: 72px auto 0;
  padding: 0 24px 120px;
  max-width: 720px;
  width: 100%;
  box-sizing: border-box;
}

.listing-posts li {
  border-top: 1px solid var(--line);
}

.listing-posts li:last-child {
  border-bottom: 1px solid var(--line);
}

.listing-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 0;
  color: inherit;
  text-decoration: none;
  transition: opacity 0.2s;
}

.listing-row:hover {
  opacity: 0.7;
}

.listing-row-title {
  font-size: 28px;
  font-weight: 600;
  color: var(--title);
  line-height: 1.2;
  text-wrap: pretty;
}

.listing-row-meta {
  font-size: 16px;
  color: var(--muted);
  white-space: nowrap;
  letter-spacing: 0;
}

.listing-empty {
  padding: 26px 0;
  font-size: 18px;
  color: var(--muted);
}

@media (max-width: 768px) {
  .listing-hero { height: 240px; }
  .listing-title { left: 24px; font-size: 48px; }
  .listing-description { padding: 0 24px; font-size: 18px; }
  .listing-posts { margin-top: 40px; }
  .listing-row { flex-direction: column; gap: 6px; padding: 20px 0; }
  .listing-row-title { font-size: 22px; }
  .listing-row-meta { font-size: 14px; }
}
