/* The rules of the user guide's pages, beside those of base.css. */

* {
  font-family: "Lucida Grande", Verdana, Helvetica, sans-serif;
  font-size: 15px;
}

body {
  color: rgb(204,204,204);
}

a[href] {
  color: rgb(179,208,237);
  text-decoration: underline;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: normal;
  color: white;
  clear: both;
}

h1, h2 {
  border-bottom: 1px solid rgb(99,130,160);
  margin-bottom: 0.25em;
  line-height: 1.3;
}

h2 {
  margin-top: 1.5em;
  margin-bottom: 0em;
}

h3 {
  margin-top: 0.5em;
}

h3, h4, h5, h6 {
  padding-top: 0.5em;
  line-height: 1.6;
}

h4, h5, h6 {
  margin-top: 0.3em;
}

h3, h4, h5 {
  font-weight: bold;
}

h6 {
  font-style: italic;
}

h1 {
  font-size: 34px;
}

h2 {
  font-size: 30px;
}

h3 {
  font-size: 22px;
  color: rgb(179,208,237);
}

h4 {
  font-size: 16px;
}

p {
  line-height: 1.5em;
  margin: 0.8em 0em;
}

ul, ol {
  line-height: 1.5em;
  margin-left: 1.5em;
}

code, pre {
  font-family: Consolas, Menlo, Monaco, "Lucida Console", "Liberation Mono", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Courier New", monospace;
  background: rgb(26,26,26);
  white-space: pre-wrap;
  word-wrap: break-word;
  box-decoration-break: clone;
  padding: .1rem .3rem .2rem;
  border-radius: .2rem;
}

table {
  border-collapse: collapse;
}

td {
  border: 1.5px solid rgb(99, 130, 160);
  padding: 0.5em;
}

.document-breadcrumbs {
  display: flex;
  flex-direction: row;
}

.document-breadcrumb-segment, .document-breadcrumb-segment a {
  color: rgb(166,166,166);
}

/* A row of its own below the header's logo and breadcrumbs. */
.version-notice {
  grid-column: 1 / -1;
  justify-self: center;
  margin: 8px 10px 0 10px;
  padding: 6px 16px;
  border: 2px solid rgb(255,138,0);
  border-radius: 6px;
  color: white;
}

.version-notice.stable {
  border-color: rgb(99,130,160);
}

/* The section index gets a column of fixed width, so that the page's column keeps its width from page to page. */
.document-container {
  display: grid;
  grid-template-columns: minmax(160px, 320px) minmax(auto, 900px) 260px;
  grid-column-gap: 20px;
  align-items: start;

  padding: 10px 0 10px 0;
  background-color: rgba(33,34,36,0.7);
}

.document-tree {
  justify-self: right;
}

.document-tree ul {
  list-style: none;
}

.document-tree a {
  font-size: 16px;
  color: rgb(204,204,204);
  line-height: 1em;
  text-decoration: none;
}

.document-tree a:hover {
  color: rgb(204,204,204);
}

.document-tree div {
  padding: 0 8px 2px 8px;
  margin: 6px 0 6px 0;
}

.document-tree div:hover {
  background-color: rgb(99,130,160);
}

.document-tree div.active {
  background-color: rgb(99,130,160);
}

.document-main {
  padding: 1.25em;
}

.toc-title {
  color: white;
  font-weight: bold;
  line-height: 1.6;
}

.user-guide-index {
  position: sticky;
  top: 10px;
  max-height: calc(100vh - 20px);
  overflow-y: auto;
  padding: 1.25em 20px 12px 0;
}

.user-guide-index ul {
  list-style: none;
  margin-left: 0;
}

/* A wrapped entry indents its further lines, so that they don't read as entries of their own. */
.user-guide-index li {
  line-height: 1.25;
  margin: 0.4em 0 0 0;
  padding-left: 1em;
  text-indent: -1em;
}

/* The h3 entries start beyond the further lines of the h2 entries. */
.user-guide-index ul ul {
  margin-left: 1em;
}

.user-guide-index a {
  color: rgb(204,204,204);
  text-decoration: none;
}

.user-guide-index a:hover {
  color: white;
}

.markdown-alert {
  border: 1.5px solid rgb(99, 130, 160);
  background-color: rgb(26,26,26);
  padding: 10px;
  border-radius: 6px;
  margin: 0.8em 0;
}

.markdown-alert p:first-child {
  margin-top: 0;
}

.markdown-alert p:last-child {
  margin-bottom: 0;
}

.markdown-alert-title {
  color: white;
  font-weight: bold;
}

.document-content strong {
  color: white;
}

/* An icon opens its paragraph, and the text flows beside it. The next block starts below the icon. */
.document-content img.icon {
  float: left;
  margin: 0 8px 8px 0;
}

/* Icons that follow each other in a row touch, as a group of buttons does. */
.document-content img.icon:has(+ img.icon) {
  margin-right: 0;
}

.document-content p.icon-row, .document-content p.icon-row + * {
  clear: left;
}

/* Nothing follows the row within a list item, so the row contains its icon. */
.document-content li > p.icon-row {
  display: flow-root;
}

/* The blocks after the image flow beside it until the next heading, which clears it. */
.document-content img.float-left, .document-content video.float-left {
  float: left;
  margin: 0.3em 1.25em 0.8em 0;
}

/* An image with a size suffix of width and height keeps its aspect ratio where max-width narrows it. */
.document-content img, .document-content video {
  max-width: 100%;
  height: auto;
}

.document-content video {
  display: block;
}

.document-content table {
  margin: 0.8em 0;
}

.document-content th {
  border: 1.5px solid rgb(99, 130, 160);
  padding: 0.5em;
  color: white;
  font-weight: bold;
  text-align: left;
}

.document-content pre {
  padding: 0.5em;
  margin: 0.8em 0;
}

.document-content pre code {
  padding: 0;
  background: none;
}
