/* docs.spellship.com: layout and article styles, on top of the shared styles.css. */
.docs-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 24px;
}

.docs-brand img {
  height: 32px;
  width: auto;
}

.docs-top {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 15px;
}

.docs-top a:not(.btn) {
  text-decoration: none;
}

.docs-top a:not(.btn):hover {
  text-decoration: underline;
}

.docs-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 56px;
  align-items: start;
  padding-bottom: 72px;
}

.docs-nav {
  position: sticky;
  top: 24px;
  padding-top: 16px;
  font-size: 15px;
}

.docs-nav-title {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ss-muted);
}

.docs-nav ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.docs-nav a {
  display: block;
  padding: 7px 12px;
  border-left: 2px solid var(--ss-line);
  color: var(--ss-text);
  text-decoration: none;
}

.docs-nav a:hover {
  background: var(--ss-tint);
}

.docs-nav a[aria-current="page"] {
  border-left-color: var(--ss-accent);
  background: var(--ss-tint);
  color: var(--ss-accent-strong);
  font-weight: 600;
}

.doc,
.tutorial {
  min-width: 0;
}

.doc {
  max-width: 46em;
  padding-block: 16px 0;
}

.doc h1 {
  color: var(--ss-text);
  font-size: clamp(32px, 4.6vw, 48px);
}

.doc .lead {
  color: var(--ss-muted);
}

.doc h2 {
  margin-top: 48px;
  font-size: 26px;
  scroll-margin-top: 24px;
}

.doc h3 {
  margin-top: 28px;
  font-size: 19px;
}

.doc p,
.doc li {
  color: var(--ss-text);
}

.doc ul,
.doc ol {
  padding-left: 24px;
}

.doc li + li {
  margin-top: 10px;
}

.doc code {
  font-size: 0.92em;
  overflow-wrap: anywhere;
}

.doc-toc {
  margin-top: 32px;
  padding: 18px 22px;
  border: 1px solid var(--ss-line);
  border-radius: var(--radius);
  background: #fff;
}

.doc-toc ul {
  margin: 0;
}

.doc-steps {
  padding-left: 24px;
}

.doc-steps li::marker {
  font-family: var(--display);
  font-weight: 600;
  color: var(--ss-accent);
}

.doc-table-wrap {
  margin: 14px 0;
  overflow-x: auto;
}

.doc table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  background: #fff;
}

.doc th,
.doc td {
  padding: 10px 14px;
  border: 1px solid var(--ss-line);
  text-align: left;
  vertical-align: top;
}

.doc th {
  background: var(--ss-tint);
}

.doc-callout {
  margin: 24px 0;
  padding: 16px 20px;
  border: 1px solid #ffd99b;
  border-left: 4px solid var(--ss-sparkle);
  border-radius: 12px;
  background: #fff8ea;
}

.doc-note {
  margin-top: 40px;
  color: var(--ss-muted);
}

.guide-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-top: 40px;
}

.guide-card {
  display: block;
  padding: 24px;
  border: 1px solid var(--ss-line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ss-text);
  text-decoration: none;
  transition:
    border-color 0.15s,
    transform 0.15s;
}

.guide-card:hover {
  border-color: var(--ss-accent);
  transform: translateY(-2px);
}

.guide-card h2 {
  font-size: 22px;
}

.guide-card p {
  margin: 10px 0 0;
  color: var(--ss-muted);
}

@media (max-width: 800px) {
  .docs-layout {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .docs-nav {
    position: static;
    padding-top: 0;
  }
  .docs-nav ul {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }
  .docs-nav a {
    border: 1px solid var(--ss-line);
    border-radius: 999px;
    padding: 6px 14px;
  }
  .docs-nav-title {
    display: none;
  }
}
