
/* Premium docs UI (Stripe-like) - lightweight and self-contained */
:root{
  --docs-bg: #0b1220;
  --docs-panel: rgba(255,255,255,.04);
  --docs-panel-2: rgba(255,255,255,.06);
  --docs-border: rgba(255,255,255,.08);
  --docs-text: rgba(255,255,255,.88);
  --docs-muted: rgba(255,255,255,.62);
  --docs-accent: #7c3aed;
  --docs-code-bg: #0a0f1a;
  --docs-code-text: #b6ffdf;
  --docs-shadow: 0 10px 30px rgba(0,0,0,.35);
}

.docs-body{
  background: radial-gradient(1200px 600px at 20% 10%, rgba(124,58,237,.25), transparent 60%),
              radial-gradient(900px 500px at 80% 20%, rgba(34,197,94,.18), transparent 60%),
              var(--docs-bg);
  color: var(--docs-text);
  min-height: 100vh;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Arial, sans-serif;
}

.docs-shell{ display:flex; gap: 18px; padding: 18px; max-width: 1320px; margin: 0 auto; }
.docs-nav{
  width: 280px; flex: 0 0 280px;
  position: sticky; top: 18px; height: calc(100vh - 36px);
  background: var(--docs-panel);
  border: 1px solid var(--docs-border);
  border-radius: 16px;
  box-shadow: var(--docs-shadow);
  overflow:auto;
  padding: 14px;
}
.docs-brand{
  display:flex; align-items:center; gap: 10px; padding: 10px 8px 14px 8px;
  border-bottom: 1px solid var(--docs-border); margin-bottom: 10px;
}
.docs-logo{
  width: 36px; height: 36px; border-radius: 10px;
  background: linear-gradient(135deg, rgba(124,58,237,.9), rgba(34,197,94,.65));
  box-shadow: 0 8px 18px rgba(124,58,237,.25);
}
.docs-brand h1{ font-size: 15px; margin: 0; font-weight: 800; letter-spacing: .2px; }
.docs-brand p{ margin: 2px 0 0 0; font-size: 12px; color: var(--docs-muted); }

.docs-search{ margin: 10px 6px 14px 6px; }
.docs-search input{
  width: 100%;
  border: 1px solid var(--docs-border);
  background: rgba(0,0,0,.25);
  color: var(--docs-text);
  padding: 10px 12px;
  border-radius: 12px;
  outline: none;
}
.docs-search input::placeholder{ color: rgba(255,255,255,.45); }

.docs-nav a{
  display:flex; gap:10px; align-items:center;
  padding: 10px 10px;
  border-radius: 12px;
  color: var(--docs-text);
  text-decoration:none;
  border: 1px solid transparent;
}
.docs-nav a:hover{ background: var(--docs-panel-2); border-color: var(--docs-border); }
.docs-nav .group-title{
  margin: 14px 8px 8px 8px;
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--docs-muted);
}
.docs-nav .pill{
  margin-left:auto;
  font-size: 11px;
  color: rgba(255,255,255,.7);
  border: 1px solid var(--docs-border);
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(0,0,0,.18);
}

.docs-main{
  flex: 1 1 auto;
  min-width: 0;
}
.docs-topbar{
  display:flex; align-items:center; justify-content:space-between; gap: 12px;
  background: var(--docs-panel);
  border: 1px solid var(--docs-border);
  border-radius: 16px;
  padding: 14px 16px;
  box-shadow: var(--docs-shadow);
  margin-bottom: 16px;
}
.docs-topbar .meta{
  display:flex; flex-direction:column;
}
.docs-topbar h2{ margin:0; font-size: 18px; font-weight: 900; }
.docs-topbar small{ color: var(--docs-muted); }
.docs-topbar .actions{ display:flex; gap: 10px; align-items:center; flex-wrap:wrap; }
.docs-btn{
  display:inline-flex; gap: 8px; align-items:center;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--docs-border);
  background: rgba(0,0,0,.22);
  color: var(--docs-text);
  text-decoration:none;
  cursor:pointer;
}
.docs-btn:hover{ background: rgba(0,0,0,.32); }
.docs-btn.primary{
  border-color: rgba(124,58,237,.45);
  background: rgba(124,58,237,.20);
}
.docs-btn.primary:hover{ background: rgba(124,58,237,.28); }

.docs-card{
  background: var(--docs-panel);
  border: 1px solid var(--docs-border);
  border-radius: 18px;
  padding: 18px;
  box-shadow: var(--docs-shadow);
  margin-bottom: 16px;
}
.docs-card h3{ margin: 0 0 10px 0; font-size: 16px; font-weight: 900; }
.docs-card p{ margin: 8px 0; color: var(--docs-text); }
.docs-card ul, .docs-card ol{ margin: 8px 0 8px 18px; color: var(--docs-text); }
.docs-muted{ color: var(--docs-muted); }

.docs-kpi{
  display:grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 12px;
}
.docs-kpi .box{
  background: rgba(0,0,0,.18);
  border: 1px solid var(--docs-border);
  border-radius: 14px;
  padding: 12px 14px;
}
.docs-kpi .box b{ display:block; font-size: 14px; }
.docs-kpi .box span{ font-size: 12px; color: var(--docs-muted); }

pre.docs-code{
  position: relative;
  background: var(--docs-code-bg);
  color: var(--docs-code-text);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 14px;
  padding: 14px 14px 14px 14px;
  overflow:auto;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.15);
}
pre.docs-code code{
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 12.5px;
  line-height: 1.5;
}

.docs-copy{
  position:absolute;
  top: 10px;
  right: 10px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.35);
  color: rgba(255,255,255,.85);
  border-radius: 12px;
  padding: 6px 10px;
  cursor:pointer;
  font-size: 12px;
}
.docs-copy:hover{ background: rgba(0,0,0,.5); }
.docs-toast{
  position: fixed;
  bottom: 18px;
  right: 18px;
  background: rgba(0,0,0,.55);
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 14px;
  padding: 10px 12px;
  color: rgba(255,255,255,.9);
  box-shadow: var(--docs-shadow);
  backdrop-filter: blur(10px);
  display:none;
  z-index: 9999;
}

.docs-grid2{ display:grid; grid-template-columns: 1.2fr .8fr; gap: 16px; }
.docs-note{
  border-left: 3px solid rgba(124,58,237,.7);
  background: rgba(124,58,237,.10);
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(124,58,237,.20);
}

@media (max-width: 980px){
  .docs-shell{ flex-direction: column; }
  .docs-nav{ width: auto; position: relative; height: auto; }
  .docs-grid2{ grid-template-columns: 1fr; }
  .docs-kpi{ grid-template-columns: 1fr; }
}
