/* ── layout ── */
body {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 1rem;
}

header nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
  border-bottom: 1px solid var(--pico-muted-border-color);
  margin-bottom: 2rem;
}

header nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.5rem;
}

.site-title {
  font-weight: bold;
  font-size: 1.1rem;
  text-decoration: none;
}

footer {
  margin-top: 3rem;
  padding: 1.5rem 0;
  border-top: 1px solid var(--pico-muted-border-color);
  text-align: center;
  font-size: 0.9rem;
}

/* ── hero ── */
.site-hero {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  height: 420px;
  overflow: hidden;
  margin-bottom: 2.5rem;
}

.site-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
  display: block;
}

/* ── post header ── */
.post-header {
  margin-bottom: 1.5rem;
}

.post-header h1 {
  margin-bottom: 0.25rem;
}

.post-meta {
  color: var(--pico-muted-color);
  font-size: 0.9rem;
}

.post-meta .categories a {
  margin-right: 0.5rem;
}

/* ── images ── */
img {
  max-width: 100%;
  height: auto;
}

figure {
  margin: 1.5rem 0;
}

figcaption, .wp-element-caption {
  font-size: 0.875rem;
  color: var(--pico-muted-color);
  margin-top: 0.4rem;
  font-style: italic;
}

/* ── gallery ── */
.wp-block-gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1.5rem 0;
}

.wp-block-gallery figure {
  margin: 0;
  flex: 1 1 200px;
}

.wp-block-gallery figure img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

/* ── tiled gallery ── */
.wp-block-jetpack-tiled-gallery {
  margin: 1.5rem 0;
}

.tiled-gallery__gallery {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.tiled-gallery__row {
  display: flex;
  gap: 0.25rem;
}

.tiled-gallery__col {
  overflow: hidden;
}

.tiled-gallery__item img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

/* ── embeds ── */
.wp-block-embed__wrapper {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
}

.wp-block-embed__wrapper iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
}

/* ── pagefind component UI ── */

/* Reduce the library's boxed "Search... ⌘K" trigger to an icon-only button
   matching the weight of the other nav links. Its button is plain light DOM
   (no shadow part), and the library boosts its own rules' specificity with
   :is(*, #\#) x3, so overriding it needs a real selector plus !important. */
.nav-search-trigger .pf-trigger-btn {
  all: unset !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 2rem !important;
  height: 2rem !important;
  color: var(--pico-primary) !important;
  cursor: pointer !important;
}

.nav-search-trigger .pf-trigger-btn:hover {
  opacity: 0.7 !important;
}

.nav-search-trigger .pf-trigger-icon {
  width: 20px !important;
  height: 20px !important;
  background: currentColor !important;
}

.nav-search-trigger .pf-trigger-text,
.nav-search-trigger .pf-trigger-shortcut {
  display: none !important;
}

/* ── inline image alignment ── */
.alignright {
  float: right;
  margin: 0 0 1rem 1.5rem;
}

/* ── multi-column layout ── */
.wp-block-columns {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin: 1.5rem 0;
}

.wp-block-column {
  flex: 1 1 0;
  min-width: 0;
}

/* ── file download button ── */
.wp-element-button {
  display: inline-block;
  padding: 0.4rem 1rem;
  background: var(--pico-primary);
  color: var(--pico-primary-inverse);
  border-radius: var(--pico-border-radius, 4px);
  text-decoration: none;
  font-size: 0.9rem;
}

.wp-element-button:hover {
  opacity: 0.85;
}

/* ── misc ── */
.song-marker {
  font-style: normal;
  font-weight: bold;
  color: var(--pico-muted-color);
}

blockquote {
  border-left: 3px solid var(--pico-primary);
  padding-left: 1rem;
  margin-left: 0;
  color: var(--pico-muted-color);
}

/* ── home / archive ── */
.post-list {
  list-style: none;
  padding: 0;
}

.post-list li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--pico-muted-border-color);
  display: flex;
  gap: 1rem;
  align-items: baseline;
}

/* archive lists sit under a date heading — no need for the date column */
.archive-day-heading + .post-list li {
  padding: 0.35rem 0;
}

.post-list .post-date {
  color: var(--pico-muted-color);
  font-size: 0.875rem;
  white-space: nowrap;
  min-width: 6rem;
}

.archive-day-heading {
  margin: 1.25rem 0 0.25rem;
  font-size: 0.875rem;
  color: var(--pico-muted-color);
  font-weight: normal;
  border-bottom: 1px solid var(--pico-muted-border-color);
  padding-bottom: 0.2rem;
}

/* ── home / featured posts ── */
.featured-posts {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin: 1.5rem 0 2rem;
}

.featured-post {
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--pico-muted-border-color);
}

.featured-post:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.featured-post-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.featured-post-thumb {
  flex: 0 0 auto;
  display: block;
  width: 64px;
  height: 64px;
  overflow: hidden;
  border-radius: var(--pico-border-radius, 4px);
}

.featured-post-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.featured-post-heading {
  min-width: 0;
}

.featured-post-heading h2 {
  margin: 0;
  font-size: 1.15rem;
}

.featured-post-excerpt {
  margin: 0.5rem 0;
  color: var(--pico-color);
}

.featured-post-more {
  font-size: 0.9rem;
}

.pagination {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin: 2rem 0;
}
