/* The dev diary, on the home page and on each app's diary page. Also loaded by the engines with
   their own layout, so it keeps to the colors of the page around it. */
/* Above the entries, or in a modal's title bar */
.dev-diary-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;

  nav {
    display: flex;
    gap: 0.5rem;
    font-size: 0.8em;
    font-weight: normal;

    a.current {
      font-weight: bold;
      text-decoration: underline;
    }
  }
}

/* The title bar's space between the close button and it goes to the heading, its links by the button */
.modal-title:has(> .dev-diary-heading) {
  flex: 1;
  padding-right: 1rem;

  h2 { margin: 0; }
}

.dev-diary {
  max-width: 42rem;

  article {
    padding: 0.8rem 0;
    border-top: 1px solid color-mix(in srgb, currentColor 20%, transparent);

    .meta {
      margin: 0;
      font-size: 0.8em;
      opacity: 0.7;
    }

    h3 {
      margin: 0.2em 0 0.4em;
      font-size: 1.05em;
    }

    p:not(.meta) {
      margin: 0 0 0.6em;
      line-height: 1.5;
    }
  }
}

/* An app's diary page, whatever room its own pages give their main (Elite Dangerous gives it none) */
body.diary.show > main {
  padding: 1em 2em;
}
