.docs-root {
  --docs-accent: #ffd466;
  --docs-accent-soft: rgba(255, 212, 102, .12);
  --docs-border: rgba(255,255,255,.105);
  --docs-border-strong: rgba(255,255,255,.18);
  --docs-panel: rgba(255,255,255,.035);
  --docs-muted: #aaa49b;
  min-height: 100vh;
  color: var(--text, #f4f0e8);
  background: var(--dark, #090909);
}
@font-face {
  font-family: "Magnifico";
  src: url("../../../assets/fonts/magnifico_nighttime_regular.otf") format("opentype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
.docs-root [hidden] { display: none !important; }
.docs-shell { position: relative; z-index: 1; }
.docs-root .site-nav { z-index: 50; }

/* Preserve the Docs gold hero and existing presentation. */
.docs-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 132px 0 36px;
  border-top: 0;
  border-bottom: 1px solid rgba(255,255,255,.22);
  color: #0b0b0c;
  background:
    radial-gradient(circle at 84% 18%, rgba(255,255,255,.40), transparent 21%),
    radial-gradient(circle at 10% 80%, rgba(255,247,211,.48), transparent 29%),
    radial-gradient(circle at 92% 82%, rgba(219,143,13,.22), transparent 24%),
    linear-gradient(125deg, #ffd466 0%, #ffd879 42%, #f1bc46 73%, #ffd466 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.35), 0 16px 38px rgba(77,58,16,.10);
}
.docs-hero::before {
  position: absolute; inset: -4%; z-index: 0; content: ""; pointer-events: none;
  background: radial-gradient(circle at 50% 42%, rgba(255,255,255,.22) 0%, rgba(255,255,255,.10) 30%, rgba(255,255,255,.025) 68%, transparent 100%);
  backdrop-filter: blur(5px) saturate(125%) brightness(1.04);
  -webkit-backdrop-filter: blur(5px) saturate(125%) brightness(1.04);
}
.docs-hero::after {
  position: absolute; right: -85px; bottom: -150px; width: 430px; height: 430px; z-index: 0;
  border: 1px solid rgba(255,255,255,.34); border-radius: 50%;
  box-shadow: 0 0 0 38px rgba(255,255,255,.09), 0 0 0 78px rgba(11,11,12,.035);
  content: ""; pointer-events: none;
}
.docs-hero-inner { position: relative; z-index: 2; }
.docs-hero .kicker { color: rgba(11,11,12,.60); }
.docs-hero .docs-title { color: #0b0b0c; }
.docs-hero .docs-lede { color: rgba(11,11,12,.68); }
.docs-hero .btn-secondary, .docs-hero .docs-small-button {
  color: #17120a; background: rgba(255,255,255,.36); border-color: rgba(255,255,255,.56);
  box-shadow: 0 12px 28px rgba(0,0,0,.10), inset 0 1px 0 rgba(255,255,255,.28);
  backdrop-filter: blur(16px) saturate(120%); -webkit-backdrop-filter: blur(16px) saturate(120%);
}
.docs-hero .btn-secondary:hover, .docs-hero .docs-small-button:hover { color: #17120a; background: rgba(255,255,255,.50); border-color: rgba(255,255,255,.72); }
.docs-hero .docs-search-panel {
  border-color: rgba(255,255,255,.62); background: rgba(255,255,255,.36);
  box-shadow: 0 18px 38px rgba(77,58,16,.10), inset 0 1px 0 rgba(255,255,255,.42);
  backdrop-filter: blur(18px) saturate(125%); -webkit-backdrop-filter: blur(18px) saturate(125%);
}
.docs-hero .docs-search-panel input { color: #17120a; }
.docs-hero .docs-search-panel input::placeholder { color: rgba(23,18,10,.56); }
.docs-hero .docs-search-icon { color: #17120a; }
.docs-hero .docs-search-caption { color: rgba(23,18,10,.62); }
.docs-hero .docs-search-caption span:first-child { color: rgba(23,18,10,.82); }
.docs-home-kicker { display: inline-flex; font-size: medium; color: rgba(11,11,12,.68) !important; text-decoration: none;}
.docs-home-kicker:hover { color: #0b0b0c !important; }
.docs-hero-icon {
  --docs-icon-size: clamp(220px, 28vw, 340px);
  position: absolute; top: auto; right: calc(130px - (var(--docs-icon-size) / 2));
  bottom: calc(65px - (var(--docs-icon-size) / 2)); z-index: 0; display: grid;
  place-items: center; width: var(--docs-icon-size); pointer-events: none; user-select: none;
  opacity: .17; filter: none saturate(.82);
  animation: docsIconReveal .88s cubic-bezier(.2,.75,.25,1) .16s both;
}
.docs-hero-icon::before {
  position: absolute; inset: 8%; z-index: -1; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.42), transparent 62%); filter: blur(18px); opacity: .30;
  content: ""; animation: docsIconHalo 6.5s ease-in-out infinite;
}
.docs-hero-icon img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: contain; filter: drop-shadow(0 24px 36px rgba(39,29,8,.10)); animation: docsIconFloat 7s ease-in-out infinite; will-change: transform; }
@keyframes docsIconReveal { from { transform: translateX(18px) scale(.96); } to { transform: translateX(0) scale(1); } }
@keyframes docsIconFloat { 0%,100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-8px) rotate(1deg); } }
@keyframes docsIconHalo { 0%,100% { transform: scale(.92); opacity: .45; } 50% { transform: scale(1.08); opacity: .78; } }
.docs-hero-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; padding-right: 0; }
.docs-hero-copy { min-width: 0; }
.docs-title { margin: 14px 0 0; color: var(--text, #f4f0e8); font-family: 'Magnifico', serif; font-size: clamp(43px, 7vw, 76px); line-height: .97; letter-spacing: -.075em; font-weight: 850; }
.docs-lede { max-width: 680px; margin: 17px 0 0; color: var(--docs-muted); font-size: clamp(14px, 1.4vw, 17px); line-height: 1.75; }
.docs-account-actions { display: flex; flex: 0 0 auto; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px; align-self: flex-end; }
.docs-account-actions #login-button { min-width: 190px; white-space: nowrap; }
.docs-account-actions button { white-space: nowrap; }
.docs-library-button { gap: 9px; }
.docs-avatar { display: inline-grid; flex: 0 0 auto; place-items: center; width: 30px; height: 30px; border-radius: 50%; object-fit: cover; }
.docs-header-avatar { width: 22px; height: 22px; border: 1px solid rgba(0,0,0,.14); }
.docs-avatar-fallback { color: #1b160b; background: var(--docs-accent); font-size: 12px; font-weight: 900; }
.docs-small-button, .docs-text-button, .docs-back-button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 39px;
  padding: 0 12px; border: 1px solid var(--docs-border-strong); border-radius: 11px;
  color: var(--text, #f4f0e8); background: rgba(255,255,255,.04); font: inherit; font-size: 11px;
  font-weight: 800; text-decoration: none; cursor: pointer;
  transition: border-color .18s ease, background .18s ease, color .18s ease, transform .18s ease;
}
.docs-small-button:hover { border-color: rgba(255,212,102,.48); background: rgba(255,255,255,.08); transform: translateY(-1px); }
.docs-small-button:disabled, .docs-action-button:disabled { opacity: .5; cursor: not-allowed; }
.docs-small-button:focus-visible, .docs-text-button:focus-visible, .docs-topic-button:focus-visible, .docs-card-link:focus-visible, .docs-back-button:focus-visible { outline: 2px solid var(--docs-accent); outline-offset: 3px; }
.docs-text-button { min-height: 30px; padding: 0; border: 0; border-radius: 0; color: #d6b44e; background: transparent; font-size: 11px; }
.docs-text-button:hover { color: #ffe7a3; }
.docs-search-panel { display: flex; align-items: center; gap: 13px; min-height: 62px; margin-top: 30px; padding: 0 17px; border: 1px solid rgba(255,212,102,.19); border-radius: 15px; background: rgba(0,0,0,.34); box-shadow: 0 14px 40px rgba(0,0,0,.15); }
.docs-search-panel:focus-within { border-color: rgba(255,212,102,.48); box-shadow: 0 0 0 3px rgba(255,212,102,.06); }
.docs-search-icon { color: var(--docs-accent); font-size: 28px; line-height: 1; transform: rotate(-20deg); }
.docs-search-panel input { width: 100%; min-width: 0; border: 0; outline: 0; color: var(--text, #f4f0e8); background: transparent; font: inherit; font-size: 14px; }
.docs-search-panel input::placeholder { color: #77736d; }
.docs-search-clear { width: 28px; height: 28px; flex: 0 0 auto; border: 0; border-radius: 7px; color: inherit; background: rgba(0,0,0,.06); font-size: 21px; cursor: pointer; }
.docs-search-caption { display: flex; justify-content: space-between; gap: 16px; margin-top: 10px; color: #817b73; font-size: 10px; }
.docs-search-caption span:first-child { color: #c5bdaf; }

/* Catalogue: Plugin Portal-style spacing, selectable categories, and per-collection sorting. */
.docs-main-section { min-height: 54vh; background: radial-gradient(ellipse at 0% 12%, rgba(255,255,255,.018), transparent 34%); }
.docs-main-shell { padding-top: 42px; padding-bottom: 72px; }
.docs-section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 24px; }
.docs-section-heading h2 { margin: 9px 0 0; color: var(--text, #f4f0e8); font-size: clamp(28px, 4vw, 40px); line-height: 1.04; letter-spacing: -.06em; }
.docs-section-heading p { margin: 10px 0 0; color: #89837a; font-size: 12px; line-height: 1.7; }
.docs-catalog-layout { display: grid; grid-template-columns: 245px minmax(0,1fr); align-items: start; gap: 27px; }
.docs-topic-sidebar { position: sticky; top: 100px; min-width: 0; padding: 17px 16px 14px; border: 1px solid var(--docs-border); border-radius: 16px; background: rgba(255,255,255,.018); }
.docs-sidebar-label { margin: 0 0 10px 5px; color: #858076; font-size: 9px; font-weight: 900; letter-spacing: .13em; }
.docs-topic-filters { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 6px; }
.docs-topic-button { display: inline-flex; justify-content: space-between; align-items: center; gap: 8px; max-width: 100%; min-height: 32px; padding: 0 11px; border: 1px solid rgba(255,255,255,.09); border-radius: 999px; color: #bdb7ae; background: rgba(255,255,255,.025); text-align: left; font: inherit; font-size: 11px; cursor: pointer; transition: color .18s ease, border-color .18s ease, background .18s ease, transform .18s ease; }
.docs-topic-button span { color: #79736a; font-size: 10px; font-variant-numeric: tabular-nums; }
.docs-topic-button:hover { color: var(--text, #f4f0e8); border-color: rgba(255,212,102,.35); background: rgba(255,212,102,.065); transform: translateY(-1px); }
.docs-topic-button.is-active { color: #17140c; border-color: var(--docs-accent); background: var(--docs-accent); box-shadow: 0 3px 12px rgba(255,212,102,.12); }
.docs-topic-button.is-active span { color: #3d321a; }
.docs-category-filters { max-height: none; overflow: visible; }
.docs-category-filter { min-height: 28px; padding: 0 8px; border-color: rgba(255,255,255,.065); font-size: 10px; }
.docs-sidebar-divider { height: 1px; margin: 17px 0; background: var(--docs-border); }
.docs-sidebar-note { margin-top: 22px; padding: 14px 10px 6px; border-top: 1px solid var(--docs-border); }
.docs-note-mark { color: var(--docs-accent); font-size: 19px; }
.docs-sidebar-note p { margin: 8px 0 4px; color: #eee8dd; font-size: 12px; font-weight: 800; }
.docs-sidebar-note > span:not(.docs-note-mark) { display: block; color: #8e887f; font-size: 10px; line-height: 1.65; }
.docs-sidebar-note .docs-text-button { margin-top: 8px; }
.docs-results-column { min-width: 0; }
.docs-collection + .docs-collection { margin-top: 42px; }
.docs-collection-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.docs-collection-heading h2 { margin: 8px 0 0; color: #f1ede4; font-size: clamp(23px, 3vw, 31px); line-height: 1.12; letter-spacing: -.05em; }
.docs-collection-heading p { margin: 8px 0 0; color: #8e887e; font-size: 11px; line-height: 1.7; }
.docs-collection-tools { display: flex; align-items: center; gap: 9px; flex: 0 0 auto; }
.docs-count-pill { display: inline-flex; align-items: center; justify-content: center; min-width: 25px; min-height: 24px; padding: 0 7px; border: 1px solid rgba(255,212,102,.17); border-radius: 7px; color: var(--docs-accent); background: rgba(255,212,102,.055); font-size: 10px; font-weight: 800; font-variant-numeric: tabular-nums; }
.docs-sort-wrap { display: inline-flex; align-items: center; gap: 7px; color: #888278; font-size: 10px; }
.docs-sort-wrap select { max-width: 150px; min-height: 34px; padding: 0 9px; border: 1px solid var(--docs-border); border-radius: 8px; outline: 0; color: #e3ddd2; background: #111112; font: inherit; font-size: 10px; cursor: pointer; }
.docs-sort-wrap select:focus-visible { border-color: rgba(255,212,102,.5); outline: 2px solid rgba(255,212,102,.15); }
.docs-list { display: grid; gap: 10px; }
.docs-card { position: relative; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 10px 18px; min-width: 0; padding: 19px 20px 17px; border: 1px solid var(--docs-border); border-radius: 15px; background: linear-gradient(125deg, rgba(255,255,255,.035), rgba(255,255,255,.012) 70%); transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.docs-card[data-card-href] { cursor: pointer; }
.docs-card[data-card-href]:hover, .docs-card[data-card-href]:focus-visible { border-color: rgba(255,212,102,.28); background: linear-gradient(125deg, rgba(255,212,102,.055), rgba(255,255,255,.014) 70%); transform: translateY(-2px); outline: none; }
.docs-card[data-card-href]:focus-visible { box-shadow: 0 0 0 2px rgba(255,212,102,.2); }
.docs-card-main { min-width: 0; }
.docs-card-eyebrow { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; color: #858076; font-size: 9px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.docs-card-dot { color: #645e54; }
.docs-topic-pill { display: inline-flex; align-items: center; width: fit-content; min-height: 22px; padding: 0 8px; border: 1px solid rgba(255,212,102,.17); border-radius: 6px; color: var(--docs-accent); background: rgba(255,212,102,.055); font-size: 9px; font-weight: 850; letter-spacing: .025em; text-transform: none; }
.docs-topic-pill-button { position: relative; z-index: 2; min-height: 23px; font: inherit; cursor: pointer; }
.docs-topic-pill-button:hover { color: #16120a; background: var(--docs-accent); }
.docs-card h3 { margin: 11px 0 0; color: #f2eee6; font-size: clamp(16px, 2vw, 20px); line-height: 1.25; letter-spacing: -.035em; overflow-wrap: anywhere; }
.docs-card-link { position: relative; z-index: 1; color: inherit; text-decoration: none; }
.docs-card-link:hover { color: var(--docs-accent); }
.docs-card-summary { margin: 8px 0 0; color: #a9a399; font-size: 12px; line-height: 1.7; overflow-wrap: anywhere; }
.docs-card-categories { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 12px; }
.docs-category-chip { position: relative; z-index: 2; display: inline-flex; align-items: center; min-height: 25px; padding: 3px 7px; border: 1px solid rgba(255,255,255,.075); border-radius: 6px; color: #9c968c; background: rgba(0,0,0,.15); font: inherit; font-size: 9px; text-decoration: none; cursor: pointer; transition: color .16s ease, border-color .16s ease, background .16s ease; }
.docs-category-chip:hover, .docs-category-chip.is-active { color: #17140c; border-color: var(--docs-accent); background: var(--docs-accent); }
.docs-card-metrics { display: flex; flex-wrap: wrap; gap: 7px 15px; margin-top: 14px; color: #8e887e; font-size: 10px; }
.docs-card-metrics span { display: inline-flex; align-items: center; gap: 5px; }
.docs-card-metrics span span { color: var(--docs-accent); font-weight: 850; }
.docs-card-footer { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; margin-top: 14px; color: #7f7a72; font-size: 10px; }
.docs-card-footer > span { display: inline-flex; align-items: center; gap: 5px; }
.docs-card-footer strong { color: #bcb5aa; font-weight: 750; }
.docs-card-arrow { align-self: start; display: grid; place-items: center; width: 32px; height: 32px; border: 1px solid var(--docs-border); border-radius: 9px; color: var(--docs-accent); background: rgba(0,0,0,.18); font-size: 16px; }
.docs-card.is-pending { cursor: default; border-style: dashed; }
.docs-status-pill { padding: 3px 7px; border: 1px solid rgba(255,212,102,.20); border-radius: 5px; color: #d6bd78; background: rgba(255,212,102,.05); font-size: 9px; }
.docs-loading { display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 130px; color: #8d877e; font-size: 12px; }
.docs-loader { width: 18px; height: 18px; flex: 0 0 auto; border: 2px solid rgba(255,255,255,.15); border-top-color: var(--docs-accent); border-radius: 50%; animation: docs-spin .8s linear infinite; }
@keyframes docs-spin { to { transform: rotate(360deg); } }
.docs-empty-state { display: grid; justify-items: center; align-content: center; min-height: 260px; padding: 24px; border: 1px dashed var(--docs-border-strong); border-radius: 16px; color: #8f897f; text-align: center; }
.docs-empty-mark { color: var(--docs-accent); font-size: 34px; }
.docs-empty-state h3 { margin: 10px 0 0; color: #e7e1d7; font-size: 17px; }
.docs-empty-state p { margin: 8px 0 18px; font-size: 12px; }
.docs-inline-empty { grid-column: 1 / -1; padding: 22px 15px; border: 1px dashed var(--docs-border); border-radius: 10px; color: #817b72; font-size: 11px; text-align: center; }

/* Document reading */
.docs-detail { min-width: 0; }
.docs-detail-top { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 27px; }
.docs-back-button { min-height: 36px; padding: 0 13px; border-color: var(--docs-border); color: #c3bcb0; background: rgba(255,255,255,.035); }
.docs-back-button:hover { color: #18140a; border-color: var(--docs-accent); background: var(--docs-accent); }
.docs-reading-layout { display: grid; grid-template-columns: minmax(0,1fr) 210px; align-items: start; gap: 40px; }
.docs-article { min-width: 0; }
.docs-article-header { padding: 0 0 24px; border-bottom: 1px solid var(--docs-border); }
.docs-article-category { display: inline-flex; min-height: 24px; align-items: center; padding: 0 9px; border: 1px solid rgba(255,212,102,.2); border-radius: 6px; color: var(--docs-accent); background: rgba(255,212,102,.06); font-size: 9px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.docs-article-title { margin: 15px 0 0; color: #f5f1e8; font-size: clamp(34px, 5.7vw, 57px); line-height: 1.02; letter-spacing: -.065em; overflow-wrap: anywhere; scroll-margin-top: 100px; }
.docs-article-summary { max-width: 820px; margin: 15px 0 0; color: #b9b2a7; font-size: 15px; line-height: 1.75; }
.docs-article-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 13px; margin-top: 18px; color: #817b72; font-size: 10px; }
.docs-article-meta strong { color: #d6d0c5; font-weight: 800; }
.docs-detail-categories { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 14px; }
.docs-article-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin-top: 20px; }
.docs-action-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 36px; padding: 0 11px; border: 1px solid var(--docs-border-strong); border-radius: 9px; color: #e4ded3; background: rgba(255,255,255,.035); font: inherit; font-size: 10px; font-weight: 800; cursor: pointer; transition: .18s ease; }
.docs-action-button:hover { border-color: rgba(255,212,102,.4); background: rgba(255,255,255,.07); }
.docs-action-button.is-active { color: #17140c; border-color: var(--docs-accent); background: var(--docs-accent); }
.docs-detail-metrics { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 7px 13px; margin-left: auto; color: #8c867d; font-size: 10px; }
.docs-detail-metrics strong { color: #c8c0b5; font-weight: 800; }
.docs-pending-note { margin-top: 15px; padding: 11px 12px; border: 1px solid rgba(255,212,102,.2); border-radius: 9px; color: #d5c394; background: rgba(255,212,102,.05); font-size: 11px; line-height: 1.6; }
.docs-toc { position: sticky; top: 22px; padding: 16px 14px; border: 1px solid var(--docs-border); border-radius: 14px; background: rgba(255,255,255,.02); }
.docs-toc h2 { margin: 0 0 12px; color: #d8d1c6; font-size: 11px; letter-spacing: -.01em; }
.docs-toc-links { display: grid; gap: 9px; }
.docs-toc-links a { color: #969087; font-size: 10px; line-height: 1.55; text-decoration: none; overflow-wrap: anywhere; }
.docs-toc-links a[data-depth="3"], .docs-toc-links a[data-depth="4"] { padding-left: 10px; color: #777168; }
.docs-toc-links a[data-depth="5"], .docs-toc-links a[data-depth="6"] { padding-left: 19px; color: #777168; }
.docs-toc-links a:hover { color: var(--docs-accent); }
.docs-toc-empty { color: #79736a; font-size: 10px; line-height: 1.6; }
.docs-useful-panel { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 42px; padding: 20px; border: 1px solid rgba(255,212,102,.18); border-radius: 14px; background: linear-gradient(110deg, rgba(255,212,102,.055), rgba(255,255,255,.015)); }
.docs-useful-copy h2 { margin: 0; color: #f0e9dd; font-size: 16px; letter-spacing: -.025em; }
.docs-useful-copy p { margin: 6px 0 0; color: #918a80; font-size: 11px; line-height: 1.6; }
.docs-useful-actions { display: flex; flex: 0 0 auto; gap: 7px; }
.docs-feedback-status { margin: 10px 0 0 !important; color: #b7a779 !important; font-size: 10px !important; }
.docs-markdown { min-width: 0; margin-top: 30px; color: #d1cbc1; font-size: 14px; line-height: 1.85; overflow-wrap: anywhere; scroll-margin-top: 100px; }
.docs-markdown > :first-child { margin-top: 0; }
.docs-markdown h1, .docs-markdown h2, .docs-markdown h3, .docs-markdown h4, .docs-markdown h5, .docs-markdown h6 { color: #f4efe6; font-weight: 800; line-height: 1.2; letter-spacing: -.04em; scroll-margin-top: 100px; }
.docs-markdown h1 { margin: 1.8em 0 .7em; font-size: 29px; }
.docs-markdown h2 { margin: 1.7em 0 .65em; padding-bottom: 9px; border-bottom: 1px solid var(--docs-border); font-size: 24px; }
.docs-markdown h3 { margin: 1.45em 0 .5em; font-size: 19px; }
.docs-markdown h4 { margin: 1.3em 0 .45em; font-size: 16px; }
.docs-markdown h5 { margin: 1.2em 0 .4em; font-size: 14px; }
.docs-markdown h6 { margin: 1.1em 0 .35em; color: #d3ccbf; font-size: 13px; }
.docs-markdown p, .docs-markdown ul, .docs-markdown ol, .docs-markdown blockquote, .docs-markdown table { margin: 1em 0; }
.docs-markdown ul, .docs-markdown ol { padding-left: 1.5em; }
.docs-markdown li { margin: .25em 0; padding-left: .2em; }
.docs-markdown a { color: var(--docs-accent); text-decoration-color: rgba(255,212,102,.4); text-underline-offset: 3px; }
.docs-markdown a:hover { color: #ffebad; }
.docs-markdown :not(pre) > code { padding: .19em .42em; border: 1px solid rgba(255,255,255,.075); border-radius: 5px; color: #ffd98a; background: rgba(0,0,0,.35); font: .88em/1.6 ui-monospace, SFMono-Regular, Consolas, monospace; }
.docs-markdown pre code { color: inherit; }
.docs-markdown blockquote { margin-left: 0; padding: 3px 0 3px 15px; border-left: 3px solid rgba(255,212,102,.55); color: #aaa398; }
.docs-markdown hr { height: 1px; margin: 2em 0; border: 0; background: var(--docs-border); }
.docs-markdown img, .docs-markdown .docs-md-image { display: block; max-width: 100%; height: auto; margin: 1.25rem auto; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; object-fit: contain; }
.docs-markdown a:has(img) { display: block; width: fit-content; max-width: 100%; margin-inline: auto; }
.docs-markdown table { display: block; width: 100%; border-collapse: collapse; overflow-x: auto; font-size: 12px; }
.docs-markdown th, .docs-markdown td { min-width: 90px; padding: 9px 10px; border: 1px solid rgba(255,255,255,.13); text-align: left; vertical-align: top; }
.docs-markdown th { color: #f0eadd; background: rgba(255,255,255,.04); }
.docs-markdown tr:nth-child(even) td { background: rgba(255,255,255,.018); }
.docs-markdown .markdown-heading-anchor { display: inline-block; margin-right: 8px; color: var(--docs-accent, #ffd466); font-size: .85em; font-weight: 900; text-decoration: none; opacity: .72; transition: opacity .15s ease, color .15s ease, transform .15s ease; }
.docs-markdown .markdown-heading-anchor:hover, .docs-markdown .markdown-heading-anchor:focus-visible { color: #ffebad; opacity: 1; transform: translateX(-1px); }
.docs-markdown h1:hover .markdown-heading-anchor, .docs-markdown h2:hover .markdown-heading-anchor, .docs-markdown h3:hover .markdown-heading-anchor, .docs-markdown h4:hover .markdown-heading-anchor, .docs-markdown h5:hover .markdown-heading-anchor, .docs-markdown h6:hover .markdown-heading-anchor { opacity: 1; }
.docs-code-block { position: relative; margin: 1.3em 0; border: 1px solid rgba(255,255,255,.105); border-radius: 11px; overflow: hidden; background: #080808; }
.docs-code-block pre { max-width: 100%; margin: 0; padding: 17px; overflow: auto; color: #e9dfcc; font: 12px/1.7 ui-monospace, SFMono-Regular, Consolas, monospace; white-space: pre; }
.docs-code-block pre code { padding: 0; color: inherit; border: 0; background: transparent; font: inherit; }
.docs-code-copy { position: absolute; top: 9px; right: 9px; z-index: 1; display: grid; place-items: center; width: 31px; height: 31px; padding: 6px; border: 1px solid rgba(255,255,255,.14); border-radius: 8px; background: rgba(20,20,20,.92); cursor: pointer; opacity: .72; transition: opacity .15s ease, border-color .15s ease; }
.docs-code-copy:hover { opacity: 1; border-color: rgba(255,212,102,.45); }
.docs-code-copy img { display: block; width: 15px; height: 15px; margin: 0; border: 0; object-fit: contain; }
.docs-code-copy span { position: absolute; right: -1px; top: 35px; padding: 4px 6px; border-radius: 4px; color: #16130b; background: var(--docs-accent); font-family: inherit; font-size: 9px; font-weight: 800; line-height: 1.2; white-space: nowrap; opacity: 0; pointer-events: none; }
.docs-code-copy.is-copied span { opacity: 1; }
.docs-markdown-preview { max-height: 400px; margin: 0; padding: 15px; border: 1px solid var(--docs-border); border-radius: 11px; overflow: auto; background: rgba(0,0,0,.18); }
.docs-markdown-preview[hidden] { display: none !important; }

/* My Library and admin workspace */
.docs-page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.docs-page-heading h2 { margin: 8px 0 0; color: #f2eee6; font-size: clamp(32px, 4.5vw, 48px); line-height: 1; letter-spacing: -.065em; }
.docs-page-heading p { margin: 11px 0 0; color: var(--docs-muted); font-size: 12px; line-height: 1.7; }
.docs-library-title-line { display: flex; align-items: center; gap: 13px; }
.docs-library-avatar { width: 49px; height: 49px; border: 1px solid rgba(255,255,255,.15); box-shadow: 0 4px 16px rgba(0,0,0,.22); }
.docs-library-title-line h2 { margin-top: 5px; }
.docs-library-section + .docs-library-section { margin-top: 39px; }
.docs-library-section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; margin-bottom: 15px; }
.docs-library-section h3, .docs-admin-section h3 { margin: 0; color: #e9e3d9; font-size: 18px; letter-spacing: -.03em; }
.docs-library-section > p, .docs-library-section-heading p { margin: 7px 0 0; color: #89837a; font-size: 11px; }
.docs-library-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.docs-library-grid .docs-card { padding: 17px; }
.docs-library-grid .docs-card h3 { font-size: 17px; }
.docs-heading-actions { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.docs-primary-small { color: #16120a; border-color: var(--docs-accent); background: var(--docs-accent); }
.docs-primary-small:hover { color: #16120a; border-color: #ffe39a; background: #ffe39a; }
.docs-admin-summary { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; margin-bottom: 28px; }
.docs-admin-stat { padding: 15px 17px; border: 1px solid var(--docs-border); border-radius: 12px; background: var(--docs-panel); }
.docs-admin-stat span { display: block; color: #89837a; font-size: 9px; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.docs-admin-stat strong { display: block; margin-top: 7px; color: #f4efe5; font-size: 27px; letter-spacing: -.05em; font-variant-numeric: tabular-nums; }
.docs-admin-section { margin-top: 27px; padding: 20px; border: 1px solid var(--docs-border); border-radius: 16px; background: rgba(255,255,255,.018); }
.docs-admin-section-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; margin-bottom: 16px; }
.docs-admin-section-header p { margin: 6px 0 0; color: #8f897f; font-size: 11px; line-height: 1.6; }
.docs-admin-rows { display: grid; gap: 8px; }
.docs-admin-row { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 12px; min-width: 0; padding: 13px; border: 1px solid rgba(255,255,255,.075); border-radius: 10px; background: rgba(0,0,0,.16); }
.docs-admin-row-main { min-width: 0; }
.docs-admin-row-main strong { display: block; color: #eee8de; font-size: 12px; overflow-wrap: anywhere; }
.docs-admin-row-main p { margin: 5px 0 0; color: #8f897f; font-size: 10px; line-height: 1.6; }
.docs-admin-row-meta { display: flex; flex-wrap: wrap; gap: 6px 11px; margin-top: 7px; color: #777168; font-size: 9px; }
.docs-admin-row-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 5px; }
.docs-admin-row-actions .docs-small-button { min-height: 30px; padding: 0 9px; font-size: 9px; }
.docs-order-buttons { display: flex; gap: 4px; margin-right: 3px; }
.docs-order-buttons button { width: 28px; height: 29px; border: 1px solid var(--docs-border); border-radius: 7px; color: #c7c0b5; background: rgba(255,255,255,.03); cursor: pointer; }
.docs-order-buttons button:disabled { opacity: .28; cursor: default; }
.docs-order-buttons button:not(:disabled):hover { border-color: rgba(255,212,102,.4); color: var(--docs-accent); }
.docs-request-preview { grid-column: 1 / -1; padding: 13px; border-top: 1px solid var(--docs-border); color: #b7b0a5; }
.docs-request-preview .docs-markdown { margin-top: 0; font-size: 12px; }
.docs-admin-status { margin-top: 11px; color: #b5a574; font-size: 10px; }

/* Dialogs / form controls */
.docs-dialog { width: min(760px, calc(100% - 28px)); max-height: min(88vh, 900px); overflow: auto; padding: 24px; border: 1px solid var(--docs-border-strong); border-radius: 19px; color: #f1ece2; background: #0c0c0d; box-shadow: 0 32px 100px rgba(0,0,0,.6); }
.docs-dialog::backdrop { background: rgba(0,0,0,.74); backdrop-filter: blur(6px); }
.docs-auth-dialog { width: min(540px, calc(100% - 28px)); }
.docs-dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; }
.docs-dialog-heading h2 { margin: 8px 0 0; color: #f3eee5; font-size: clamp(24px, 4vw, 33px); line-height: 1.08; letter-spacing: -.05em; }
.docs-dialog-close { display: grid; place-items: center; flex: 0 0 auto; width: 33px; height: 33px; border: 1px solid var(--docs-border); border-radius: 9px; color: #bdb6aa; background: rgba(255,255,255,.035); font-size: 23px; cursor: pointer; }
.docs-dialog-copy { margin: 13px 0 20px; color: #9d968b; font-size: 11px; line-height: 1.7; }
.docs-form { display: grid; gap: 14px; }
.docs-form-row { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 12px; }
.docs-field { display: grid; gap: 7px; min-width: 0; }
.docs-field > span { color: #e5dfd5; font-size: 11px; font-weight: 800; }
.docs-field > span b { color: var(--docs-accent); font-size: 9px; letter-spacing: .08em; }
.docs-field input, .docs-field select, .docs-field textarea { display: block; width: 100%; min-width: 0; border: 1px solid rgba(255,255,255,.13); border-radius: 9px; padding: 11px 12px; outline: 0; color: #f2ede3; background: #151516; font: inherit; font-size: 12px; line-height: 1.65; resize: vertical; }
.docs-field select { cursor: pointer; }
.docs-field input:focus, .docs-field select:focus, .docs-field textarea:focus { border-color: rgba(255,212,102,.48); box-shadow: 0 0 0 3px rgba(255,212,102,.06); }
.docs-field input::placeholder, .docs-field textarea::placeholder { color: #716b62; }
.docs-field small { color: #827b72; font-size: 9px; line-height: 1.6; }
.docs-field small code { color: #e4c66d; }
.docs-preview-tools { display: flex; justify-content: flex-start; margin-top: -6px; }
.docs-form-error { padding: 10px 11px; border: 1px solid rgba(255,120,95,.28); border-radius: 8px; color: #efac9d; background: rgba(255,100,75,.055); font-size: 10px; line-height: 1.6; }
.docs-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; padding-top: 15px; border-top: 1px solid var(--docs-border); }
.docs-dialog-actions .btn { min-height: 39px; }
.docs-toast { position: fixed; top: 76px; right: max(18px, calc((100vw - 1440px) / 2)); z-index: 1000; width: fit-content; max-width: min(360px, calc(100vw - 36px)); margin: 0; padding: 11px 15px; border: 1px solid rgba(255,212,102,.26); border-radius: 11px; color: #e7d5a2; background: rgba(18,17,14,.97); box-shadow: 0 12px 40px rgba(0,0,0,.3); font-size: 11px; line-height: 1.5; animation: docs-toast-in .18s ease-out both; }
.docs-toast.is-success { border-color: rgba(255,212,102,.32); color: #f3dfaa; }
.docs-toast.is-error { border-color: rgba(255,120,95,.35); color: #f2b4a8; }
@keyframes docs-toast-in { from { opacity: 0; transform: translateY(-5px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 1050px) {
  .docs-catalog-layout { grid-template-columns: 210px minmax(0,1fr); gap: 15px; }
  .docs-reading-layout { grid-template-columns: minmax(0,1fr) 180px; gap: 22px; }
  .docs-collection-heading { align-items: flex-start; }
  .docs-collection-tools { align-items: flex-end; }
}
@media (max-width: 900px) {
  .docs-hero-icon { --docs-icon-size: clamp(190px, 29vw, 270px); right: calc(130px - (var(--docs-icon-size) / 2)); bottom: calc(65px - (var(--docs-icon-size) / 2)); opacity: .15; filter: blur(3px) saturate(.82); }
  .docs-hero-row { align-items: flex-start; flex-direction: column; gap: 22px; padding-right: 0; }
  .docs-account-actions { justify-content: flex-start; align-self: flex-start; }
  .docs-account-actions #login-button { min-width: 0; }
  .docs-collection-heading { flex-direction: column; }
  .docs-collection-tools { align-items: center; }
  .docs-reading-layout { grid-template-columns: minmax(0,1fr) 175px; gap: 22px; }
  .docs-article-title { font-size: clamp(31px, 5vw, 47px); }
}
@media (max-width: 640px) {
  .docs-hero { padding: 108px 0 27px; }
  .docs-hero::after { right: -40px; bottom: -90px; width: 270px; height: 270px; box-shadow: 0 0 0 25px rgba(255,255,255,.08), 0 0 0 52px rgba(11,11,12,.03); }
  .docs-hero-icon { --docs-icon-size: clamp(165px, 43vw, 205px); right: calc(95px - (var(--docs-icon-size) / 2)); bottom: calc(45px - (var(--docs-icon-size) / 2)); opacity: .14; filter: blur(2.5px) saturate(.8); }
  .docs-title { font-size: clamp(40px, 10vw, 58px); }
  .docs-search-panel { min-height: 55px; gap: 9px; margin-top: 23px; padding: 0 12px; }
  .docs-search-caption { flex-direction: column; gap: 5px; }
  .docs-main-shell { padding-top: 30px; padding-bottom: 50px; }
  .docs-catalog-layout { grid-template-columns: minmax(0,1fr); }
  .docs-topic-sidebar { position: static; padding: 12px; }
  .docs-topic-filters { display: flex; flex-wrap: wrap; gap: 6px; overflow: visible; padding: 1px 0 5px; }
  .docs-topic-button { width: auto; flex: 0 0 auto; min-height: 32px; border: 1px solid var(--docs-border); padding: 0 10px; }
  .docs-topic-button span { display: none; }
  .docs-category-filters { max-height: none; overflow: visible; }
  .docs-sidebar-note { display: block; }
  .docs-sidebar-divider { margin: 12px 0; }
  .docs-collection + .docs-collection { margin-top: 32px; }
  .docs-collection-heading { gap: 12px; }
  .docs-collection-heading h2 { font-size: 25px; }
  .docs-collection-tools { width: 100%; justify-content: space-between; }
  .docs-card { padding: 16px; }
  .docs-card h3 { font-size: 17px; }
  .docs-card-footer { gap: 7px 10px; }
  .docs-detail-top { align-items: flex-start; }
  .docs-reading-layout { grid-template-columns: minmax(0,1fr); gap: 21px; }
  .docs-toc { position: static; order: -1; }
  .docs-toc-links { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
  .docs-useful-panel { align-items: flex-start; flex-direction: column; gap: 13px; padding: 16px; }
  .docs-library-grid { grid-template-columns: minmax(0,1fr); }
  .docs-library-section-heading { align-items: flex-start; }
  .docs-library-avatar { width: 43px; height: 43px; }
  .docs-detail-metrics { width: 100%; margin-left: 0; padding: 5px 1px; }
  .docs-admin-summary { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 6px; }
  .docs-admin-stat { padding: 11px; }
  .docs-admin-stat span { font-size: 8px; }
  .docs-admin-stat strong { font-size: 22px; }
  .docs-admin-section { padding: 14px; }
  .docs-admin-section-header { align-items: flex-start; flex-direction: column; }
  .docs-admin-row { grid-template-columns: minmax(0,1fr); }
  .docs-admin-row-actions { justify-content: flex-start; }
  .docs-heading-actions { justify-content: flex-start; }
  .docs-page-heading { align-items: flex-start; flex-direction: column; }
  .docs-form-row { grid-template-columns: minmax(0,1fr); }
  .docs-dialog { padding: 19px; }
  .docs-dialog-actions { flex-wrap: wrap; }
  .docs-article-actions { gap: 6px; }
  .docs-article-title { font-size: clamp(32px, 9vw, 44px); }
  .docs-markdown { font-size: 13px; }
  .docs-markdown h1 { font-size: 26px; }
  .docs-markdown h2 { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  .docs-hero-icon, .docs-hero-icon::before, .docs-hero-icon img, .docs-loader { animation: none !important; }
  .docs-card, .docs-small-button, .docs-category-chip { transition: none !important; }
}


/* Final Docs information architecture: official references use a compact horizontal grid; community docs use a flexible gallery. */
.docs-collection-heading { align-items: flex-end; }
.docs-official-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
#official-docs-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: stretch; gap: 12px; }
#official-docs-list .docs-card { display: flex; align-items: flex-start; min-height: 100%; padding: 17px; }
#official-docs-list .docs-card-main { display: flex; flex-direction: column; align-items: flex-start; width: 100%; }
#official-docs-list .docs-card h3 { margin-top: 10px; }
#official-docs-list .docs-card-footer { margin-top: auto; padding-top: 14px; }
#community-docs-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; gap: 12px; }
#community-docs-list .docs-card { display: flex; min-height: 100%; padding: 16px; }
#community-docs-list .docs-card-main { display: flex; flex-direction: column; align-items: flex-start; width: 100%; }
#community-docs-list .docs-card-footer { margin-top: auto; padding-top: 13px; }
#community-docs-list .docs-card-categories { max-width: 100%; }
.docs-choice-field { min-width: 0; margin: 0; padding: 13px; border: 1px solid var(--docs-border); border-radius: 11px; }
.docs-choice-field legend { padding: 0 6px; color: #e5dfd5; font-size: 11px; font-weight: 850; }
.docs-choice-required, .docs-choice-hint { margin-left: 7px; color: #8d867b; font-size: 9px; font-weight: 500; }
.docs-choice-grid { display: flex; flex-wrap: wrap; gap: 7px; }
.docs-choice-chip { position: relative; display: inline-flex; cursor: pointer; }
.docs-choice-chip input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.docs-choice-chip span { display: inline-flex; align-items: center; min-height: 31px; padding: 0 10px; border: 1px solid rgba(255,255,255,.11); border-radius: 8px; color: #aaa398; background: rgba(255,255,255,.025); font-size: 10px; transition: color .16s ease, background .16s ease, border-color .16s ease; }
.docs-choice-chip:hover span, .docs-choice-chip:focus-within span { border-color: rgba(255,212,102,.45); color: #f6e5b2; }
.docs-choice-chip.is-selected span, .docs-choice-chip input:checked + span { border-color: var(--docs-accent); color: #17140c; background: var(--docs-accent); }
.docs-choice-chip input:focus-visible + span { outline: 2px solid var(--docs-accent); outline-offset: 3px; }
.docs-library-heading { align-items: flex-start; }
.docs-library-heading h2 { margin-top: 8px; }
.docs-library-heading p { max-width: 640px; }
.docs-library-section { scroll-margin-top: 92px; }
.docs-pending-library-item { min-width: 0; }
.docs-pending-item-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.docs-pending-preview { padding: 14px; border: 1px solid var(--docs-border); border-radius: 10px; background: rgba(255,255,255,.02); }
.docs-pending-preview h3 { margin: 0 0 10px; color: #f1ede4; font-size: 14px; }
.docs-admin-section + .docs-admin-section { margin-top: 22px; }
.docs-admin-section .docs-admin-row-meta { gap: 7px 12px; }
.docs-admin-status { line-height: 1.7; }

@media (max-width: 1000px) {
  #community-docs-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  #official-docs-list, #community-docs-list { grid-template-columns: minmax(0, 1fr); }
  .docs-collection-heading { align-items: flex-start; flex-direction: column; }
  .docs-collection-tools { width: 100%; justify-content: space-between; }
  .docs-choice-field { padding: 10px; }
  .docs-choice-grid { gap: 6px; }
  .docs-choice-chip span { min-height: 29px; padding: 0 8px; }
  .docs-library-heading { align-items: flex-start; flex-direction: column; }
}


/* Select styling for the admin-only visibility control and helper copy below chip lists. */
.docs-field select { display: block; width: 100%; min-width: 0; min-height: 40px; border: 1px solid rgba(255,255,255,.13); border-radius: 9px; padding: 10px 12px; outline: 0; color: #f2ede3; background: #151516; font: inherit; font-size: 12px; }
.docs-field select:focus { border-color: rgba(255,212,102,.48); box-shadow: 0 0 0 3px rgba(255,212,102,.06); }
.docs-choice-field > small { display: block; margin-top: 9px; color: #827b72; font-size: 9px; line-height: 1.6; }


/* Search/filter and required-field refinements. */
.docs-search-panel input[type="search"]::-webkit-search-cancel-button,
.docs-search-panel input[type="search"]::-webkit-search-decoration,
.docs-search-panel input[type="search"]::-webkit-search-results-button,
.docs-search-panel input[type="search"]::-webkit-search-results-decoration { -webkit-appearance: none; appearance: none; display: none; }
.docs-search-panel input[type="search"] { appearance: textfield; }
.docs-card-cover-wrap { grid-column: 1 / -1; width: 100%; max-height: 180px; overflow: hidden; border-radius: 10px; border: 1px solid rgba(255,255,255,.07); background: rgba(0,0,0,.2); }
.docs-card-cover { display: block; width: 100%; max-height: 180px; object-fit: cover; object-position: center; }
.docs-article-cover { display: block; width: min(100%, 900px); max-height: 420px; margin: 0 0 22px; border: 1px solid var(--docs-border); border-radius: 14px; object-fit: cover; background: rgba(0,0,0,.18); }
.docs-field-inline-error { margin: 8px 0 0; color: #efac9d; font-size: 10px; }
.docs-field input[aria-invalid="true"], .docs-field textarea[aria-invalid="true"] { border-color: rgba(255,120,95,.6); }
.docs-choice-field[aria-invalid="true"] { border-color: rgba(255,120,95,.5); }
.docs-choice-field[aria-invalid="true"] legend { color: #efac9d; }
.docs-choice-chip.docs-choice-category span { border-radius: 999px; }
.docs-card-cover-wrap + .docs-card-main { min-width: 0; }
@media (max-width: 700px) {
  }

/* Shared left-side topic and category filters across Official and Community Docs. */
.docs-category-filters { max-height: none; overflow: visible; }
.docs-category-chip { position: relative; z-index: 2; display: inline-flex; align-items: center; min-height: 25px; padding: 3px 7px; border: 1px solid rgba(255,255,255,.075); border-radius: 6px; color: #9c968c; background: rgba(0,0,0,.15); font: inherit; font-size: 9px; text-decoration: none; cursor: pointer; transition: color .16s ease, border-color .16s ease, background .16s ease; }
.docs-category-chip:hover, .docs-category-chip.is-active { color: #17140c; border-color: var(--docs-accent); background: var(--docs-accent); }
.docs-card-categories, .docs-detail-categories { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 12px; }
@media (max-width: 900px) { .docs-catalog-layout { grid-template-columns: 210px minmax(0,1fr); gap: 15px; } }
@media (max-width: 640px) { .docs-catalog-layout { grid-template-columns: minmax(0,1fr); } .docs-topic-sidebar { position: static; } }

/* =========================================================
   Responsive finishing pass — mobile, tablet, laptop, wide
   Preserve the existing visual design while preventing
   cramped grids, clipped controls, and horizontal overflow.
   ========================================================= */
.docs-root,
.docs-root * {
  min-width: 0;
}
.docs-root img,
.docs-root video,
.docs-root iframe,
.docs-root canvas,
.docs-root svg {
  max-width: 100%;
}
.docs-root button,
.docs-root input,
.docs-root select,
.docs-root textarea {
  max-width: 100%;
}
.docs-root .docs-main-shell,
.docs-root .docs-hero-inner,
.docs-root .docs-results-column,
.docs-root .docs-collection,
.docs-root .docs-detail,
.docs-root .docs-library,
.docs-root .docs-admin,
.docs-root .docs-article,
.docs-root .docs-markdown {
  min-width: 0;
}
.docs-root .docs-markdown p,
.docs-root .docs-markdown li,
.docs-root .docs-markdown blockquote,
.docs-root .docs-markdown a,
.docs-root .docs-article-summary,
.docs-root .docs-card-summary,
.docs-root .docs-admin-row-main,
.docs-root .docs-page-heading p {
  overflow-wrap: anywhere;
  word-break: normal;
}
.docs-root .docs-markdown table {
  max-width: 100%;
}
.docs-root .docs-markdown img,
.docs-root .docs-article-cover,
.docs-root .docs-card-cover {
  height: auto;
}
.docs-root .docs-topic-sidebar,
.docs-root .docs-toc {
  min-width: 0;
}
.docs-root .docs-dialog {
  max-width: calc(100vw - 28px);
  max-height: 88vh;
  max-height: min(88dvh, 900px);
  overscroll-behavior: contain;
}
.docs-root .docs-field input,
.docs-root .docs-field select,
.docs-root .docs-field textarea {
  min-width: 0;
}
.docs-root .docs-action-button,
.docs-root .docs-small-button,
.docs-root .docs-back-button,
.docs-root .docs-dialog-close {
  touch-action: manipulation;
}

@media (min-width: 1600px) {
  .docs-root .docs-hero-inner,
  .docs-root .docs-main-shell {
    width: min(1440px, calc(100% - 96px));
  }
  .docs-root .docs-main-shell { padding-top: 52px; }
  .docs-root .docs-catalog-layout { grid-template-columns: 260px minmax(0, 1fr); gap: 32px; }
  .docs-root #official-docs-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .docs-root #community-docs-list { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .docs-root .docs-reading-layout { grid-template-columns: minmax(0, 1fr) 240px; gap: 46px; }
  .docs-root .docs-markdown { font-size: 15px; }
}

@media (max-width: 1200px) {
  .docs-root .docs-hero { padding-top: 120px; }
  .docs-root .docs-hero-row { gap: 24px; }
  .docs-root .docs-catalog-layout { grid-template-columns: 205px minmax(0, 1fr); gap: 18px; }
  .docs-root .docs-topic-sidebar { padding: 14px 12px; }
  .docs-root #community-docs-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .docs-root .docs-reading-layout { grid-template-columns: minmax(0, 1fr) 175px; gap: 22px; }
}

@media (max-width: 900px) {
  .docs-root .docs-hero { padding-top: 112px; }
  .docs-root .docs-hero-row { align-items: flex-start; flex-direction: column; gap: 18px; }
  .docs-root .docs-account-actions { width: 100%; justify-content: flex-start; align-self: stretch; }
  .docs-root .docs-account-actions #login-button { min-width: 0; }
  .docs-root .docs-catalog-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .docs-root .docs-topic-sidebar { position: static; }
  .docs-root .docs-topic-filters { display: flex; flex-wrap: wrap; gap: 7px; }
  .docs-root .docs-reading-layout { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  .docs-root .docs-toc { position: static; order: -1; }
  .docs-root .docs-toc-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .docs-root .docs-article-actions { align-items: stretch; }
  .docs-root .docs-detail-metrics { margin-left: 0; }
}

@media (max-width: 700px) {
  .docs-root .docs-hero { padding: 100px 0 25px; }
  .docs-root .docs-hero-icon { --docs-icon-size: clamp(145px, 40vw, 190px); right: -12px; bottom: -28px; opacity: .11; }
  .docs-root .docs-hero-row { gap: 17px; }
  .docs-root .docs-title { font-size: clamp(38px, 10vw, 56px); line-height: 1; letter-spacing: -.065em; }
  .docs-root .docs-lede { max-width: 620px; margin-top: 13px; font-size: clamp(14px, 3.5vw, 16px); line-height: 1.65; }
  .docs-root .docs-account-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .docs-root .docs-account-actions > button { width: 100%; min-height: 42px; padding-inline: 9px; white-space: normal; text-align: center; }
  .docs-root .docs-account-actions #login-button { grid-column: 1 / -1; }
  .docs-root .docs-search-panel { min-height: 51px; margin-top: 20px; padding: 0 11px; }
  .docs-root .docs-search-panel input { font-size: 16px; }
  .docs-root .docs-search-caption { gap: 4px; font-size: 10px; }
  .docs-root .docs-main-shell { padding-top: 28px; padding-bottom: 42px; }
  .docs-root .docs-section-heading { align-items: flex-start; gap: 12px; margin-bottom: 19px; }
  .docs-root .docs-section-heading h2 { font-size: clamp(27px, 7.5vw, 35px); }
  .docs-root .docs-section-heading p { font-size: 12px; }
  .docs-root .docs-section-heading > button { flex: 0 0 auto; }
  .docs-root .docs-topic-sidebar { padding: 12px; border-radius: 13px; }
  .docs-root .docs-topic-filters { gap: 6px; }
  .docs-root .docs-topic-button { max-width: 100%; min-height: 36px; padding: 4px 10px; font-size: 11px; }
  .docs-root .docs-topic-button span { display: none; }
  .docs-root .docs-sidebar-note { margin-top: 15px; padding: 12px 4px 2px; }
  .docs-root .docs-sidebar-note p { margin-top: 6px; }
  .docs-root .docs-collection + .docs-collection { margin-top: 28px; }
  .docs-root .docs-collection-heading { align-items: flex-start; flex-direction: column; gap: 10px; }
  .docs-root .docs-collection-heading h2 { font-size: clamp(22px, 6.3vw, 28px); line-height: 1.12; overflow-wrap: anywhere; }
  .docs-root .docs-collection-heading p { max-width: 100%; }
  .docs-root .docs-collection-tools { width: 100%; flex-wrap: wrap; justify-content: space-between; gap: 8px; }
  .docs-root .docs-sort-wrap { min-width: 0; flex: 1 1 175px; justify-content: flex-end; }
  .docs-root .docs-sort-wrap select { width: min(100%, 190px); max-width: 100%; min-height: 38px; font-size: 11px; }
  .docs-root #official-docs-list,
  .docs-root #community-docs-list { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .docs-root #official-docs-list .docs-card,
  .docs-root #community-docs-list .docs-card { padding: 14px; border-radius: 12px; }
  .docs-root .docs-card h3 { font-size: 17px; line-height: 1.3; }
  .docs-root .docs-card-summary { font-size: 12px; line-height: 1.65; }
  .docs-root .docs-card-footer { gap: 8px 10px; }
  .docs-root .docs-detail-top { align-items: flex-start; gap: 12px; margin-bottom: 19px; }
  .docs-root .docs-back-button { min-height: 40px; }
  .docs-root .docs-article-title { margin-top: 12px; font-size: clamp(30px, 9vw, 43px); line-height: 1.05; scroll-margin-top: 78px; }
  .docs-root .docs-article-summary { font-size: 14px; line-height: 1.7; }
  .docs-root .docs-article-meta { gap: 7px 10px; font-size: 10px; }
  .docs-root .docs-article-actions { gap: 7px; }
  .docs-root .docs-action-button { min-height: 40px; padding: 0 10px; }
  .docs-root .docs-detail-metrics { width: 100%; gap: 7px 12px; padding-top: 5px; }
  .docs-root .docs-markdown { margin-top: 24px; font-size: 14px; line-height: 1.8; scroll-margin-top: 78px; }
  .docs-root .docs-markdown h1 { font-size: clamp(25px, 7vw, 30px); }
  .docs-root .docs-markdown h2 { font-size: clamp(21px, 6vw, 25px); }
  .docs-root .docs-markdown h3 { font-size: clamp(18px, 5vw, 21px); }
  .docs-root .docs-markdown pre { max-width: 100%; }
  .docs-root .docs-markdown table { font-size: 11px; }
  .docs-root .docs-markdown th,
  .docs-root .docs-markdown td { min-width: 76px; padding: 8px; }
  .docs-root .docs-useful-panel { align-items: stretch; padding: 15px; gap: 12px; }
  .docs-root .docs-useful-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
  .docs-root .docs-useful-actions .docs-action-button { width: 100%; }
  .docs-root .docs-library-grid { grid-template-columns: minmax(0, 1fr); }
  .docs-root .docs-page-heading h2 { font-size: clamp(29px, 8vw, 42px); overflow-wrap: anywhere; }
  .docs-root .docs-library-title-line { align-items: flex-start; }
  .docs-root .docs-admin-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .docs-root .docs-admin-stat:last-child { grid-column: 1 / -1; }
  .docs-root .docs-admin-stat { padding: 12px; }
  .docs-root .docs-admin-stat strong { font-size: clamp(20px, 6vw, 25px); }
  .docs-root .docs-admin-section { padding: 13px; }
  .docs-root .docs-admin-row { grid-template-columns: minmax(0, 1fr); padding: 11px; }
  .docs-root .docs-admin-row-actions { justify-content: flex-start; }
  .docs-root .docs-admin-row-actions .docs-small-button { min-height: 36px; padding-inline: 10px; font-size: 10px; }
  .docs-root .docs-form-row { grid-template-columns: minmax(0, 1fr); }
  .docs-root .docs-choice-field { padding: 10px; }
  .docs-root .docs-choice-grid { gap: 6px; }
  .docs-root .docs-choice-chip span { min-height: 36px; padding: 0 9px; font-size: 10px; }
  .docs-root .docs-dialog { width: calc(100% - 20px); max-width: calc(100% - 20px); max-height: 90vh; max-height: min(90dvh, 900px); padding: 16px; border-radius: 15px; }
  .docs-root .docs-dialog-heading h2 { font-size: clamp(22px, 6.5vw, 29px); }
  .docs-root .docs-dialog-copy { font-size: 12px; }
  .docs-root .docs-field input,
  .docs-root .docs-field select,
  .docs-root .docs-field textarea { padding: 11px; font-size: 16px; }
  .docs-root .docs-dialog-actions { align-items: stretch; flex-direction: column-reverse; }
  .docs-root .docs-dialog-actions > button,
  .docs-root .docs-dialog-actions > .btn { width: 100%; min-height: 42px; }
  .docs-root .docs-toast { top: auto; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); left: 12px; width: auto; max-width: none; font-size: 12px; }
}

@media (max-width: 420px) {
  .docs-root .docs-shell { width: calc(100% - 24px); }
  .docs-root .docs-hero { padding-top: 92px; }
  .docs-root .docs-title { font-size: clamp(35px, 10vw, 45px); }
  .docs-root .docs-hero-icon { --docs-icon-size: 142px; right: -27px; bottom: -31px; }
  .docs-root .docs-account-actions { grid-template-columns: minmax(0, 1fr); }
  .docs-root .docs-account-actions #login-button { grid-column: auto; }
  .docs-root .docs-section-heading { flex-direction: column; }
  .docs-root .docs-section-heading > button { align-self: flex-start; }
  .docs-root .docs-topic-button { font-size: 10px; padding-inline: 8px; }
  .docs-root .docs-toc-links { grid-template-columns: minmax(0, 1fr); }
  .docs-root .docs-article-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .docs-root .docs-article-actions > .docs-action-button { width: 100%; }
  .docs-root .docs-detail-metrics { grid-column: 1 / -1; }
  .docs-root .docs-article-title { font-size: clamp(29px, 9vw, 36px); }
  .docs-root .docs-markdown { font-size: 13px; }
  .docs-root .docs-markdown h1 { font-size: 24px; }
  .docs-root .docs-markdown h2 { font-size: 20px; }
  .docs-root .docs-markdown h3 { font-size: 17px; }
  .docs-root .docs-useful-actions { grid-template-columns: minmax(0, 1fr); }
  .docs-root .docs-library-title-line { flex-direction: column; }
  .docs-root .docs-admin-summary { gap: 7px; }
  .docs-root .docs-admin-stat span { letter-spacing: .06em; }
}

@media (max-width: 350px) {
  .docs-root .docs-shell { width: calc(100% - 20px); }
  .docs-root .docs-main-shell { padding-top: 22px; }
  .docs-root .docs-hero { padding: 86px 0 22px; }
  .docs-root .docs-title { font-size: 34px; }
  .docs-root .docs-account-actions > button { font-size: 10px; }
  .docs-root .docs-search-panel { padding-inline: 8px; }
  .docs-root .docs-search-icon { font-size: 23px; }
  .docs-root .docs-topic-sidebar { padding: 9px; }
  .docs-root .docs-card { padding: 12px; }
  .docs-root .docs-detail-top { flex-direction: column; }
  .docs-root .docs-article-actions { grid-template-columns: minmax(0, 1fr); }
  .docs-root .docs-admin-summary { grid-template-columns: minmax(0, 1fr); }
  .docs-root .docs-admin-stat:last-child { grid-column: auto; }
  .docs-root .docs-dialog { width: calc(100% - 12px); max-width: calc(100% - 12px); padding: 13px; }
}

/* Compact-height landscape screens: avoid wasting the visible viewport on the hero. */
@media (max-height: 520px) and (orientation: landscape) {
  .docs-root .docs-hero { padding-top: 82px; padding-bottom: 22px; }
  .docs-root .docs-hero-icon { opacity: .08; }
  .docs-root .docs-title { font-size: clamp(34px, 6vw, 49px); }
  .docs-root .docs-search-panel { margin-top: 16px; }
  .docs-root .docs-dialog { max-height: 94vh; max-height: 94dvh; }
}

/* Larger touch targets on touch-only devices without changing desktop density. */
@media (hover: none) and (pointer: coarse) {
  .docs-root .docs-topic-button,
  .docs-root .docs-category-chip,
  .docs-root .docs-action-button,
  .docs-root .docs-small-button,
  .docs-root .docs-back-button { min-height: 40px; }
  .docs-root .docs-card:hover { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .docs-root *, .docs-root *::before, .docs-root *::after { scroll-behavior: auto !important; }
}


/* Cover images should sit above document-card content and retain the 1200×630 ratio.
   The collection layouts use flex by default; use a two-column card grid so the cover
   spans the full card width while the arrow stays beside the text. */
.docs-root #official-docs-list .docs-card,
.docs-root #community-docs-list .docs-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-content: start;
}
.docs-root #official-docs-list .docs-card-cover-wrap,
.docs-root #community-docs-list .docs-card-cover-wrap {
  grid-column: 1 / -1;
  width: 100%;
  max-height: none;
  aspect-ratio: 1200 / 630;
}
.docs-root #official-docs-list .docs-card-cover,
.docs-root #community-docs-list .docs-card-cover {
  width: 100%;
  height: 100%;
  max-height: none;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
  object-position: center;
}
