/* Docs (2026-10-01). Site tokens only (base.css, on body.v2). The sidebar
   reproduces the admin console's look (admin.css "Sidebar shell") with the
   site's tokens; coral is for actions and screenshot markers only. */

.docs-bar { position: sticky; top: calc(var(--nav-height) + var(--dcms-hb-h, 0px)); z-index: 20; background: var(--bg-void);
  border-bottom: 1px solid var(--hairline); }
.docs-bar-inner { max-width: 1440px; margin: 0 auto; padding: 10px var(--s-3);
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-2); }
.docs-crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; color: var(--text-muted); min-width: 0; }
.docs-crumbs a { color: var(--text-muted); text-decoration: none; }
.docs-crumbs a:hover { color: var(--text-primary); }
.docs-crumbs [aria-current] { color: var(--text-primary); }

.docs-layout { max-width: 1440px; margin: 0 auto; display: grid;
  grid-template-columns: 260px minmax(0, 1fr) 220px; gap: var(--s-4); padding: 0 var(--s-3); }

/* Sidebar — the admin console's language */
.docs-side { position: sticky; top: calc(var(--nav-height) + var(--dcms-hb-h, 0px) + 58px); align-self: start;
  max-height: calc(100vh - var(--nav-height) - 58px); overflow-y: auto; padding: var(--s-3) 0;
  border-right: 1px solid var(--border-subtle);
  scrollbar-width: thin; scrollbar-color: var(--border-strong) var(--bg-void); }
/* Navy scrollbar, the same treatment as the DonkeyCMS admin's editors (2026-10-02). */
.docs-side::-webkit-scrollbar { width: 10px; }
.docs-side::-webkit-scrollbar-track { background: var(--bg-void); }
.docs-side::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 6px; border: 2px solid var(--bg-void); }
.docs-side::-webkit-scrollbar-thumb:hover { background: #4a5d85; }
.docs-menu-btn { display: none; }
.docs-menu { display: flex; flex-direction: column; gap: 2px; padding-right: 12px; }
.docs-menu-group { margin: 18px 8px 6px; font-size: 11px; font-weight: 600; text-transform: uppercase;
  letter-spacing: .06em; }
.docs-menu-group:first-child { margin-top: 0; }
.docs-menu-group a { color: var(--text-muted); text-decoration: none; }
.docs-menu-group a:hover { color: var(--text-primary); }
.docs-menu-item { display: block; padding: 8px 10px; border-radius: 6px; font-size: 14px;
  color: var(--text-muted); text-decoration: none; }
.docs-menu-item:hover { color: var(--text-primary); background: var(--bg-surface-alt); }
.docs-menu-item.is-current { color: var(--text-primary); background: var(--bg-surface-alt);
  box-shadow: inset 3px 0 0 var(--accent); }
/* Plan filter above the menu (Buğra, 2026-10-09). A plan shows everything that plan
   includes, so only guides of HIGHER plans go. The page being read and its group always
   stay. The chosen button takes its plan's pill color. */
.docs-filter { margin: 0 12px var(--s-2) 0; padding: 0 0 var(--s-2); border-bottom: 1px solid var(--border-subtle); }
.docs-filter[hidden] { display: none; }
.docs-filter-label { margin: 0 8px 8px; font-size: 11px; font-weight: 600; text-transform: uppercase;
  letter-spacing: .06em; color: var(--text-muted); }
.docs-filter-btns { display: flex; gap: 4px; }
.docs-filter-btn { flex: 1 1 auto; height: 26px; padding: 0 6px; white-space: nowrap; border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill); background: transparent; color: var(--text-muted);
  font: 600 11px/1 var(--font-body); cursor: pointer; }
.docs-filter-btn:hover { color: var(--text-primary); border-color: var(--text-muted); }
.docs-filter-btn[aria-pressed="true"] { background: var(--bg-surface-alt); border-color: rgba(255, 255, 255, .38);
  color: var(--text-primary); }
