.site-main {
  min-height: 60vh;
  padding-block: clamp(2.5rem, 6vw, 5rem);
}

.page-header,
.entry,
.error-404 {
  max-width: var(--content-width);
  margin-inline: auto;
}

.post-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.post-card {
  padding: 1.25rem;
  border: 1px solid var(--color-border);
  border-radius: 0.75rem;
  background: var(--color-surface);
}

.post-card__image img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 0.45rem;
}

.post-card__title {
  font-size: 1.35rem;
}

.post-card__title a {
  color: inherit;
}

.post-card__title a:is(:hover, :focus-visible) {
  color: var(--color-primary);
}

.post-card__excerpt {
  color: var(--color-muted);
}

.entry__featured-image {
  margin-block: 2rem;
}

.site-main.page-content {
  display: flow-root;
  padding-block: 0;
}

.site-main.page-content:has(
    > :first-child:not(.toc, .content-section, .content-spacer, script, style)
  ) {
  padding-top: var(--spacing-block-large);
}

.site-main.page-content:has(
    > :last-child:not(.toc, .content-section, .content-spacer, script, style)
  ) {
  padding-bottom: var(--spacing-block-large);
}

.page-content > :not(.toc, .content-section, .content-spacer, script, style) {
  width: calc(100% - (var(--site-gutter) * 2));
  max-width: var(--site-width);
  margin-inline: auto;
}

.page-content > .entry__featured-image:first-child {
  margin-top: 0;
}

.entry__content > * {
  max-width: 100%;
}

:where(p:not([class]), ul:not([class]), ol:not([class])) {
  margin: 0;
}

:where(p:not([class]), ul:not([class]), ol:not([class])):not(:first-child) {
  margin-top: 0.5em;
}

:where(p:not([class]), ul:not([class]), ol:not([class])):not(:last-child) {
  margin-bottom: 0.5em;
}

:where(ul:not([class]), ol:not([class])) {
  display: grid;
  gap: 0.625rem;
  padding-block: 0;
  padding-inline-start: 0;
  list-style: none;
}

:where(ul:not([class]), ol:not([class])) > li {
  min-width: 0;
  padding-inline-start: 1.5rem;
}

:where(ul:not([class]), ol:not([class])) > li::before {
  position: relative;
  top: 0.5lh;
  display: inline-block;
  width: 1rem;
  height: 1rem;
  margin-inline: -1.5rem 0.5rem;
  transform: translateY(-50%);
}

ul:not([class]) > li::before {
  border-radius: 0.1875rem;
  background: var(--color-success) var(--icon-check-mark) center / contain
    no-repeat;
  content: '';
}

ol:not([class]) {
  counter-reset: content-list;
}

ol:not([class]) > li {
  counter-increment: content-list;
}

ol:not([class]) > li::before {
  color: var(--color-primary);
  content: counter(content-list);
  font-weight: 700;
  line-height: 1;
  text-align: center;
}

:where(
  h2:not([class]),
  h3:not([class]),
  h4:not([class]),
  h5:not([class]),
  h6:not([class])
) {
  margin: 0;
}

:where(
  h2:not([class]),
  h3:not([class]),
  h4:not([class]),
  h5:not([class]),
  h6:not([class])
):not(:first-child) {
  margin-top: var(--spacing-block-medium);
}

:where(
  h2:not([class]),
  h3:not([class]),
  h4:not([class]),
  h5:not([class]),
  h6:not([class])
):not(:last-child) {
  margin-bottom: 0.5em;
}

:is(h2, h3) :is(i, em) {
  font-style: inherit;
  color: var(--color-muted);
}
