/* Lily SDK documentation (/sdk/lily/): full-width layout with a sidebar */
.doc { display: grid; grid-template-columns: 290px minmax(0, 1fr); align-items: start; }
.doc__side { position: sticky; top: 72px; align-self: start; height: calc(100vh - 72px); border-right: 1px solid var(--line); background: var(--gray); }
.doc__nav { height: 100%; overflow-y: auto; padding: 20px 16px 40px; }
.doc__menu { display: none; }
.doc__brand { display: flex; align-items: center; gap: 10px; padding: 0 8px 16px; border-bottom: 1px solid var(--line); }
.doc__brand strong { display: block; color: var(--ink); font-size: 15.5px; line-height: 1.2; }
.doc__brand small { display: block; color: var(--muted); font-size: 12.5px; }
.doc__group > p { margin: 18px 8px 6px; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.doc__group a { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 6px; font-size: 14.5px; color: var(--text); transition: background-color .2s, color .2s; }
.doc__group a img { flex: none; width: 20px; height: 20px; }
.doc__dot { flex: none; width: 6px; height: 6px; margin: 0 7px; border-radius: 50%; background: var(--line); }
.doc__group a:hover { background: #fff; color: var(--red); }
.doc__group a[aria-current="true"] { background: #fff; color: var(--red); font-weight: 600; box-shadow: inset 3px 0 0 var(--red); }
.doc__group a[aria-current="true"] .doc__dot { background: var(--red); }
.doc__body { min-width: 0; max-width: 1040px; padding: 28px clamp(18px, 4vw, 56px) 64px; }
.doc__hero { padding-bottom: 30px; margin-bottom: 34px; border-bottom: 1px solid var(--line); }
.doc__hero h1 { font-size: clamp(28px, 3.4vw, 40px); letter-spacing: -.02em; margin: 14px 0 8px; }
.doc__hero > p { font-size: 17px; color: var(--muted); }
.doc__sec { scroll-margin-top: 90px; padding-bottom: 38px; margin-bottom: 38px; border-bottom: 1px solid var(--line); }
.doc__sec h2 { display: flex; align-items: center; gap: 12px; font-size: 25px; margin-bottom: 14px; }
.doc__sec h3 { font-size: 17px; margin: 24px 0 8px; }
.doc__sec h4 { font-size: 15.5px; margin-bottom: 6px; }
.doc__sec > p { margin: 10px 0; line-height: 1.7; color: var(--text); }
.doc__sec code { font-family: var(--mono); font-size: .9em; }
.doc__sec > p code, .doc__sec li code, .doc__sec td code, .doc__sec th code, .doc-note code, .doc-card code { padding: 1px 5px; border-radius: 4px; background: var(--gray); overflow-wrap: anywhere; }
.doc__sec .table-wrap { margin-top: 14px; }
.doc__sec .sdk-chip { margin: 0; }
.doc__sec .sdk-list { margin-top: 14px; }
.doc-status { margin-top: -4px !important; }
.doc-badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; margin-top: 18px; }
.doc-badges a { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 18px 10px; border: 1px solid var(--line); border-radius: var(--radius); font-size: 14px; font-weight: 600; color: var(--ink); transition: transform .2s var(--ease), border-color .2s; }
.doc-badges a:hover { border-color: var(--red); transform: translateY(-3px); }
.doc-flow { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 30px; margin: 16px 0; padding: 0; }
.doc-flow li { position: relative; padding: 16px; border: 1px solid var(--line); border-top: 3px solid var(--red); border-radius: var(--radius); text-align: center; }
.doc-flow li + li::before { content: "\2192"; position: absolute; left: -23px; top: 50%; transform: translateY(-50%); color: var(--red); font-size: 18px; }
.doc-flow strong { display: block; color: var(--ink); }
.doc-flow span { display: block; margin-top: 4px; font-size: 14px; color: var(--muted); }
.doc-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; margin-top: 14px; }
.doc-card { padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius); }
.doc-card p { font-size: 14.5px; line-height: 1.6; color: var(--muted); }
.doc-note { margin: 14px 0; padding: 12px 16px; border-left: 3px solid #1A56C4; border-radius: 6px; background: #F1F5FE; font-size: 14.5px; line-height: 1.65; color: var(--text); }
.doc-note--warn { border-left-color: #9A5B00; background: #FFF8EB; }
.doc-code { margin: 12px 0; }
.sdk-code-head > span:first-child { font-weight: 600; }
.doc-code .sdk-code { white-space: pre; background: #15171C; color: #E8EAF0; border-color: #15171C; }
.doc-code .sdk-code code { color: inherit; background: none; padding: 0; }
.doc-copy { border: 1px solid var(--line); border-radius: 6px; background: #fff; padding: 3px 10px; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--ink); cursor: pointer; }
.doc-copy:hover { border-color: var(--red); color: var(--red); }
.doc-tabs { margin: 14px 0; }
.doc-tabs__list { display: none; flex-wrap: wrap; gap: 8px; }
.doc-tabs.is-on .doc-tabs__list { display: flex; }
.doc-tabs.is-on .doc-panel:not(.is-shown) { display: none; }
.doc-tab { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px; border: 1px solid var(--line); border-radius: 6px; background: #fff; font: inherit; font-size: 14px; font-weight: 600; color: var(--ink); cursor: pointer; }
.doc-tab img { width: 18px; height: 18px; }
.doc-tab:hover { border-color: var(--red); }
.doc-tab[aria-pressed="true"] { border-color: var(--red); box-shadow: inset 0 -2px 0 var(--red); }
.doc-faq { border-bottom: 1px solid var(--line); }
.doc-faq summary { padding: 13px 0; font-weight: 600; color: var(--ink); cursor: pointer; }
.doc-faq p { padding-bottom: 14px; color: var(--muted); line-height: 1.7; }
@media (max-width: 960px) {
  .doc { grid-template-columns: minmax(0, 1fr); }
  .doc__side { position: sticky; top: 62px; z-index: 20; height: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .doc__menu { display: block; width: 100%; padding: 12px 18px; border: 0; background: var(--gray); font: inherit; font-weight: 600; text-align: left; color: var(--ink); cursor: pointer; }
  .doc__nav { display: none; height: auto; max-height: 65vh; }
  .doc__side.is-open .doc__nav { display: block; }
  .doc__sec { scroll-margin-top: 130px; }
  .doc-flow { grid-template-columns: 1fr; gap: 26px; }
  .doc-flow li + li::before { content: "\2193"; left: 50%; top: -22px; transform: translateX(-50%); }
}
/* the site already keeps 80px clear under the header when jumping to an anchor */
.doc__sec { scroll-margin-top: 8px; }
@media (max-width: 960px) { .doc__sec { scroll-margin-top: 52px; } }

/* pieces the other SDK docs use (ZabMessaging) */
.doc__logo { display: block; width: min(360px, 100%); height: auto; margin-top: 18px; }
.doc__hero .doc__logo + h1 { margin-top: 18px; }
.doc-letter { flex: none; display: inline-flex; align-items: center; justify-content: center; border-radius: 5px; background: var(--ink); color: #fff; font-weight: 700; line-height: 1; }
.doc-letter--18 { width: 18px; height: 18px; font-size: 10px; }
.doc-letter--20 { width: 20px; height: 20px; font-size: 10.5px; }
.doc-letter--28 { width: 28px; height: 28px; font-size: 13px; }
.doc-letter--30 { width: 30px; height: 30px; font-size: 14px; }
.doc__sec h4 { margin-top: 18px; }
.doc__sec ul.doc-list, .doc__sec ol.doc-steps { margin: 10px 0; padding-left: 22px; line-height: 1.7; color: var(--text); }
.doc__sec ul.doc-list { list-style: disc; }
.doc__sec ol.doc-steps { list-style: decimal; }
.doc__sec .doc-list li, .doc__sec .doc-steps li { margin: 6px 0; }
.doc__sec .doc-steps li::marker { color: var(--red); font-weight: 700; }
.doc__sec .doc-note p { margin: 0; }
.doc-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.doc__sec .compare-table.doc-table tbody th { width: auto; vertical-align: top; }
.doc__sec .compare-table.doc-table td { vertical-align: top; }
.doc__sec .compare-table.doc-table thead th:nth-child(3), .doc__sec .compare-table.doc-table tbody td:nth-child(3) { background: none; }
.doc__sec .compare-table.doc-table thead th { background: var(--gray); }
.doc-card--link { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; color: var(--text); transition: transform .2s var(--ease), border-color .2s; }
.doc-card--link:hover { border-color: var(--red); transform: translateY(-3px); }
.doc-card--link strong { color: var(--ink); }
.doc-card--link p { margin: 0; }
.doc__sec .compare-table.doc-table th, .doc__sec .compare-table.doc-table td { text-align: left; padding: 11px 14px; }

/* pieces of the ZabVerify docs */
.doc-method { display: inline-block; padding: 2px 8px; border-radius: 4px; background: var(--gray); color: var(--ink); font-family: var(--mono); font-size: 12px; font-weight: 700; }
.doc-kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 18px; margin: 14px 0; font-size: 15px; }
.doc-kv dt { font-weight: 600; color: var(--ink); }
.doc-kv dd { margin: 0; color: var(--text); }
.doc__sec .tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.doc-file { margin: 12px 0; border-bottom: 1px solid var(--line); }
.doc-file summary { padding: 11px 0; font-weight: 600; color: var(--ink); cursor: pointer; overflow-wrap: anywhere; }
.doc-diagram { margin: 14px 0; padding: 12px; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.doc-diagram svg { display: block; width: 100%; min-width: 500px; height: auto; color: var(--muted); }
.doc-diagram text { fill: var(--ink); font-size: 12.5px; }
.doc-diagram .muted text, .doc-diagram text.muted { fill: var(--muted); }
.doc-diagram .box { fill: var(--gray); stroke: var(--line); }
.doc-diagram .line { fill: none; stroke: var(--muted); stroke-width: 1.4; }
.doc-diagram .line.hot { stroke: var(--red); color: var(--red); }
@media (max-width: 560px) { .doc-kv { grid-template-columns: minmax(0, 1fr); gap: 2px; } .doc-kv dd { margin-bottom: 8px; } }
.doc-code .sdk-code-head { gap: 10px; }
.doc-code .sdk-code-head > span:first-child { min-width: 0; overflow-wrap: anywhere; }

/* the supported countries list */
.doc-filter { max-width: 460px; margin: 18px 0 10px; }
.doc-filter label { display: block; margin-bottom: 6px; font-weight: 600; color: var(--ink); }
.doc-filter .input { width: 100%; }
.doc-filter__none { color: var(--muted); }
.doc-regions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.doc-regions a { padding: 6px 12px; border: 1px solid var(--line); border-radius: 6px; font-size: 14px; font-weight: 600; color: var(--ink); }
.doc-regions a:hover { border-color: var(--red); color: var(--red); }
.doc-regions span { color: var(--muted); font-weight: 500; }
.doc__sec .compare-table.doc-countries tbody th { width: 28%; }
.doc__sec .compare-table.doc-countries td:nth-child(2) { width: 18%; white-space: nowrap; }
.doc-countries tr[hidden], [data-doc-region][hidden] { display: none; }
.doc-cc { margin-left: 4px; font-size: 12px; font-weight: 600; color: var(--muted); }
.doc-chip { display: inline-block; margin: 2px 0; padding: 2px 8px; border: 1px solid var(--line); border-radius: 5px; background: var(--gray); font-size: 13px; }
@media (max-width: 700px) {
  .doc__sec .compare-table.doc-countries tbody th, .doc__sec .compare-table.doc-countries td:nth-child(2) { width: auto; white-space: normal; }
  .doc__sec .compare-table.doc-countries { font-size: 13.5px; }
}
.doc__sec .compare-table.doc-countries code { white-space: nowrap; overflow-wrap: normal; }
/* on a phone the passport ID (always the country code and _passport) makes room for the document names */
@media (max-width: 700px) { .doc__sec .compare-table.doc-countries th:nth-child(2), .doc__sec .compare-table.doc-countries td:nth-child(2) { display: none; } .doc__sec .compare-table.doc-countries tbody th { width: 36%; } }
.doc-flag { margin-right: 10px; font-size: 22px; vertical-align: -3px; }

/* pieces of the ZabMonitor docs: terminal colours, pictures, status words, endpoint lines */
.doc-code .sdk-code .t-b { color: #7FB2FF; font-weight: 700; }
.doc-code .sdk-code .t-g { color: #6FD68B; }
.doc-code .sdk-code .t-y { color: #FFD479; }
.doc-code .sdk-code .t-c { color: #9AA1AE; }
.doc__sec .zm-ok { color: #12703A; }
.doc__sec .zm-warn { color: #9A5B00; }
.doc__sec .zm-crit { color: #B3141F; }
.doc__sec .zm-muted { color: var(--muted); }
.doc-shot { margin: 16px 0; }
.doc-shot a { display: block; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .2s; }
.doc-shot a:hover { border-color: var(--red); }
.doc-shot img { display: block; width: 100%; height: auto; }
.doc-shot figcaption { margin-top: 8px; font-size: 14px; color: var(--muted); }
.doc__sec p.doc-need { margin: 0 0 10px; font-size: 14.5px; color: var(--muted); }
.doc__sec p.doc-ep { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 10px; }
.doc-code + .doc-code { margin-top: -4px; }
.zm-shots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; gap: 22px; }
.zm-shots .doc-shot { margin: 0; }
.zm-shots .doc-shot a { height: clamp(180px, 20vw, 240px); background: #F3F3F3; }
.zm-shots .doc-shot img { height: 100%; object-fit: cover; object-position: top left; }
.zm-shots .doc-shot figcaption { text-align: center; font-weight: 600; color: var(--ink); }
@media (max-width: 860px) { .zm-shots { grid-template-columns: minmax(0, 1fr); max-width: 520px; margin: 0 auto; } .zm-shots .doc-shot a { height: auto; } .zm-shots .doc-shot img { height: auto; } }
.compare-table.zm-table th, .compare-table.zm-table td { text-align: left; padding: 11px 14px; }
.compare-table.zm-table thead th:nth-child(3) { background: var(--gray); }
.compare-table.zm-table tbody td:nth-child(3) { background: none; }

/* pieces of the ZabPush docs: boxes and steps with a title line, cards with an icon, questions */
.doc__sec .doc-note--titled > b, .doc__sec .doc-steps--titled > li > b:first-child, .doc__sec .doc-cards--steps .doc-card > b:first-child { display: block; color: var(--ink); }
.doc__sec .doc-card__head { display: inline-flex; align-items: center; gap: 8px; }
.doc__sec .doc-card__head img { flex: none; width: 20px; height: 20px; }
.doc__sec .doc-cards--steps .doc-card { font-size: 14.5px; line-height: 1.6; }
.doc__sec h3 + .doc-code { margin-top: 8px; }
.doc__sec .doc-faq__a { padding-bottom: 14px; color: var(--muted); line-height: 1.7; }
.compare-table.zp-ask tbody th { width: 38%; white-space: normal; }