.docs-filter-pro[aria-pressed="true"] { background: var(--accent-voice); border-color: transparent; color: #131b2e; }
.docs-filter-business[aria-pressed="true"] { background: #4fd18f; border-color: transparent; color: #131b2e; }
.docs-filter-agency[aria-pressed="true"] { background: #f4c94e; border-color: transparent; color: #131b2e; }
.docs-filter-note { margin: 8px 8px 0; font-size: 12px; color: var(--text-muted); }
[data-docs-plan="free"] .docs-menu [data-plan="pro"]:not(.is-current),
[data-docs-plan="free"] .docs-menu [data-plan="business"]:not(.is-current),
[data-docs-plan="free"] .docs-menu [data-plan="agency"]:not(.is-current),
[data-docs-plan="pro"] .docs-menu [data-plan="business"]:not(.is-current),
[data-docs-plan="pro"] .docs-menu [data-plan="agency"]:not(.is-current),
[data-docs-plan="business"] .docs-menu [data-plan="agency"]:not(.is-current) { display: none; }

/* Content */
.docs-main { min-width: 0; padding: var(--s-4) 0 var(--s-7); }
.docs-article { max-width: 720px; color: var(--text-primary); font-size: 16px; line-height: 1.7; }
.docs-title { font-family: var(--font-heading); font-weight: 600; font-size: 36px; line-height: 1.2;
  margin: 0 0 var(--s-2); }
.docs-lead { color: var(--text-muted); font-size: 18px; }
.docs-article h2 { font-family: var(--font-heading); font-weight: 600; font-size: 24px;
  margin: var(--s-6) 0 var(--s-2); scroll-margin-top: calc(var(--nav-height) + 80px); }
.docs-article h3 { font-family: var(--font-heading); font-weight: 600; font-size: 19px;
  margin: var(--s-5) 0 var(--s-2); scroll-margin-top: calc(var(--nav-height) + 80px); }
.docs-article p, .docs-article li { color: #cfd6e6; }
/* Reading rhythm (Buğra, 2026-10-02: "never squeeze things, people should feel their eyes
   comfortable"). base.css zeroes every margin inside .v2, so each block gets its space back
   here. :where() keeps this at the reset's weight, so the screenshot legend and the tip
   boxes, which set their own margins further down, still win. */
.docs-article :where(p, pre, ol, ul, .docs-table-wrap) { margin: 0 0 var(--s-3); }
/* A sentence that introduces a code box or a list ("The menu line:") sits closer to it. */
.docs-article :where(p:has(+ pre, + ol, + ul)) { margin-bottom: var(--s-2); }
.docs-article a { color: var(--accent-voice); }
.docs-article strong { color: var(--text-primary); }
.docs-article code { font-family: Consolas, Menlo, monospace; font-size: .9em; background: var(--bg-surface-alt);
  border: 1px solid var(--border-subtle); border-radius: 5px; padding: 1px 6px; }
.docs-article pre { background: var(--bg-surface); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm); padding: var(--s-2); overflow-x: auto; }
.docs-article pre code { background: none; border: 0; padding: 0; }
/* Marked lines in a code example ("```html mark=2-9"): the code the reader replaces.
   Coral by Buğra's request (2026-10-02), the one non-action use: it marks what to act on. */
.docs-article pre.has-marks { padding-left: 0; padding-right: 0; }
.docs-article pre.has-marks code { display: inline-block; min-width: 100%; } /* marks reach the end of long lines when the box scrolls */
.docs-code-line { display: block; padding: 0 var(--s-2); border-left: 3px solid transparent; }
.docs-code-line.is-marked { background: var(--accent-soft); border-left-color: var(--accent); color: var(--accent); }
.docs-article ol, .docs-article ul { padding-left: 1.4em; }
.docs-article li { margin: 6px 0; }
.docs-table-wrap { overflow-x: auto; margin: var(--s-2) 0; }
.docs-article table { border-collapse: collapse; width: 100%; font-size: 15px; }
.docs-article th, .docs-article td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border-subtle); }
.docs-article th { color: var(--text-muted); font-weight: 600; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; }
.docs-box { border-radius: var(--radius-sm); padding: 14px 16px; margin: var(--s-3) 0;
  background: var(--accent-voice-soft); border: 1px solid var(--accent-voice-line); }
.docs-box p { margin: 0; }
.docs-box-warning { background: rgba(240, 180, 80, .08); border-color: rgba(240, 180, 80, .35); }
/* Plan pills (Buğra, 2026-10-02): one per plan that includes the feature, from the
   guide's own plan up. Free is an outline; Pro blue, Business green, Agency yellow, each
   with navy text. Labels, not buttons, so none of them is coral. Placed per context below. */
.docs-plans { display: inline-flex; flex-wrap: wrap; gap: 6px; flex: none; }
.docs-plan { display: inline-block; flex: none; width: auto; font: 700 10.5px/1 var(--font-body); letter-spacing: .05em;
  padding: 5px 9px; border: 1px solid transparent; border-radius: var(--radius-pill); color: #131b2e; white-space: nowrap; }
.docs-plan-free { background: transparent; border-color: rgba(255, 255, 255, .38); color: var(--text-primary); }
.docs-plan-pro { background: var(--accent-voice); }
.docs-plan-business { background: #4fd18f; }
.docs-plan-agency { background: #f4c94e; }
.docs-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s-2);
  flex-wrap: wrap; margin: 0 0 var(--s-2); }
.docs-title-row .docs-title { margin: 0; }
.docs-title .pill-new { margin-left: 10px; position: relative; top: -4px; }
/* In the menu the pill comes BEFORE the title and is as tall as the title's capital
   letters (Buğra, 2026-10-08): 14px Inter has capitals about 10px tall. */
.docs-menu-item .pill-new { margin: 0 7px 0 0; padding: 0 5px; font-size: 7.5px; line-height: 11px;
  letter-spacing: 0.06em; position: relative; top: -1px; }
.docs-title-row .docs-plans { margin-top: 12px; }

/* Screenshots */
.docs-shot { margin: var(--s-4) 0; }
/* margin-inline auto centers a narrow (phone) shot, whose frame is capped at its own width. */
.docs-shot-frame { position: relative; display: block; margin-inline: auto; border-radius: 12px; overflow: hidden;
  border: 1px solid var(--border-strong); box-shadow: 0 18px 40px rgba(0, 0, 0, .35); cursor: zoom-in; }
.docs-shot-frame img { display: block; width: 100%; height: auto; }
.docs-mark { position: absolute; pointer-events: none; }
.docs-mark-dot { width: 28px; height: 28px; margin: -14px 0 0 -14px; border-radius: 50%;
  background: var(--accent); color: #131b2e; font: 700 14px/28px var(--font-body); text-align: center;
  box-shadow: 0 0 0 4px rgba(221, 120, 103, .3); }
.docs-mark-box { border: 2px solid var(--accent); border-radius: 8px; box-shadow: 0 0 0 4px rgba(221, 120, 103, .18); }
.docs-mark-box b { position: absolute; top: -12px; left: -12px; width: 24px; height: 24px; border-radius: 50%;
  background: var(--accent); color: #131b2e; font: 700 13px/24px var(--font-body); text-align: center; }
.docs-shot-legend { margin: var(--s-2) 0 0; padding-left: 1.4em; font-size: 15px; color: var(--text-muted); }
.docs-shot-legend li::marker { color: var(--accent); font-weight: 700; }
.docs-lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(10, 14, 26, .92);
  display: flex; align-items: center; justify-content: center; padding: 16px; cursor: zoom-out; }
/* The stage hugs the picture, so the copied marks' percentages match the picture exactly. */
.docs-lightbox-stage { position: relative; display: inline-block; }
.docs-lightbox img { display: block; max-width: calc(100vw - 32px); max-height: calc(100vh - 32px); border-radius: 8px; }

/* Pager and footer of an article */
.docs-pager { display: flex; justify-content: space-between; gap: var(--s-2); margin-top: var(--s-6); }
.docs-pager a { flex: 1; max-width: 48%; padding: 14px 16px; border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm); text-decoration: none; color: var(--text-primary); }
.docs-pager a:hover { border-color: var(--border-strong); background: var(--bg-surface); }
.docs-pager small { display: block; color: var(--text-muted); font-size: 12px; text-transform: uppercase; letter-spacing: .05em; }
.docs-pager-next { margin-left: auto; text-align: right; }
/* Chevron on the outer side of each card; coral because the card is a link. Nudges outward on hover. */
.docs-pager a { display: flex; align-items: center; gap: 14px; }
.docs-pager-next { justify-content: flex-end; }
.docs-pager-chev { flex: 0 0 auto; width: 22px; height: 22px; fill: none; stroke: var(--accent); stroke-width: 2.5;
  stroke-linecap: round; stroke-linejoin: round; transition: transform .15s ease; }
.docs-pager-prev:hover .docs-pager-chev { transform: translateX(-3px); }
.docs-pager-next:hover .docs-pager-chev { transform: translateX(3px); }
.docs-stuck { margin-top: var(--s-4); color: var(--text-muted); font-size: 15px; }
.docs-topic-list { list-style: none; padding: 0; }
.docs-topic-list a { position: relative; display: block; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm);
  margin-bottom: 10px; text-decoration: none; color: var(--text-primary); }
