/* AppRelease docs — a light reading surface, loaded on top of styles.css.
   Sidebar on the left, the article in the middle, table of contents on the
   right. On a phone the sidebar folds into a toggle above the article. */

.docs-page {
  --bg: #FFFFFF; --bg-2: #FAFAF7; --panel: #FFFFFF;
  --line: #E3E3DE; --line-2: #CFCFC8;
  --text: #111111; --muted: #4A4A46; --faint: #8A8A84;
  --indigo: #1D6B3F;
  --shadow: none;
  background: var(--bg); color: var(--text);
}
.docs-page .site-header { background: rgba(255,255,255,.92); }

.docs-page .site-footer { background: var(--bg-2); }
.docs-page .footer-cols h4 { color: var(--text); }


.docs-search { display: none; flex: 1; max-width: 520px; margin-left: 20px; position: relative; }
.docs-search input {
  width: 100%; height: 40px; border-radius: 8px; border: 1px solid var(--line-2); background: #FAFAF7;
  padding: 0 14px 0 40px; font: inherit; font-size: .92rem; color: var(--text);
}
.docs-search input:focus { outline: 2px solid var(--text); outline-offset: 0; background: #fff; }
.docs-search svg { position: absolute; left: 13px; top: 12px; width: 18px; height: 18px; color: var(--faint); pointer-events: none; }
.docs-search ul { position: absolute; left: 0; right: 0; top: 48px; margin: 0; padding: 6px; list-style: none; border-radius: 12px;
  border: 1px solid var(--line-2); background: #fff; box-shadow: var(--shadow); display: none; z-index: 20; }
.docs-search ul.is-open { display: block; }
.docs-search li a { display: block; padding: 9px 12px; border-radius: 8px; text-decoration: none; font-size: .9rem; }
.docs-search li a:hover, .docs-search li a.is-hot { background: #F1F1EC; }
.docs-search li small { display: block; color: var(--faint); font-size: .78rem; }

.docs-layout { display: grid; gap: 28px; padding: 28px 0 80px; }

/* sidebar */
.docs-side { position: relative; }
.docs-side-toggle {
  display: flex; align-items: center; justify-content: space-between; width: 100%;
  border: 1px solid var(--line-2); background: #fff; border-radius: 12px; padding: 12px 14px;
  font: inherit; font-weight: 620; cursor: pointer; color: var(--text);
}
.docs-side-toggle::after { content: "▾"; color: var(--faint); }
.docs-nav { display: none; margin-top: 10px; }
.docs-nav.is-open { display: block; }
.docs-nav h4 { font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); margin: 18px 0 6px; padding: 0 10px; }
.docs-nav h4:first-child { margin-top: 0; }
.docs-nav a { display: block; padding: 6px 10px; border-radius: 6px; text-decoration: none; font-size: .93rem; color: var(--muted); }
.docs-nav a:hover { color: var(--text); background: #F1F1EC; }
.docs-nav a.is-active { color: var(--text); font-weight: 600; background: #F1F1EC; }
.docs-nav .soon { opacity: .55; pointer-events: none; }
.docs-nav .soon::after { content: "soon"; float: right; font-size: .7rem; font-weight: 700; letter-spacing: .06em; color: var(--faint); margin-top: 3px; }

/* article */
.docs-article { min-width: 0; max-width: 780px; }
.docs-article h1 { font-size: clamp(2rem, 5vw, 2.8rem); margin-bottom: 10px; }
.docs-article .lead { font-size: 1.1rem; margin-bottom: 26px; }
.docs-article h2 { font-size: 1.65rem; margin-top: 2.4em; padding-top: .4em; scroll-margin-top: 90px; }
.docs-article h3 { font-size: 1.18rem; margin-top: 1.8em; scroll-margin-top: 90px; }
.docs-article p, .docs-article li { color: var(--muted); }
.docs-article li { margin-bottom: 6px; }
.docs-article strong { color: var(--text); font-weight: 640; }
.docs-article a { color: var(--text); }
.docs-article code { font-size: .86em; padding: 2px 6px; border-radius: 6px; background: #F1F1EC; color: #111; border: 1px solid #E3E3DE; }
.docs-article pre code { background: none; border: 0; padding: 0; color: inherit; font-size: inherit; }
.docs-article .code { box-shadow: none; margin: 18px 0 24px; }
.docs-article .code pre { color: #111; }
.docs-article table { width: 100%; border-collapse: collapse; font-size: .92rem; margin: 16px 0 24px; }
.docs-article th, .docs-article td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.docs-article th { color: var(--text); font-weight: 640; background: var(--bg-2); }
.docs-article td { color: var(--muted); }
.docs-article td code { white-space: nowrap; }

.crumbs { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: .85rem; color: var(--faint); margin-bottom: 18px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--text); }

.note {
  margin: 20px 0; padding: 16px 18px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--bg-2);
  font-size: .95rem; color: var(--muted);
}
.note b { color: var(--text); }
.note p:last-child { margin-bottom: 0; }
.note-tip { border-color: #BFE0CC; background: #E6F2EB; }
.note-warn { border-color: #F6D9A3; background: #FFF8E8; }

/* tabs inside docs (light chrome, dark code) */
.tabs { border: 1px solid var(--line-2); border-radius: 14px; margin: 18px 0 26px; overflow: hidden; }
.tabs-bar { display: flex; gap: 2px; padding: 8px 8px 0; background: var(--bg-2); border-bottom: 1px solid var(--line); overflow-x: auto; }
.tabs-bar button { border: 0; background: transparent; color: var(--muted); font: inherit; font-size: .9rem; font-weight: 620;
  padding: 10px 16px; border-radius: 9px 9px 0 0; cursor: pointer; white-space: nowrap; }
.tabs-bar button[aria-selected="true"] { color: var(--text); background: #fff; box-shadow: inset 0 -2px 0 var(--text); }
.tabs-pane { display: none; padding: 20px 20px 6px; }
.tabs-pane.is-active { display: block; }
.tabs-pane > :first-child { margin-top: 0; }
.tabs-pane h3 { margin-top: 1.2em; }

.docs-steps { counter-reset: s; list-style: none; padding: 0; }
.docs-steps li { position: relative; padding-left: 40px; margin-bottom: 12px; }
.docs-steps li::before { counter-increment: s; content: counter(s); position: absolute; left: 0; top: 1px; width: 26px; height: 26px; border-radius: 50%;
  background: var(--text); color: #fff; font-weight: 600; font-size: .82rem; display: grid; place-items: center; }

.docs-cards { display: grid; gap: 14px; margin: 26px 0; }
.docs-card { padding: 22px; border-radius: 14px; border: 1px solid var(--line-2); background: #fff; text-decoration: none; display: block; transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s; }
.docs-card:hover { border-color: var(--text); }
.docs-card h3 { margin: 0 0 6px; color: var(--text); }
.docs-card p { margin: 0 0 10px; font-size: .93rem; }
.docs-card ul { margin: 0; padding-left: 18px; font-size: .9rem; }
.docs-card ul a { text-decoration: none; }

.docs-next { display: grid; gap: 12px; margin-top: 48px; }
.docs-next a { padding: 18px 20px; border: 1px solid var(--line-2); border-radius: 14px; text-decoration: none; display: block; }
.docs-next a:hover { border-color: var(--text); }
.docs-next small { display: block; color: var(--faint); font-size: .8rem; margin-bottom: 4px; }
.docs-next b { color: var(--text); }
.docs-next .next { text-align: right; }

.docs-help { margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line); font-size: .92rem; }
.docs-help h2 { font-size: 1.2rem; margin-top: 0; }

/* table of contents */
.docs-toc { display: none; }
.docs-toc h4 { font-size: .76rem; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); margin: 0 0 10px; }
.docs-toc ol { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.docs-toc a { display: block; padding: 5px 12px; font-size: .86rem; color: var(--muted); text-decoration: none; border-left: 2px solid transparent; margin-left: -1px; }
.docs-toc a:hover { color: var(--text); }
.docs-toc a.is-active { color: var(--text); border-left-color: var(--text); font-weight: 600; }

@media (min-width: 600px) {
  .docs-cards { grid-template-columns: 1fr 1fr; }
  .docs-next { grid-template-columns: 1fr 1fr; }
  .docs-search { display: block; }
}

@media (min-width: 900px) {
  .docs-layout { grid-template-columns: 240px minmax(0, 1fr); gap: 44px; padding-top: 36px; }
  .docs-side-toggle { display: none; }
  .docs-nav { display: block; position: sticky; top: 90px; max-height: calc(100vh - 110px); overflow: auto; padding-right: 8px; margin-top: 0; }
}

@media (min-width: 1200px) {
  .docs-layout { grid-template-columns: 240px minmax(0, 1fr) 210px; }
  .docs-toc { display: block; position: sticky; top: 90px; align-self: start; }
}
