/* Small text / footnote content classes — used by insertSmallText command and xml2md converter. */
.Small_Text { font-size: 0.8em; }
p.footnote   { font-size: 0.8em; }

/* Superscript / subscript. The shared production CSS reset (css.css) flattens bare
 * <sup>/<sub> to `vertical-align: baseline; font: inherit`, which neutralizes the
 * browser default and makes superscript text sit on the baseline at full size.
 * Restore the raised/lowered offset + smaller size, scoped under .topic so the
 * specificity beats the element-level reset. Writers author plain <sup>/<sub>
 * (the Superscript insert command + corpus); Pandoc passes them through to gen
 * unchanged, so this one rule fixes both preview and production output. */
.topic sup { vertical-align: super; font-size: 0.83em; }
.topic sub { vertical-align: sub;   font-size: 0.83em; }

/* Topic-body images must never overflow their column. Mirrors editor-source-code's
 * recent toggle fix (ImageDomService.buildToggleElement): cap width to container,
 * preserve aspect ratio via height:auto. xml2md bakes scale into width/height, so
 * the image renders at intended size when there's room and shrinks proportionally
 * otherwise. Same rule lives in preview-extra.css for the preview webview. */
.topic img,
.topic a[data-md-image] > img {
  max-width: 100%;
  height: auto;
}

/* md_multi.css — Override sheet for MD-generated topic pages.
 *
 * Scoped to .multi-md (a marker class on <article>). The MD pipeline emits
 * simplified HTML (no List_L1, T_Controls, value="N" styleclasses), so prod's
 * class-keyed rules in css.css don't fire. This file mirrors the safe subset
 * of css.css's `.release-notes` block (which exists for the same reason) using
 * simple selectors that do match our HTML.
 *
 * Source rules: see media/css.css `.release-notes …` block (~line 4084-4250).
 * Excluded from that block:
 *   - Blue_Table first-row flatten (we want prod's bold blue header row).
 *   - `.mini-toc / .pdf-TOC / .page-toc__search-global / .veeam-logo-pdf {
 *      display: none }` — those are visible on prod docs pages.
 *   - `figcaption { display: none }` — neutral but skipped on principle.
 *
 * Per memory feedback_css_files_role: css.css is read-only; this file is the
 * only place to add visual deltas. When css.css updates, re-audit this file
 * against the new release-notes block.
 */

/* Inline elements: restore <em>/<i> stripped by the global CSS reset. */
.multi-md em, .multi-md i {
    font: revert !important
}