.docs-topic-list a:hover { border-color: var(--border-strong); background: var(--bg-surface); }
.docs-topic-list .docs-topic-desc { display: block; color: var(--text-muted); font-size: 15px; margin-top: 4px; }
/* Under the guide's description. */
.docs-topic-list .docs-plans { display: flex; margin-top: 10px; }

/* On this page */
.docs-toc { position: sticky; top: calc(var(--nav-height) + var(--dcms-hb-h, 0px) + 58px); align-self: start; padding: var(--s-4) 0;
  font-size: 14px; display: flex; flex-direction: column; gap: 8px; }
.docs-toc-title { margin: 0 0 4px; font-size: 11px; font-weight: 600; text-transform: uppercase;
  letter-spacing: .06em; color: var(--text-muted); }
.docs-toc a { color: var(--text-muted); text-decoration: none; }
.docs-toc a:hover { color: var(--text-primary); }

/* Search (compact + hero share the dropdown) */
.docs-search { position: relative; }
.docs-search-compact { width: min(340px, 45vw); }
.docs-search-input { width: 100%; box-sizing: border-box; font: inherit; font-size: 15px; color: var(--text-primary);
  background: var(--bg-surface); border: 1px solid var(--border-strong); border-radius: var(--radius-btn);
  padding: 9px 64px 9px 14px; }
