.docs .content-container {
  @apply px-8 lg:pl-0 xl:pr-0;
  @apply mx-auto min-h-[100vh];
  max-width: min(var(--container-max-width), 100vw);
}

.docs .docs-container {
  @apply pt-8 lg:pt-5;
  @apply min-w-48;

  @screen lg {
    /* approx 85ch, but since the contents use font-sizes in absolute values,
       we need to use an absolute value here too */
    max-width: 850px;
  }
}

.docs article a {
  color: var(--interactive-text-color);
  text-decoration: underline;
}

.docs article blockquote {
  background: var(--blockquote-bg-color);
  padding: 20px 13px 20px 10px;
  border-left: 10px solid #ac7ef4;
  margin: 30px 0;
}

.docs article blockquote p:first-child {
  margin-top: 0;
}

.docs article blockquote p:last-child {
  margin-bottom: 0;
}

.docs article a:hover {
  text-decoration: none;
}

.docs article .card-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 25px;
  margin: 30px 0;
}

.docs article .card {
  background: var(--bg-secondary-color);
  border-radius: 10px;
  min-width: 230px;
  padding: 25px;
  flex: 1;
  color: inherit;
  text-decoration: none;
}

.docs article a.card:hover {
  outline: 2px solid var(--interactive-text-color);
}

.docs article .card-center {
  text-align: center;
}

.docs article .card h3 {
  margin-top: 10px;
  margin-bottom: 0;
  font-weight: 500;
  font-size: 22px;
}

.docs article .card p {
  font-size: 14px;
}

.docs article .card .icon {
  font-size: 70px;
  margin: 0;
  line-height: 1;
}

.docs article .card .intro-icon {
  position: relative;
  margin: auto;
}

.docs article h1 {
  @apply mb-7;
  @apply relative;

  line-height: 1.2;
  font-size: 55px;
  font-weight: 800;
  scroll-margin-top: var(--scroll-margin-top);
}

.docs article h2,
.docs article h3,
.docs article h4,
.docs article h5,
.docs article h6 {
  @apply text-xl font-semibold;
  @apply relative;
  margin-top: 1.2em;
  scroll-margin-top: var(--scroll-margin-top);

  margin-bottom: max(0.7em, 18px);
}

.docs article h2 {
  line-height: 1.2;
  font-size: 42px;
  font-weight: 800;
  scroll-margin-top: var(--scroll-margin-top);
  margin-top: 45px;
}

.docs article h3 {
  font-size: 1.8rem;
}

.docs h2 a,
.docs h3 a,
.docs h4 a,
.docs h5 a,
.docs h6 a {
  position: absolute;
  width: 100%;
  height: 1em;
}

.icon-link {
  display: none;
}

.icon-link::after {
  position: absolute;
  content: '#';
  left: -1em;
}

h2 a:hover .icon,
h3 a:hover .icon,
h4 a:hover .icon,
h5 a:hover .icon,
h6 a:hover .icon {
  display: inline;
}

.docs article p {
  margin-top: 1.6rem;
  margin-bottom: 0.9rem;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7;
  color: var(--secondary-text-color);
}

.docs article ul,
.docs article ol {
  @apply my-4;
  @apply ml-10;
  line-height: 1.7;
  list-style: disc;

  font-size: 16px;
  font-weight: 400;
  color: var(--secondary-text-color);
}

.docs article ol {
  list-style: decimal;
}

.docs article li {
  @apply my-1;
  @apply pl-2;
}

.docs article li::marker,
.docs article li::-webkit-details-marker {
  color: var(--interactive-text-color);
  font-weight: 800;
}

[data-rehype-pretty-code-fragment] {
  overflow: auto;
  color: white;
  background-color: rgb(1 31 51);
  border-radius: 8px;
  margin: 20px 0;
}

[data-rehype-pretty-code-fragment] pre {
  overflow: auto;
  border-radius: 8px;
  max-height: var(--pretty-code-fragment-max-height);
}

[data-rehype-pretty-code-title] {
  padding: 5px 15px;
  background: #4199d3;
  font-family: monospace;
  font-weight: bold;
}

.docs article pre {
  padding: 18px 15px;
  overflow: auto;
}

:root {
  --code-line-height: 24px;
}

.docs article pre code {
  display: grid;
  counter-reset: line;
  background-color: transparent;
  border: none;
  user-select: auto;
  line-height: 1.28;
}

.docs article code {
  background-color: var(--code-bg-color);
  padding: 2px 4px;
  border-radius: 3px;
  font-size: 0.9em;
  border-bottom: 2px solid var(--code-border-color);
  user-select: all;
}

@media (max-width: 640px) {
  .docs article code {
    word-break: break-all;
  }
  .docs article h1 {
    font-size: 40px;
  }
  .docs article h2 {
    font-size: 30px;
  }
}

.docs article table {
  @apply my-5;
}

.docs article th,
.docs article td {
  padding: 6px;
  vertical-align: top;
}

.docs article th:first-child,
.docs article td:first-child {
  padding-left: 0;
}

.docs article th:last-child,
.docs article td:last-child {
  padding-right: 0;
}

.docs article img {
  border-radius: 5px;
  overflow: hidden;
}
