html, body {
  margin: 0;
  padding: 0;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  font-family: var(--font-family-base);
  font-weight: 400;
  background-color: var(--color-bg);
  color: var(--color-text);
}

/* Base link colour. :where() keeps specificity at zero, so buttons and nav links keep their own colours. */
:where(a, a:visited) {
  color: var(--color-link);
}

/* Post titles are links, but read as headings rather than copper link text. */
.post-header h1 a,
.post-header h1 a:visited {
  color: var(--color-text);
}

.container {
  display: flex;
}

.main-content {
  flex: 1;

  .wide-2 {
    width: 20%;
  }

  .wide-6 {
    width: 60%;
  }

  h1 {
    text-align: center;
  }
}

h1, h2, h3, h4, h5, h6 {
  line-height: 1;
}

h1 {
  font-size: 4em;
  letter-spacing: -2px;
  margin-bottom: 30px;
}

h2 {
  font-size: 2.25em;
  letter-spacing: -1px;
  margin-bottom: 20px;
  font-weight: normal;
  color: var(--color-text);
}

h3 {
  font-size: 1.80em;
  letter-spacing: -1px;
  margin-bottom: 20px;
  font-weight: normal;
}


/* Flash notifications */
.notification-banner {
  width: 100%;
  padding: 0 1rem;

  .notification {
    padding: 0.75rem 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
    font-size: 1rem;

    &.is-success {
      background-color: #d4edda;
      color: #155724;
      border: 1px solid #c3e6cb;
    }

    &.is-warning {
      background-color: #fff3cd;
      color: #856404;
      border: 1px solid #ffc107;
    }

    &.is-danger {
      background-color: #f8d7da;
      color: #721c24;
      border: 1px solid #f5c6cb;
    }
  }
}

/* Paragraph CSS */
p {
  font-size: 1.2em;
  line-height: 1.75em;
}

/* Post header row: date and collection on the left, admin Edit button on the right.
   Wraps so the button drops below the details on narrow screens. */
.post-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