.docs-search-input::-webkit-search-cancel-button { -webkit-appearance: none; display: none; } /* browser's blue × clashed with the Ctrl K hint */
.docs-search-input:focus { outline: 2px solid var(--accent-voice-line); outline-offset: 1px; }
.docs-kbd { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font: 12px var(--font-body);
  color: var(--text-muted); border: 1px solid var(--border-strong); border-radius: 5px; padding: 1px 6px; pointer-events: none; }
.docs-results { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 30; list-style: none;
  margin: 0; padding: 6px; background: var(--bg-surface); border: 1px solid var(--border-strong);
  border-radius: 12px; box-shadow: 0 24px 50px rgba(0, 0, 0, .45); max-height: 70vh; overflow-y: auto; text-align: left; }
.docs-result a { display: block; padding: 10px 12px; border-radius: 8px; text-decoration: none; color: var(--text-primary); }
.docs-result.is-active a, .docs-result a:hover { background: var(--bg-surface-alt); }
.docs-result-title { font-weight: 600; }
/* Right end of the result's first line; only that line keeps clear of it, so
   the snippet below still uses the full width. */
.docs-result a { position: relative; }
.docs-result-head { display: block; }
.docs-result .docs-plans { display: flex; margin-top: 6px; }
.docs-result .docs-plan { font-size: 9.5px; padding: 4px 7px; }
.docs-result-section { color: var(--text-muted); font-size: 13px; }
.docs-result-snippet { display: block; color: var(--text-muted); font-size: 14px; margin-top: 2px; }
.docs-result mark { background: none; color: var(--accent); font-weight: 600; }
.docs-result-empty { padding: 12px; color: var(--text-muted); }
.docs-result-empty a { color: var(--accent-voice); }

