/* SPDX-License-Identifier: BUSL-1.1 | Copyright (c) 2026 LPStation. All rights reserved. */
/* The docs page, on the landing's tokens and type (../style.css): a table of contents beside one readable column. */
.docs-links { display: flex; align-items: center; gap: 24px; font-size: 14px; color: var(--muted); }
.docs-links a:hover { color: var(--text); }
.docs-links a[aria-current="page"] { color: var(--text); }

.docs-shell { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 64px; padding-block: 24px 112px; }

/* table of contents: sticky beside the text on a wide screen, a fold above it on a narrow one */
.docs-toc { position: sticky; top: 24px; align-self: start; max-height: calc(100vh - 48px); overflow: auto; padding-bottom: 24px; font-size: 14px; }
.docs-toc h4 { margin: 24px 0 8px; font: 500 11px/1.4 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
.docs-toc h4:first-child { margin-top: 0; }
.docs-toc a { display: block; padding: 5px 12px; border-left: 2px solid var(--line-strong); border-radius: 0 8px 8px 0; color: var(--muted); line-height: 1.45; transition: color .15s, background .15s, border-color .15s; }
.docs-toc a:hover { color: var(--text); }
.docs-toc a.on { color: var(--mint); font-weight: 500; background: #78e5ae14; border-left-color: var(--mint); }
.toc-fold { display: none; margin: 0 0 8px; border: 1px solid var(--line-strong); border-radius: 14px; background: var(--surface); }
.toc-fold summary { padding: 12px 16px; font-size: 14px; font-weight: 500; cursor: pointer; list-style: none; }
.toc-fold summary::-webkit-details-marker { display: none; }
.toc-fold summary::after { content: '+'; float: right; color: var(--dim); }
.toc-fold[open] summary::after { content: '−'; color: var(--mint); }
.toc-fold .docs-toc { position: static; max-height: none; padding: 0 16px 16px; }

/* the text */
.docs { min-width: 0; }
/* text keeps a reading width; a .wide figure takes the column's full width beside it */
.docs > .toc-fold, .docs section > :not(.wide) { max-width: 780px; }
.docs h1 { margin: 0 0 14px; font-size: 46px; font-weight: 600; letter-spacing: -1.6px; line-height: 1.08; text-wrap: balance; }
.docs .lead { margin: 0; font-size: 19px; line-height: 1.6; color: var(--muted); }
.docs section { padding-top: 64px; scroll-margin-top: 16px; }
.docs h2 { margin: 0 0 14px; font-size: 30px; font-weight: 600; letter-spacing: -.8px; line-height: 1.2; text-wrap: balance; }
.docs h3 { margin: 40px 0 10px; font-size: 20px; font-weight: 600; letter-spacing: -.3px; line-height: 1.3; scroll-margin-top: 16px; }
.docs p, .docs li, .docs dd { color: #c4c4cc; font-size: 16px; line-height: 1.75; }
.docs p { margin: 0 0 14px; }
.docs ul, .docs ol { margin: 0 0 14px; padding-left: 22px; }
.docs li { margin: 4px 0; padding-left: 2px; }
.docs li::marker { color: var(--dim); }
.docs strong { color: var(--text); font-weight: 550; }
.docs a.inline { color: var(--mint); text-decoration: underline; text-decoration-color: #78e5ae55; text-underline-offset: 3px; }
.docs a.inline:hover { text-decoration-color: var(--mint); }
.eyebrow-sm { display: inline-block; margin-bottom: 10px; font: 500 12px var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--mint); }

/* "not a vault": the one thing to take from the page, said once in a box of its own */
.callout { margin: 24px 0 8px; padding: 18px 22px; border: 1px solid #78e5ae3d; border-radius: 16px; background: #78e5ae0b; }
.callout p { margin: 0; color: var(--text); }
.callout strong { color: var(--mint); }
/* Permit2: the one habit the Safety section asks of the reader */
.callout.permit { margin: 22px 0; padding: 22px 24px; }
.callout.permit h3 { margin: 0 0 10px; color: var(--mint); }
.callout.permit p { margin-bottom: 10px; }
.callout.permit ul { margin: 0; }
.callout.permit li { color: var(--text); }

.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 24px 0 8px; }
.card { padding: 18px 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.card b { display: block; margin-bottom: 4px; font-size: 16px; font-weight: 600; color: var(--text); }
.card span { display: block; font-size: 14.5px; line-height: 1.6; color: var(--muted); }

.backed { margin: 28px 0 8px; padding: 22px 24px; border: 1px solid var(--line-strong); border-radius: 16px; background: var(--surface); }
.backed h3 { margin: 0 0 12px; }
.backed ul { margin: 0; }

/* screenshots: the app as it is, private details removed */
.shot { margin: 28px 0 8px; }
.shot img { width: 100%; height: auto; border: 1px solid var(--line-strong); border-radius: 14px; background: var(--surface); }
.shot figcaption { margin-top: 10px; font-size: 13px; line-height: 1.6; color: var(--dim); }
.split { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 36px; align-items: start; margin-top: 8px; }
.split .shot { margin: 6px 0 0; }
.docs .shot.narrow { max-width: 520px; }

/* lists that carry a term and what it means */
.terms { display: grid; gap: 10px; margin: 18px 0; }
.terms > div { padding: 16px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.terms dt { margin-bottom: 4px; font-size: 16px; font-weight: 600; color: var(--text); }
.terms dd { margin: 0; font-size: 15px; line-height: 1.65; }
.terms.plain > div { padding: 0 0 12px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: none; }

/* who is approved and who does the work: three boxes on a line, what cannot happen underneath */
.flow { margin: 22px 0 18px; padding: 22px; border: 1px solid var(--line-strong); border-radius: 16px; background: var(--surface); }
.flow-main { display: grid; grid-template-columns: minmax(0, 1fr) 104px minmax(0, 1fr) 104px minmax(0, 1fr); align-items: stretch; }
.node { display: flex; flex-direction: column; gap: 4px; padding: 14px; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--bg); }
.node b { font-size: 16px; font-weight: 600; color: var(--text); }
.node span { font-size: 13px; line-height: 1.5; color: var(--muted); }
.node .node-k { font: 500 10.5px/1.4 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
.node.hub { border-color: #78e5ae66; background: #78e5ae0b; }
.node.hub .node-k { color: var(--mint); }
.edge { position: relative; display: flex; align-items: center; justify-content: center; }
.edge::before { content: ''; position: absolute; left: 8px; right: 12px; top: 50%; height: 1px; background: var(--mint); }
.edge::after { content: ''; position: absolute; right: 6px; top: calc(50% - 4px); border: 4px solid transparent; border-left: 7px solid var(--mint); }
.edge span { position: relative; margin-bottom: 44px; padding: 0 6px; font: 11px/1.35 var(--mono); color: var(--mint); text-align: center; }
.docs .flow-return { margin: 12px 0 0; padding: 10px 14px; border: 1px dashed #78e5ae55; border-radius: 10px; font-size: 13.5px; line-height: 1.55; color: var(--muted); }
.flow-return span { margin-right: 6px; color: var(--mint); }
.flow-no { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 10px; }
.flow-no > div { display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; border: 1px solid #ef8f8f33; border-radius: 10px; background: #ef8f8f08; }
.flow-no b { font-size: 14px; font-weight: 600; color: var(--text); }
.flow-no b::before { content: '✕'; margin-right: 8px; color: #ef8f8f; }
.flow-no span { font-size: 13px; line-height: 1.5; color: var(--muted); }

/* networks and contract addresses; the logo strip is the landing's, laid out from the left */
.venue-strip { margin: 16px 0 0; padding: 18px 20px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.venue-strip .venue-list { flex-direction: column; align-items: flex-start; gap: 14px; }
.venue-strip .venue-group { justify-content: flex-start; gap: 12px; }
.venue-strip .venue-divider { width: 100%; height: 1px; }
.table-wrap { margin: 20px 0 8px; overflow-x: auto; border: 1px solid var(--line-strong); border-radius: 14px; }
.docs table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.docs th { padding: 12px 16px; border-bottom: 1px solid var(--line-strong); font: 500 12px var(--mono); letter-spacing: .05em; text-transform: uppercase; color: var(--dim); text-align: left; background: var(--surface); }
.docs td { padding: 12px 16px; border-bottom: 1px solid var(--line); color: #c4c4cc; vertical-align: middle; }
.docs tr:last-child td { border-bottom: 0; }
.docs td:first-child { color: var(--text); font-weight: 500; white-space: nowrap; }
.addr { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.addr code { font: 13px var(--mono); color: var(--text); overflow-wrap: anywhere; }
.addr button, .addr a { display: inline-flex; align-items: center; min-height: 28px; padding: 0 10px; border: 1px solid var(--line-strong); border-radius: 999px; background: transparent; color: var(--muted); font-size: 12px; }
.addr button:hover, .addr a:hover { color: var(--text); border-color: #ffffff40; }
.addr button.done { color: var(--mint); border-color: #78e5ae66; }

/* questions */
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 0; font-size: 17px; font-weight: 500; line-height: 1.5; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; flex: none; font-size: 22px; font-weight: 400; color: var(--dim); }
.faq details[open] summary::after { content: '−'; color: var(--mint); }
.faq details p { margin: 0 32px 20px 0; }

.docs .updated { margin-top: 56px; font-size: 13px; color: var(--dim); }

@media (max-width: 1000px) {
  .docs-shell { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .docs-shell > .docs-toc { display: none; }
  .toc-fold { display: block; }
  .split { grid-template-columns: minmax(0, 1fr); }
  .split .shot { max-width: 340px; }
}
@media (max-width: 700px) {
  /* the line turns downwards: boxes stacked, each arrow with its label beside it */
  .flow { padding: 16px; }
  .flow-main { grid-template-columns: minmax(0, 1fr); }
  .edge { justify-content: flex-start; min-height: 52px; padding-left: calc(50% + 14px); }
  .edge::before { left: 50%; right: auto; top: 6px; bottom: 12px; width: 1px; height: auto; }
  .edge::after { left: calc(50% - 4px); right: auto; top: auto; bottom: 4px; border: 4px solid transparent; border-top: 7px solid var(--mint); }
  .edge span { margin: 0; padding: 0; text-align: left; }
  .flow-no { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 600px) {
  .docs h1 { font-size: 36px; letter-spacing: -1.1px; }
  .docs .lead { font-size: 17px; }
  .docs h2 { font-size: 25px; }
  .docs section { padding-top: 48px; }
  .cards { grid-template-columns: minmax(0, 1fr); }
  .docs-links { gap: 16px; font-size: 13px; }
  .docs td, .docs th { padding: 10px 12px; }
}
