/* AZUO docs: one long readable page, contents on the left, nothing boxed that doesn't need to be */
.dhead { position: relative; z-index: 2; padding: 136px 0 34px; border-bottom: 1px solid var(--line); background: linear-gradient(rgba(10, 9, 12, .2), rgba(10, 9, 12, .9)); }
.dhead h1 { margin: 18px 0 0; font-weight: 600; font-size: clamp(42px, 7vw, 92px); line-height: 1; letter-spacing: -.035em; }
.dhead h1 em { font-style: normal; color: var(--lilac); }
.dhead .lede { max-width: 62ch; margin: 22px 0 0; color: var(--mute); font-size: 16.5px; line-height: 1.7; }
.dmath { margin-top: 34px; height: 150px; border-top: 1px solid var(--line); }
.dmath canvas { width: 100%; height: 100%; display: block; }

.dgrid { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 72px; }
.dbody { position: relative; z-index: 2; background: rgba(10, 9, 12, .9); }
.toc { position: sticky; top: 88px; align-self: start; padding: 48px 0 40px; display: flex; flex-direction: column; }
.toc a { padding: 7px 0 7px 16px; border-left: 1px solid var(--line); color: var(--dim); font-size: 13.5px; transition: color .2s, border-color .2s; }
.toc a:hover { color: var(--ink); }
.toc a.on { color: var(--ink); border-left-color: var(--azure); }

.doc { max-width: 760px; padding: 24px 0 110px; }
.doc section { padding: 46px 0 40px; border-top: 1px solid var(--line); scroll-margin-top: 76px; }
.doc section:first-child { border-top: 0; }
.doc h2 { margin: 0 0 18px; font-size: clamp(25px, 3.2vw, 34px); font-weight: 600; letter-spacing: -.025em; line-height: 1.1; }
.doc h3 { margin: 30px 0 8px; font-size: 17px; font-weight: 600; letter-spacing: -.01em; }
.doc p, .doc li { color: var(--mute); font-size: 15.5px; line-height: 1.78; }
.doc p { margin: 0 0 14px; }
.doc b { color: var(--ink); font-weight: 500; }
.doc ol, .doc ul { margin: 0 0 14px; padding-left: 22px; }
.doc li { margin: 6px 0; padding-left: 4px; }
.doc li::marker { color: var(--lilac); font: 12px var(--mono); }
.doc code { font: 13px var(--mono); color: var(--lilac); background: rgba(184, 170, 230, .08); padding: 2px 6px; border-radius: 6px; word-break: break-all; }
.doc .ln { color: var(--azure2); border-bottom: 1px solid rgba(111, 147, 255, .35); }
.doc .ln:hover { color: var(--ink); border-bottom-color: var(--ink); }
.doc .note { font-size: 14px; color: var(--dim); }
.doc .m { font: 10.5px var(--mono); color: var(--dim); letter-spacing: .06em; margin-left: 6px; white-space: nowrap; }

.dcode { margin: 6px 0 18px; border: 1px solid var(--line); border-radius: 18px; background: rgba(13, 12, 18, .92); padding: 22px 24px; font: 13.5px/1.85 var(--mono); color: var(--mute); overflow-x: auto; white-space: pre; }
.dcode .c { color: var(--dim); } .dcode .k { color: var(--lilac); } .dcode .a { color: var(--azure2); } .dcode .g { color: var(--mint); }

.facts { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); border-radius: 18px; margin: 22px 0 22px; overflow: hidden; }
.facts > div { padding: 18px 18px 20px; border-left: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; }
.facts > div:first-child { border-left: 0; }
.facts b { font-size: 15px; color: var(--ink); font-weight: 600; }
.facts span { font-size: 13.5px; color: var(--mute); line-height: 1.55; }