/* Tablet and phone */
@media (max-width: 1199px) {
  .docs-layout { grid-template-columns: 240px minmax(0, 1fr); }
  .docs-toc { display: none; }
}
@media (max-width: 860px) {
  .docs-layout { display: block; padding: 0 16px; }
  .docs-bar-inner { padding: 10px 16px; flex-wrap: wrap; }
  .docs-search-compact { width: 100%; }
  .docs-side { position: static; max-height: none; border-right: 0; border-bottom: 1px solid var(--border-subtle);
    padding: 12px 0; overflow: visible; }
  .docs-menu-btn { display: inline-block; background: var(--bg-surface-alt); color: var(--text-primary);
    border: 1px solid var(--border-strong); border-radius: 6px; padding: 8px 14px; font: inherit; min-height: 44px; cursor: pointer; }
  .docs-menu { display: none; padding-top: 8px; }
  .docs-side.is-open .docs-menu { display: flex; }
  .docs-filter { display: none; margin: 12px 0 0; }
  .docs-side.is-open .docs-filter { display: block; }
  .docs-side.is-open .docs-filter[hidden] { display: none; }
  .docs-filter-btn { height: 44px; font-size: 13px; }
  .docs-menu-item { padding: 12px 10px; }
  .docs-title { font-size: 28px; }
  .docs-pager { flex-direction: column; }
  .docs-pager a { max-width: none; }
  .docs-pager-next { margin-left: 0; }   /* full width when stacked */
}

/* Docs home */
.docs-home { max-width: 1100px; margin: 0 auto; padding: var(--s-7) var(--s-3) var(--s-8); }
.docs-hero { text-align: center; max-width: 720px; margin: 0 auto var(--s-6); }
.docs-hero-eyebrow { color: var(--accent-voice); font-size: 13px; font-weight: 600; letter-spacing: .08em;
  text-transform: uppercase; margin: 0 0 var(--s-1); }
.docs-hero-title { font-family: var(--font-heading); font-weight: 600; font-size: 48px; line-height: 1.1; margin: 0 0 var(--s-4); }
.docs-search-hero .docs-search-input { font-size: 18px; padding: 18px 76px 18px 22px; border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .35); }
.docs-hero-try { color: var(--text-muted); font-size: 14px; margin-top: var(--s-2); }
.docs-hero-try a { color: var(--text-muted); }
.docs-topics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-3); }
.docs-topic-card { display: block; padding: var(--s-3); border-radius: var(--radius-card); background: var(--bg-surface);
  border: 1px solid var(--border-subtle); text-decoration: none; color: var(--text-primary);
  transition: border-color .2s, transform .2s; }
.docs-topic-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.docs-topic-card h2 { font-family: var(--font-heading); font-weight: 600; font-size: 20px; margin: var(--s-2) 0 6px; }
.docs-topic-card p { color: var(--text-muted); font-size: 15px; line-height: 1.55; margin: 0 0 var(--s-2); }
.docs-topic-count { font-size: 13px; color: var(--accent-voice); }
.docs-icon { color: var(--text-primary); }
.docs-icon .docs-icon-accent { stroke: var(--accent); }
@media (max-width: 960px) { .docs-topics { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) {
  .docs-home { padding: var(--s-5) 16px var(--s-7); }
  .docs-hero-title { font-size: 34px; }
  .docs-topics { grid-template-columns: 1fr; }
  .docs-search-hero .docs-search-input { font-size: 16px; padding: 14px 16px; }
  .docs-search-hero .docs-kbd { display: none; }
}