/* Inline code: prod uses .code (XSL-emitted span); we use <code> from MD. */
.multi-md .code, .multi-md code {
    font-family: "Courier New", Courier, serif;
    font-size: 13px;
    line-height: 16px;
    color: var(--base-font-color, #232323);
    margin: 0 !important;
    padding: 0;
    white-space: break-spaces;
    background: none;
    border: none
}

/* ── Breadcrumb (production parity with Kraken topic.html) ── */
.breadcrumb {
  font-size: 13px;
}
.topic ol.breadcrumb > li.breadcrumb__item--home > a {
  display: inline-flex;
  align-items: center;
  padding-top: 3px;
}
.topic ol.breadcrumb > li.breadcrumb__item--home > a > span {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.topic ol.breadcrumb > li.breadcrumb__item--home > a::before {
  content: "";
  display: inline-block;
  width: 1.3em;
  height: 1em;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 90'%3E%3Cpath fill='%2300b336' fill-rule='evenodd' d='M50 4 Q52 2 54 4 L98 42 Q100 44 98 46 L84 46 L84 86 Q84 88 82 88 L18 88 Q16 88 16 86 L16 46 L2 46 Q0 44 2 42 Z M40 62 L40 88 L60 88 L60 62 Z'/%3E%3C/svg%3E") no-repeat center/contain;
}

/* Ordered-list item margins. Prod's `.topic ol li.List_L1` rule doesn't fire
 * on our unclassed <li>; restore the same spacing via simple selector. */
.topic .multi-md ol:not(.breadcrumb) > li {
    margin: 16px 0 12px 32px
}

/* Spacing between a list and the paragraph after it. */
.topic .multi-md ol + p, .topic .multi-md ul + p {
    margin-top: 24px !important
}

/* Subheadings — keep prod's font sizing (specificity bump for our pages). */
.topic .multi-md p.Subheading,
.topic .multi-md p.Subheading_L2,
.topic .multi-md p.Subheading_L3 {
    scroll-margin-top: 80px !important
}
.topic .multi-md p.Subheading    { font-size: 21px }
.topic .multi-md p.Subheading_L2 { font-size: 16px }
.topic .multi-md p.Subheading_L3 { font-size: 15px }

/* H4/H5 styling — Pandoc emits these; no rule in prod default for them. */
.topic .multi-md p.Subheading_L4,
.topic .multi-md p.Subheading_L5 {
    font-family: "Guardian Sans LC", Helvetica, Arial, sans-serif;
    font-weight: 600;
    font-style: normal;
    font-stretch: normal;
    color: var(--base-font-color, #232323);
    line-height: 20px;
    margin: 16px 0 16px
}
.topic .multi-md p.Subheading_L4 { font-size: 16px }
.topic .multi-md p.Subheading_L5 { font-size: 14px }

/* Hover colour for back/PDF links inside multi-md pages. */
.multi-md .link--back:hover,
.multi-md .link--pdf:hover {
    color: var(--link-color, #00b336)
}

/* Blue_Table cell padding — keep prod's first-row bold header (we DO NOT
 * include the .release-notes Blue_Table flatten override here). */
.topic .multi-md table.Blue_Table td,
.topic .multi-md table.Blue_Table th {
    padding: 0
}

/* css.css's `.topic table.Blue_Table tbody>tr:first-child>td` rule (grey
 * background + bold) is a legacy fallback for prod's OLD Blue_Table markup,
 * which has NO <thead> at all — every row (including the header) lives in one
 * <tbody>, so "first row of tbody" == "the header row". Our MD pipeline (both
 * GFM pipe tables and Pandoc-style `+---+` grid tables — markdown-it always
 * emits a real <thead>/<tbody> split for either syntax) always puts the real
 * header in <thead>, so that legacy rule instead lands on the FIRST DATA ROW
 * and paints it grey, e.g. the "Windows | FAT,FAT32,NTFS,ReFS" row in an
 * OS/Supported-File-Systems table. Neutralize it: the header is already
 * styled correctly via the `td.Header, th, thead` rule above it in css.css.
 * Production only flattens this under a `.release-notes` ancestor (with
 * !important) which our preview/gen doesn't add, and css.css ALSO forces the
 * first tbody row's `<p>` text to white/bold — so we must reset the cell AND its
 * `<p>` (background, weight, and text color) and use !important to beat the
 * legacy rule regardless of injection order or `.release-notes` !important. */
.topic .multi-md table.Blue_Table tbody > tr:first-child > td,
.topic .multi-md table.Blue_Table tbody > tr:first-child > td p {
    background-color: transparent !important;
    font-weight: 400 !important;
    color: var(--article-font-color, #232323) !important;
    border-top: 1px solid var(--table-border-color, #fff);
}

/* Nested-list indent + marker style. Prod uses class-keyed L2/L3 rules; this
 * relies on selector depth instead. */
.topic .multi-md ol ul, .topic .multi-md ul ul {
    padding-left: 16px
}
.topic .multi-md ol ol li, .topic .multi-md ul ol li {
    list-style: lower-alpha !important
}
.topic .multi-md ol ol ol li, .topic .multi-md ol ul ol li,
.topic .multi-md ul ol ol li, .topic .multi-md ul ul ol li {
    list-style: lower-roman !important
}
.topic .multi-md ul ol li::before, .topic .multi-md ol ol li::before {
    content: none
}
.topic .multi-md ol ol ul li, .topic .multi-md ol ul ul li,
.topic .multi-md ul ol ul li, .topic .multi-md ul ul ul li {
    list-style: square !important;
    margin-left: 16px;
    padding-left: 3px
}
.topic .multi-md ol ol ul li::before, .topic .multi-md ol ul ul li::before,
.topic .multi-md ul ol ul li::before, .topic .multi-md ul ul ul li::before {
    content: none
}

/* TOC search-list padding (matches release-notes pages). */
.multi-md .page-toc__search-list {
    padding-bottom: 10px
}

/* Footer last-modified line. */
.multi-md .last_modified, .multi-md .product_build {
    font-size: 13px;
    margin: 10px 0
}

/* Syntax section parameter sets — UL emitted by the PlatyPS pre-pass.
 * Standard .topic li rules apply; only the label <p> needs a tweak. */
.topic .multi-md ul.syntax-sets > li > p {
    margin: 0 0 8px;
    font-weight: 600
}

/* Pandoc emits a stray empty <p> between the label and the code box (blank-line
 * boundary inside the raw <li>); collapse it so it adds no height. */
.topic .multi-md ul.syntax-sets > li > p:empty {
    display: none
}

/* Restore a 16px gap between the parameter-set label and its Rest_Box code box
 * (the label <p>'s 8px bottom margin alone left them glued). */
.topic .multi-md ul.syntax-sets > li table.Rest_Box {
    margin-top: 16px
}

/* Generalizes the fix above beyond PlatyPS syntax-sets: css.css's base
 * Code_Box/Rest_Box rule sets `margin:0`, so a code box glued to the content
 * above it has no gap. The renderer always wraps a code box as
 * `<div><table class="Rest_Box">`. Two real "glued" contexts:
 *   1. after a paragraph/subheading   →  <p>…</p><div><table.Rest_Box>
 *   2. inside a TIGHT list item        →  <li>item text<div><table.Rest_Box>
 * Case 2 has NO <p> (tight list) and the text is a bare text node, so neither
 * an adjacency rule on the table nor a `:not(:first-child)` guard on the div
 * works (the div is the first *element* child). Target the wrapper div in both
 * contexts directly. `:has` is supported in the preview webview (Chromium) and
 * modern browsers for the gen toc.html. A box that is a list item's sole
 * content gets a harmless small top gap — acceptable and rare. */
.topic .multi-md p + div:has(> table.Rest_Box),
.topic .multi-md li > div:has(> table.Rest_Box) {
    margin-top: 16px
}

/* Code-wrapped links (e.g. Related Commands) — keep the link colour. */
.topic .multi-md a > code {
    color: inherit
}

/* Code fence content — preserve column-aligned whitespace. Production css.css
 * has a class-keyed rule that doesn't fire on our simplified HTML; without
 * this, browsers collapse runs of spaces and example output (e.g. PowerShell
 * Get-Help tables) loses its column alignment. The gen pipeline injects the
 * same rule inline (md-html/filters.lua emitRestBox); this is the preview twin. */
.topic .multi-md p.Code_Example,
.topic .multi-md p.Code_Example > span.Code_Example {
    white-space: pre-wrap;
    word-break: break-word;
    tab-size: 4;
    -moz-tab-size: 4;
}

/* PowerShell syntax-highlighting classes — scoped to Rest_Box so they cannot
 * leak outside code fences. Consumes HC theme variables (light/dark) with
 * VS Code Light+ hex as fallbacks for the standalone preview. Used by the
 * preview (Phase 2) and gen (Phase 3). */

/* Veeam-style PS token palette (redesigned). Eight dedicated PS vars, tuned so
 * every token clears WCAG AA (>=4.5:1) against both the light (#fff) and dark
 * (#232323) code background. Cmdlets carry a cobalt blue AND font-weight 600 —
 * the conventional "command identifier" colour and the hero token a reader
 * scans for first; the weight is a non-colour cue so cmdlets stay distinct even
 * under red-green colour-vision deficiency. The keyword/word-operator token is
 * a desaturated slate: it reads as quiet/structural (keywords are secondary to
 * cmdlets in reference docs) and, being low-chroma, stays clear of both the
 * cobalt cmdlet and the purple variable in CVD simulation. Comments are italic
 * (second non-colour cue). Remaining tokens: variable purple, string rust,
 * number/constant teal, type magenta (kept split from keyword), comment grey.
 * These are DEDICATED PS vars (not css.css's generic --code-* vars) so the
 * palette tunes independently.
 * :root.theme--dark is toggled by the HC theme switcher (class on <html>). */
:root {
  --ps-cmdlet-color:  #0b59c2;  /* cobalt — hero token (command identifier) */
  --ps-string-color:  #b22d1f;  /* rust red (string) */
  --ps-var-color:     #8431a8;  /* purple ($var) */
  --ps-keyword-color: #4a5568;  /* slate (keywords + word-operators -eq/-like) */
  --ps-type-color:    #b01e6b;  /* magenta (split from keyword) */
  --ps-comment-color: #6e7781;  /* muted grey */
  --ps-number-color:  #0b6e75;  /* teal (numbers + constants $true/$false/$null) */
  --ps-param-color:   #9a5b00;  /* amber (-Parameter) */
  --code-lineno-color: #6e7781; /* editor gutter grey (light) */
}
:root.theme--dark {
  --ps-cmdlet-color:  #5ba2f5;  /* cobalt — hero token on dark */
  --ps-string-color:  #e08f73;  /* warm rust (string) */
  --ps-var-color:     #c690e8;  /* light purple */
  --ps-keyword-color: #9aa5b8;  /* slate (keywords + word-operators) */
  --ps-type-color:    #ee84bf;  /* light magenta (split from keyword) */
  --ps-comment-color: #8b9499;  /* muted grey */
  --ps-number-color:  #5ac8c8;  /* teal */
  --ps-param-color:   #e0a85a;  /* amber (-Parameter) */
  --code-lineno-color: #8b9499; /* editor gutter grey (dark) */
}

.Rest_Box .ps-cmdlet { color: var(--ps-cmdlet-color, #0b59c2); font-weight: 600; }
.Rest_Box .ps-var    { color: var(--ps-var-color, #8431a8); }
.Rest_Box .ps-str    { color: var(--ps-string-color, #b22d1f); }
.Rest_Box .ps-com    { color: var(--ps-comment-color, #6e7781); font-style: italic; }
.Rest_Box .ps-kw     { color: var(--ps-keyword-color, #4a5568); }
.Rest_Box .ps-type   { color: var(--ps-type-color, #b01e6b); }
.Rest_Box .ps-num    { color: var(--ps-number-color, #0b6e75); }
.Rest_Box .ps-param  { color: var(--ps-param-color, #9a5b00); }
/* ps-op intentionally inherits the code-box text color (var --code-text-color) */

/* Line numbers for highlighted (PlatyPS) example code boxes, styled like the
 * VS Code editor gutter: crisp muted-grey numbers, right-aligned in a fixed
 * gutter with a comfortable gap to the code. Pure CSS counter via ::before so
 * numbers are never part of the text selection / copy-paste. The number is
 * absolute-positioned so wrapped long lines stay aligned under the code. */
.Rest_Box.Code_Numbered { counter-reset: codeline; }
.Rest_Box.Code_Numbered p.Code_Example {
    counter-increment: codeline;
    position: relative;
    padding-left: 2.9ch;
}
.Rest_Box.Code_Numbered p.Code_Example::before {
    content: counter(codeline);
    position: absolute;
    left: 0;
    /*width: 2.5ch;*/
    /*text-align: right;*/
    color: var(--code-lineno-color, #6e7681);
    user-select: none;
    -webkit-user-select: none;
}

/* Print rules — copied from .release-notes @media print block. */
@media print {
    .topic .multi-md { padding-bottom: 0 !important; margin-bottom: 0 !important }
    .topic .multi-md p.Subheading,
    .topic .multi-md p.Subheading_L2 { padding-top: 16px !important }
    .multi-md .T_ImportantType,
    .multi-md .T_NoteType,
    .multi-md .T_TipType { page-break-after: avoid !important }
    .topic .multi-md ol + p, .topic .multi-md ul + p { margin-top: auto !important }
    .topic .multi-md li { margin-left: 16px; padding-left: 10px }
    .topic .multi-md ul li::before { content: none !important }
    .topic .multi-md ul li { list-style-type: disc }
    .topic .multi-md ol ul li, .topic .multi-md ul ul li {
        list-style-type: circle !important
    }
}

/* ------------------------------------------------------------------ */
/* Cmdlet-synopsis hover tooltip (production / gen output).            */
/* gen build.py wraps same-folder cmdlet cross-links as               */
/*   <span class="tooltip js-tooltip-container hm-cmdlet-tip">         */
/*     <a href="X.html">X</a>                                          */
/*     <span class="tooltip__text" role="tooltip">SYNOPSIS</span>      */
/*   </span>                                                           */
/* The live HC bundle already styles .tooltip/.tooltip__text for the   */
/* CLICK (.tooltip--active) inline-toggle. Here we add HOVER reveal +  */
/* right-of-link positioning, scoped to .hm-cmdlet-tip so the global   */
/* inline-toggle tooltips are untouched. Self-contained so it works    */
/* regardless of merge order into css.css. The link keeps its own      */
/* styling and click-to-navigate.                                      */
/* ------------------------------------------------------------------ */
.hm-cmdlet-tip { display: inline-block; position: relative; }
.hm-cmdlet-tip .tooltip__text {
    visibility: hidden;
    position: absolute;
    /* To the right of the link's last char, vertically centered. */
    top: 50%;
    left: 100%;
    transform: translateY(-50%);
    margin-left: 8px;
    /* width:max-content shrinks the box to the text's natural width (no empty
       space for short synopses); max-width caps long ones, then they wrap. */
    width: max-content;
    max-width: 240px;
    padding: 6px 9px;
    border-radius: 4px;
    background: var(--main-bg, #fff);
    color: var(--main-text, inherit);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(128, 128, 128, 0.3);
    font-size: 13px;
    line-height: 1.4;
    white-space: normal;
    opacity: 0;
    transition: opacity .15s, visibility .15s;
    z-index: 99;
}
.hm-cmdlet-tip:hover .tooltip__text,
.hm-cmdlet-tip:focus-within .tooltip__text {
    visibility: visible;
    opacity: 1;
}

/* Blue_Table regulating width */
.topic table.Blue_Table td {
    word-break: break-word;
}