.tbl { width: 100%; border-collapse: collapse; margin: 8px 0 18px; font-size: 14.5px; }
.tbl th { text-align: left; font: 11px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); padding: 10px 12px; border-bottom: 1px solid var(--line2); font-weight: 400; }
.tbl td { padding: 12px; border-bottom: 1px solid var(--line); color: var(--mute); vertical-align: top; line-height: 1.55; }
.tbl td:first-child { color: var(--ink); }
.tbl td.bad { color: var(--red); font: 13px var(--mono); } .tbl td.ok { color: var(--mint); font: 13px var(--mono); }

.call { margin: 18px 0 8px; padding: 16px 18px; border: 1px solid rgba(255, 107, 122, .28); background: rgba(255, 107, 122, .05); border-radius: 14px; color: var(--mute); font-size: 14.5px; line-height: 1.65; }
.call b { color: var(--red); }

.addr { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 6px 0 18px; }
.addr code { padding: 10px 14px; border-radius: 12px; font-size: 13px; }

.eps { border: 1px solid var(--line); border-radius: 18px; overflow: hidden; margin-top: 10px; }
.ep { display: grid; grid-template-columns: 52px minmax(0, 210px) minmax(0, 1fr); gap: 14px; align-items: baseline; padding: 13px 16px; border-top: 1px solid var(--line); }
.ep:first-child { border-top: 0; }
.ep i { font: 10.5px var(--mono); font-style: normal; letter-spacing: .08em; color: var(--mint); }
.ep i.p { color: var(--azure2); }
.ep > code { background: none; padding: 0; color: var(--ink); font-size: 13px; }
.ep span { color: var(--mute); font-size: 14px; line-height: 1.55; }
.ep span code { font-size: 12px; }

.dend { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 30px; }

@media (max-width: 900px) {
  .dgrid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .toc { position: sticky; top: 64px; z-index: 5; flex-direction: row; gap: 6px; overflow-x: auto; padding: 10px 0; margin: 0 -16px; padding-left: 16px; padding-right: 16px; background: rgba(10, 9, 12, .94); border-bottom: 1px solid var(--line); scrollbar-width: none; }
  .toc::-webkit-scrollbar { display: none; }
  .toc a { flex: none; white-space: nowrap; border: 1px solid var(--line); border-radius: 999px; padding: 7px 13px; font-size: 12.5px; }
  .toc a.on { border-color: var(--azure); background: rgba(61, 109, 255, .12); }
  .doc section { scroll-margin-top: 124px; }
  .facts { grid-template-columns: 1fr 1fr; }
  .facts > div:nth-child(3) { border-left: 0; }
  .facts > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .ep { grid-template-columns: 46px minmax(0, 1fr); }
  .ep span { grid-column: 2; }
}
@media (max-width: 640px) {
  .dhead { padding-top: 112px; }
  .dmath { height: 170px; }
  .dcode { font-size: 11.5px; padding: 18px; }
  .tbl { font-size: 13px; } .tbl td, .tbl th { padding: 10px 8px; }
  .tbl td.bad, .tbl td.ok { font-size: 12px; }
}

/* ---------- brand kit */
.doc.brand { max-width: 980px; margin: 0 auto; }
.bgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 18px; }
.bcard { margin: 0; border: 1px solid var(--line); border-radius: 20px; overflow: hidden; background: rgba(17, 16, 23, .8); display: flex; flex-direction: column; }
.bcard img { display: block; width: 100%; aspect-ratio: 1; object-fit: contain; background: #0a090c; }
.bcard.check img { padding: 18%; background-color: #2a2731; background-image: linear-gradient(45deg, #211f27 25%, transparent 25%, transparent 75%, #211f27 75%), linear-gradient(45deg, #211f27 25%, transparent 25%, transparent 75%, #211f27 75%); background-size: 24px 24px; background-position: 0 0, 12px 12px; }
.bcard.wide { margin-top: 18px; } .bcard.wide img { aspect-ratio: 3 / 1; object-fit: cover; }
.bcard figcaption { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; padding: 16px 18px; border-top: 1px solid var(--line); }
.bcard figcaption b { font-size: 15px; font-weight: 600; color: var(--ink); }
.bcard figcaption span { color: var(--mute); font-size: 13.5px; flex: 1; min-width: 160px; }
.bcard figcaption .bdl { display: inline-flex; gap: 8px; flex: none; min-width: 0; }
.sw { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 18px; }
.swc { text-align: left; cursor: pointer; border: 1px solid var(--line); border-radius: 16px; background: rgba(17, 16, 23, .8); padding: 0 0 14px; overflow: hidden; color: var(--ink); transition: border-color .25s, transform .25s var(--ease); }
.swc:hover { border-color: var(--line2); transform: translateY(-2px); }
.swc i { display: block; height: 76px; background: var(--c); border-bottom: 1px solid var(--line); }
.swc b { display: block; padding: 12px 14px 2px; font-size: 15px; font-weight: 600; }
.swc span { display: block; padding: 0 14px; font: 12px var(--mono); color: var(--mute); }
.ty { display: grid; gap: 12px; margin: 18px 0 16px; }
.ty > div { border: 1px solid var(--line); border-radius: 16px; padding: 18px 20px; background: rgba(17, 16, 23, .8); }
.tyl { font: 11px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.tys { margin: 8px 0 0 !important; font: 600 clamp(28px, 4.4vw, 46px)/1.05 var(--sans) !important; letter-spacing: -.03em; color: var(--ink) !important; }
.tys em { font-style: normal; color: var(--lilac); }
.tym { margin: 8px 0 0 !important; font: 16px var(--mono) !important; color: var(--lilac) !important; word-break: break-all; }
.bio { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; background: rgba(17, 16, 23, .8); margin: 14px 0 18px; }
.bio p { margin: 0 !important; flex: 1; min-width: 220px; color: var(--ink) !important; }
@media (max-width: 760px) { .bgrid { grid-template-columns: 1fr; } .sw { grid-template-columns: 1fr 1fr; } }

/* motion: sections rise in, tables and endpoints stagger, brand pieces pop */
.doc section { transition: opacity .8s var(--ease), transform .8s var(--ease); }
.doc section.pre { opacity: 0; transform: translateY(28px); }
.doc section:not(.pre) .tbl tr, .doc section:not(.pre) .ep { animation: drow .6s var(--ease) both; }
.doc section:not(.pre) .tbl tr:nth-child(2), .doc section:not(.pre) .ep:nth-child(2) { animation-delay: .05s; }
.doc section:not(.pre) .tbl tr:nth-child(3), .doc section:not(.pre) .ep:nth-child(3) { animation-delay: .1s; }
.doc section:not(.pre) .tbl tr:nth-child(4), .doc section:not(.pre) .ep:nth-child(4) { animation-delay: .15s; }
.doc section:not(.pre) .tbl tr:nth-child(5), .doc section:not(.pre) .ep:nth-child(5) { animation-delay: .2s; }
.doc section:not(.pre) .tbl tr:nth-child(n+6), .doc section:not(.pre) .ep:nth-child(n+6) { animation-delay: .25s; }
@keyframes drow { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.pop { animation: pop .7s cubic-bezier(.3, 1.5, .5, 1) both; }
@keyframes pop { from { opacity: 0; transform: translateY(14px) scale(.94); } to { opacity: 1; transform: none; } }
.dcode { position: relative; overflow: hidden; }
.dcode::after { content: ''; position: absolute; left: 0; right: 0; height: 1px; top: 0; pointer-events: none; background: rgba(111, 147, 255, .35); animation: scan 5s linear infinite; }
@keyframes scan { to { top: 110%; } }
@media (prefers-reduced-motion: reduce) { .doc section, .pop, .dcode::after { animation: none !important; transition: none; } .doc section.pre { opacity: 1; transform: none; } }
