/* Help center (support/templates/support/help/*): hub, guide cover, chapter pages, search, print booklet,
   and the figure mock-ups (support/help/figures/*.html). Logical properties throughout, so RTL needs no overrides.
   Sits on the dashboard theme tokens (--dp-*, core/css/dp-shell.css); the print page defines its own fallbacks. */

.gd-root {
    --gd-radius: var(--dp-radius, 1rem);
    --gd-radius-sm: var(--dp-radius-sm, .65rem);
    --gd-surface: var(--dp-surface, var(--bs-body-bg));
    --gd-border: var(--dp-border, var(--bs-border-color));
    --gd-soft: var(--dp-soft, color-mix(in srgb, var(--bs-emphasis-color) 4%, var(--bs-body-bg)));
    --gd-text: var(--dp-text, var(--bs-emphasis-color));
    --gd-muted: var(--dp-muted, var(--bs-secondary-color));
    --gd-accent: var(--bs-primary);
    --gd-accent-rgb: var(--bs-primary-rgb);
    --gd-shadow: var(--dp-shadow-sm, 0 1px 2px rgba(15, 23, 42, .05));
    --gd-top: var(--dp-top, 5.25rem);
    container-type: inline-size;
    container-name: gd;
    min-width: 0;
}
.gd-root .tone-warning { --gd-tone: #f59e0b; --gd-tone-rgb: 245, 158, 11; }
.gd-root .tone-success { --gd-tone: #10b981; --gd-tone-rgb: 16, 185, 129; }
.gd-root .tone-primary { --gd-tone: var(--bs-primary); --gd-tone-rgb: var(--bs-primary-rgb); }
.gd-root .tone-info { --gd-tone: #0ea5e9; --gd-tone-rgb: 14, 165, 233; }
.gd-root .tone-purple { --gd-tone: #6250d6; --gd-tone-rgb: 98, 80, 214; }

/* ---------- shared bits ---------- */
.gd-section-title { font-size: 1rem; font-weight: 700; color: var(--gd-text); margin: 1.75rem 0 .75rem; }
.gd-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; font-size: .85rem; margin-bottom: 1rem; color: var(--gd-muted); }
.gd-crumbs a { color: var(--gd-muted); text-decoration: none; }
.gd-crumbs a:hover { color: var(--gd-accent); }
.gd-crumbs [aria-current] { color: var(--gd-text); font-weight: 600; }
.gd-crumb-sep { font-size: .7rem; opacity: .6; }

.gd-search { position: relative; display: flex; gap: .5rem; align-items: center; margin: 0 0 1rem; }
.gd-search > .bi-search { position: absolute; inset-inline-start: .9rem; color: var(--gd-muted); pointer-events: none; }
.gd-search .form-control { padding-inline-start: 2.4rem; border-radius: 999px; min-height: 2.6rem; }
.gd-search .btn { border-radius: 999px; margin: 0; white-space: nowrap; }
.gd-search.is-large .form-control { min-height: 3.1rem; font-size: 1rem; box-shadow: var(--gd-shadow); }
.gd-search.is-large .btn { min-height: 3.1rem; padding-inline: 1.4rem; }

.gd-langs { display: inline-flex; flex-wrap: wrap; align-items: center; gap: .3rem; font-size: .8rem; color: var(--gd-muted); }
.gd-lang { padding: .1rem .55rem; border-radius: 999px; border: 1px solid var(--gd-border); text-decoration: none; color: var(--gd-text); background: var(--gd-surface); }
.gd-lang:hover { border-color: var(--gd-accent); color: var(--gd-accent); }
.gd-lang.is-current { background: rgba(var(--gd-accent-rgb), .1); border-color: transparent; color: var(--gd-accent); font-weight: 600; }

.gd-more { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; margin-top: 2rem;
    padding: 1.1rem 1.25rem; border: 1px dashed var(--gd-border); border-radius: var(--gd-radius); background: var(--gd-surface); }
.gd-more-text { display: flex; flex-direction: column; gap: .15rem; }
.gd-more-text span { color: var(--gd-muted); font-size: .9rem; }
.gd-more-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.gd-more-actions .btn i, .gd-cover-actions .btn i, .gd-guide-actions .btn i, .gd-article-tools .btn i { margin-inline-end: .3rem; }
.gd-coming { color: var(--gd-muted); font-size: .9rem; margin-top: 1rem; }
.gd-fallback { display: flex; gap: .6rem; align-items: flex-start; border-radius: var(--gd-radius-sm); }

/* ---------- hub ---------- */
.gd-hero { text-align: center; padding: 2rem 1.25rem 1.25rem; margin-bottom: .5rem; border-radius: var(--gd-radius);
    background: radial-gradient(120% 140% at 50% 0%, rgba(var(--gd-accent-rgb), .12), transparent 60%), var(--gd-surface);
    border: 1px solid var(--gd-border); box-shadow: var(--gd-shadow); }
.gd-hero-icon { display: inline-grid; place-items: center; width: 3.25rem; height: 3.25rem; border-radius: 1rem; font-size: 1.6rem;
    color: var(--gd-accent); background: rgba(var(--gd-accent-rgb), .12); margin-bottom: .75rem; }
.gd-hero-title { font-size: 1.6rem; font-weight: 800; margin-bottom: .35rem; }
.gd-hero-sub { color: var(--gd-muted); margin: 0 auto 1.25rem; max-width: 36rem; }
.gd-hero .gd-search { max-width: 40rem; margin-inline: auto; }

.gd-guides { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); }
.gd-guide-card { display: flex; flex-direction: column; border: 1px solid var(--gd-border); border-radius: var(--gd-radius);
    background: var(--gd-surface); box-shadow: var(--gd-shadow); overflow: hidden; border-top: 4px solid var(--gd-tone); }
.gd-guide-card-main { display: flex; gap: .9rem; padding: 1.1rem 1.1rem .5rem; text-decoration: none; color: inherit; }
.gd-guide-icon, .gd-cover-icon { flex: none; display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: .9rem;
    font-size: 1.45rem; color: var(--gd-tone); background: rgba(var(--gd-tone-rgb), .14); }
.gd-guide-text { display: flex; flex-direction: column; gap: .25rem; min-width: 0; }
.gd-guide-title { font-weight: 700; font-size: 1.08rem; color: var(--gd-text); }
.gd-guide-card-main:hover .gd-guide-title { color: var(--gd-accent); }
.gd-guide-sub { color: var(--gd-muted); font-size: .9rem; }
.gd-guide-meta, .gd-cover-meta { display: flex; flex-wrap: wrap; gap: .4rem 1rem; font-size: .8rem; color: var(--gd-muted); margin-top: .2rem; }
.gd-guide-meta i, .gd-cover-meta > span > i { margin-inline-end: .25rem; }
.gd-guide-chapters { margin: .25rem 0 .75rem; padding-inline: 1.1rem 1.1rem; padding-inline-start: 2.6rem; font-size: .88rem; flex: 1; }
.gd-guide-chapters li { padding: .15rem 0; }
.gd-guide-chapters a { color: var(--gd-text); text-decoration: none; }
.gd-guide-chapters a:hover { color: var(--gd-accent); text-decoration: underline; }
.gd-guide-chapters-more { list-style: none; }
.gd-guide-chapters-more a { color: var(--gd-accent); }
.gd-guide-foot { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; justify-content: space-between;
    padding: .75rem 1.1rem; border-top: 1px solid var(--gd-border); background: var(--gd-soft); }
.gd-guide-actions { display: flex; gap: .4rem; margin-inline-start: auto; }

/* ---------- guide cover ---------- */
.gd-cover { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 1rem 1.1rem; padding: 1.4rem;
    border: 1px solid var(--gd-border); border-radius: var(--gd-radius); background: var(--gd-surface); box-shadow: var(--gd-shadow);
    border-inline-start: 5px solid var(--gd-tone); margin-bottom: 1rem; }
.gd-cover-icon { width: 3.6rem; height: 3.6rem; font-size: 1.8rem; }
.gd-cover-title { font-size: 1.5rem; font-weight: 800; margin-bottom: .25rem; }
.gd-cover-sub { color: var(--gd-muted); margin-bottom: .5rem; }
.gd-cover-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: .5rem; }

.gd-chapter-cards { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; }
.gd-chapter-card { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: .9rem; align-items: start; padding: .9rem 1rem;
    border: 1px solid var(--gd-border); border-radius: var(--gd-radius-sm); background: var(--gd-surface); text-decoration: none; color: inherit;
    transition: border-color .15s, box-shadow .15s; }
.gd-chapter-card:hover { border-color: rgba(var(--gd-accent-rgb), .45); box-shadow: var(--gd-shadow); }
.gd-chapter-num { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; font-weight: 700; font-size: .9rem;
    background: rgba(var(--gd-accent-rgb), .1); color: var(--gd-accent); }
.gd-chapter-body { display: flex; flex-direction: column; gap: .2rem; min-width: 0; }
.gd-chapter-title { font-weight: 700; color: var(--gd-text); }
.gd-chapter-title i { color: var(--gd-muted); margin-inline-end: .2rem; }
.gd-chapter-sub { color: var(--gd-muted); font-size: .88rem; }
.gd-chapter-topics { display: flex; flex-wrap: wrap; gap: .3rem; margin-top: .3rem; }
.gd-chapter-topics span { font-size: .74rem; padding: .05rem .5rem; border-radius: 999px; background: var(--gd-soft); color: var(--gd-muted); border: 1px solid var(--gd-border); }
.gd-chapter-min { font-size: .78rem; color: var(--gd-muted); white-space: nowrap; }

/* ---------- chapter page ---------- */
.gd-layout { display: grid; gap: 1.25rem; grid-template-columns: minmax(0, 1fr); align-items: start; }
.gd-nav-box, .gd-toc-box { border: 1px solid var(--gd-border); border-radius: var(--gd-radius); background: var(--gd-surface); box-shadow: var(--gd-shadow); }
.gd-nav-head { display: flex; flex-direction: column; gap: .1rem; padding: .85rem 1rem; cursor: pointer; list-style: none; border-bottom: 1px solid var(--gd-border); }
.gd-nav-head::-webkit-details-marker { display: none; }
.gd-nav-guide { font-weight: 700; color: var(--gd-text); }
.gd-nav-guide i { color: var(--gd-accent); margin-inline-end: .25rem; }
.gd-nav-count { font-size: .78rem; color: var(--gd-muted); }
.gd-nav-list { list-style: none; margin: 0; padding: .4rem; }
.gd-nav-list a { display: flex; gap: .55rem; align-items: baseline; padding: .42rem .6rem; border-radius: .55rem; font-size: .88rem;
    color: var(--gd-text); text-decoration: none; line-height: 1.35; }
.gd-nav-list a:hover { background: var(--gd-soft); }
.gd-nav-list a.is-current { background: rgba(var(--gd-accent-rgb), .1); color: var(--gd-accent); font-weight: 600; }
.gd-nav-num { flex: none; min-width: 1.3rem; font-size: .75rem; color: var(--gd-muted); font-variant-numeric: tabular-nums; }
.gd-nav-list a.is-current .gd-nav-num { color: inherit; }
.gd-nav-tools { padding: .5rem 1rem .8rem; border-top: 1px solid var(--gd-border); font-size: .82rem; }
.gd-nav-tools a { color: var(--gd-muted); text-decoration: none; }
.gd-nav-tools a:hover { color: var(--gd-accent); }

.gd-article { min-width: 0; padding: 1.5rem clamp(1rem, 3cqi, 2.25rem) 1.25rem; border: 1px solid var(--gd-border);
    border-radius: var(--gd-radius); background: var(--gd-surface); box-shadow: var(--gd-shadow); }
.gd-article-kicker { display: block; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--gd-muted); margin-bottom: .3rem; }
.gd-article-title { font-size: clamp(1.35rem, 3.2cqi, 1.75rem); font-weight: 800; color: var(--gd-text); margin-bottom: .4rem; }
.gd-article-title i { color: var(--gd-accent); margin-inline-end: .25rem; }
.gd-article-lead { font-size: 1.05rem; color: var(--gd-muted); margin-bottom: .75rem; }
.gd-article-tools { display: flex; flex-wrap: wrap; gap: .6rem 1rem; align-items: center; padding-bottom: 1rem; margin-bottom: 1.25rem; border-bottom: 1px solid var(--gd-border); }

.gd-toc-inline { margin-bottom: 1.25rem; border: 1px solid var(--gd-border); border-radius: var(--gd-radius-sm); background: var(--gd-soft); }
.gd-toc-inline summary { padding: .6rem .9rem; cursor: pointer; font-weight: 600; font-size: .9rem; }
.gd-toc-inline ul, .gd-toc-box ul { list-style: none; margin: 0; padding: 0 .9rem .7rem; font-size: .86rem; }
.gd-toc-inline li, .gd-toc-box li { padding: .18rem 0; }
.gd-toc-inline li.lvl-3, .gd-toc-box li.lvl-3 { padding-inline-start: .9rem; font-size: .82rem; }
.gd-toc-inline a, .gd-toc-box a { color: var(--gd-muted); text-decoration: none; }
.gd-toc-inline a:hover, .gd-toc-box a:hover, .gd-toc-box a.is-active { color: var(--gd-accent); }
.gd-toc-box a.is-active { font-weight: 600; }
.gd-toc { display: none; }
.gd-toc-box { padding-top: .8rem; }
.gd-toc-head { display: block; padding: 0 .9rem .5rem; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--gd-muted); }
.gd-toc-top { display: block; padding: .6rem .9rem; border-top: 1px solid var(--gd-border); font-size: .8rem; color: var(--gd-muted); text-decoration: none; }

.gd-pager { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; margin-top: 2rem; padding-top: 1.25rem; border-top: 1px solid var(--gd-border); }
.gd-pager-link { display: flex; flex-direction: column; gap: .2rem; padding: .8rem 1rem; border: 1px solid var(--gd-border); border-radius: var(--gd-radius-sm);
    text-decoration: none; color: inherit; }
.gd-pager-link:hover { border-color: var(--gd-accent); }
.gd-pager-link.is-next { text-align: end; grid-column: 2; }
.gd-pager-label { font-size: .78rem; color: var(--gd-muted); }
.gd-pager-title { font-weight: 600; color: var(--gd-accent); }

/* two columns (chapters | text) once the content column is wide; a third ("on this page") on very wide screens */
@container gd (min-width: 860px) {
    .gd-layout { grid-template-columns: 15rem minmax(0, 1fr); }
    .gd-nav { position: sticky; top: var(--gd-top); max-height: calc(100vh - var(--gd-top) - 1rem); overflow: auto; }
    .gd-nav-head { cursor: default; pointer-events: none; }
}
@container gd (min-width: 1180px) {
    .gd-layout { grid-template-columns: 14rem minmax(0, 1fr) 12.5rem; }
    .gd-toc { display: block; position: sticky; top: var(--gd-top); max-height: calc(100vh - var(--gd-top) - 1rem); overflow: auto; }
    .gd-toc-inline { display: none; }
}

/* ---------- prose ---------- */
.gd-prose { font-size: 1rem; line-height: 1.85; color: var(--bs-body-color); overflow-wrap: anywhere; }
[dir="rtl"] .gd-prose, .gd-prose:lang(fa) { line-height: 2; }
.gd-prose > :first-child { margin-top: 0; }
.gd-prose h2 { font-size: 1.32rem; font-weight: 800; color: var(--gd-text); margin: 2.4rem 0 .8rem; padding-top: .4rem; scroll-margin-top: calc(var(--gd-top) + .5rem); }
.gd-prose h2::before { content: ""; display: block; width: 2.25rem; height: 3px; border-radius: 3px; background: var(--gd-accent); margin-bottom: .6rem; }
.gd-prose h3 { font-size: 1.08rem; font-weight: 700; color: var(--gd-text); margin: 1.8rem 0 .6rem; scroll-margin-top: calc(var(--gd-top) + .5rem); }
.gd-prose h4 { font-size: .98rem; font-weight: 700; margin: 1.3rem 0 .5rem; }
.gd-prose p, .gd-prose ul, .gd-prose ol, .gd-prose dl { margin-bottom: 1rem; }
.gd-prose ul, .gd-prose ol { padding-inline-start: 1.5rem; }
.gd-prose li { margin-bottom: .35rem; }
.gd-prose li > ul, .gd-prose li > ol { margin: .35rem 0 0; }
.gd-prose a { color: var(--gd-accent); text-underline-offset: .2em; }
.gd-prose strong { color: var(--gd-text); }
.gd-prose code { font-size: .86em; padding: .1em .35em; border-radius: .35rem; background: var(--gd-soft); border: 1px solid var(--gd-border); color: var(--gd-text); direction: ltr; unicode-bidi: isolate; }
.gd-prose hr { margin: 2rem 0; opacity: .15; }
.gd-prose dt { font-weight: 700; color: var(--gd-text); }
.gd-prose dd { margin: 0 0 .75rem; padding-inline-start: 1rem; border-inline-start: 2px solid var(--gd-border); }
.gd-prose blockquote { margin: 0 0 1rem; padding: .6rem 1rem; border-inline-start: 3px solid var(--gd-border); color: var(--gd-muted); }

/* numbered steps: an ordered list whose items start with a bold verb ("1. **Open** …") reads like a procedure */
.gd-prose ol { counter-reset: gd-step; list-style: none; padding-inline-start: 0; }
.gd-prose ol > li { counter-increment: gd-step; position: relative; padding-inline-start: 2.3rem; min-height: 1.7rem; }
.gd-prose ol > li::before { content: counter(gd-step); position: absolute; inset-inline-start: 0; top: .15rem; display: grid; place-items: center;
    width: 1.6rem; height: 1.6rem; border-radius: 50%; font-size: .8rem; font-weight: 700; color: var(--gd-accent); background: rgba(var(--gd-accent-rgb), .12); line-height: 1; }

/* a dashboard label inside the text ({{ui:...}}) */
.gd-ui { display: inline-block; padding: 0 .45em; border-radius: .4rem; font-size: .92em; font-weight: 600; line-height: 1.6;
    color: var(--gd-text); background: var(--gd-soft); border: 1px solid var(--gd-border); box-shadow: 0 1px 0 var(--gd-border); white-space: nowrap; }
@media (max-width: 575.98px) { .gd-ui { white-space: normal; } }

/* tables scroll inside their own box */
.gd-table { overflow-x: auto; margin: 0 0 1.25rem; border: 1px solid var(--gd-border); border-radius: var(--gd-radius-sm); }
.gd-prose table { width: 100%; border-collapse: collapse; font-size: .92rem; line-height: 1.6; }
.gd-prose th, .gd-prose td { padding: .6rem .8rem; border-bottom: 1px solid var(--gd-border); text-align: start; vertical-align: top; }
.gd-prose th { background: var(--gd-soft); font-weight: 700; color: var(--gd-text); white-space: nowrap; }
.gd-prose tr:last-child td { border-bottom: 0; }
.gd-prose td:first-child { font-weight: 600; color: var(--gd-text); }

/* call-outs (!!! tip / note / warning / danger / example) */
.gd-prose .admonition { --gd-c: var(--gd-accent); --gd-c-rgb: var(--gd-accent-rgb); margin: 0 0 1.25rem; padding: .8rem 1rem .8rem 1rem;
    border-radius: var(--gd-radius-sm); border: 1px solid rgba(var(--gd-c-rgb), .3); border-inline-start: 4px solid var(--gd-c); background: rgba(var(--gd-c-rgb), .06); }
.gd-prose .admonition > :last-child { margin-bottom: 0; }
.gd-prose .admonition-title { font-weight: 700; color: var(--gd-c); margin-bottom: .3rem; }
.gd-prose .admonition-title::before { font-family: "bootstrap-icons"; margin-inline-end: .4rem; vertical-align: -.1em; content: "\f431"; }
.gd-prose .admonition.tip { --gd-c: #059669; --gd-c-rgb: 5, 150, 105; }
.gd-prose .admonition.tip > .admonition-title::before { content: "\f46b"; } /* lightbulb */
.gd-prose .admonition.warning { --gd-c: #d97706; --gd-c-rgb: 217, 119, 6; }
.gd-prose .admonition.warning > .admonition-title::before { content: "\f33a"; } /* exclamation-triangle */
.gd-prose .admonition.danger { --gd-c: #dc2626; --gd-c-rgb: 220, 38, 38; }
.gd-prose .admonition.danger > .admonition-title::before { content: "\f333"; } /* exclamation-octagon */
.gd-prose .admonition.example { --gd-c: #7c3aed; --gd-c-rgb: 124, 58, 237; }
.gd-prose .admonition.example > .admonition-title::before { content: "\f4ca"; } /* play */

/* ---------- search results ---------- */
.gd-results-count { color: var(--gd-muted); font-size: .9rem; }
.gd-results { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; }
.gd-result { display: flex; flex-direction: column; gap: .2rem; padding: .9rem 1.1rem; border: 1px solid var(--gd-border); border-radius: var(--gd-radius-sm);
    background: var(--gd-surface); text-decoration: none; color: inherit; }
.gd-result:hover { border-color: var(--gd-accent); }
.gd-result-path { font-size: .78rem; color: var(--gd-muted); }
.gd-result-title { font-weight: 700; color: var(--gd-accent); }
.gd-result-snippet { font-size: .9rem; color: var(--bs-body-color); }
.gd-empty { text-align: center; padding: 2.5rem 1rem; color: var(--gd-muted); border: 1px dashed var(--gd-border); border-radius: var(--gd-radius); background: var(--gd-surface); }
.gd-empty > i { font-size: 2rem; display: block; margin-bottom: .5rem; }

/* =====================================================================================================
   Figures: mock-ups of dashboard parts (support/help/figures/*.html). Pins (①②…) point at parts the
   text explains; the legend under the picture repeats them in words.
   ===================================================================================================== */
.gd-fig { margin: 1.5rem 0 1.75rem; padding: 1.1rem; border-radius: var(--gd-radius); border: 1px solid var(--gd-border);
    background: repeating-linear-gradient(135deg, transparent 0 12px, rgba(var(--gd-accent-rgb), .025) 12px 24px), var(--gd-soft); line-height: 1.5; }
.gd-fig-stage { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; align-items: flex-start; }
.gd-fig figcaption { margin-top: .9rem; font-size: .84rem; color: var(--gd-muted); text-align: center; }
.gd-fig figcaption strong { color: var(--gd-text); }
.gd-fig-legend { list-style: none; margin: .9rem 0 0; padding: 0; display: grid; gap: .35rem .9rem; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); font-size: .84rem; }
.gd-fig-legend li { display: flex; gap: .45rem; align-items: baseline; margin: 0; padding: 0 !important; min-height: 0 !important; }
.gd-fig-legend li::before { content: none !important; }
.gd-pin { flex: none; display: inline-grid; place-items: center; width: 1.35rem; height: 1.35rem; border-radius: 50%; font-size: .72rem; font-weight: 800;
    color: #fff; background: #e11d48; box-shadow: 0 0 0 2px #fff, 0 2px 6px rgba(225, 29, 72, .4); line-height: 1; font-style: normal; }
.gd-mock .gd-pin { position: absolute; inset-inline-end: -.55rem; top: 50%; transform: translateY(-50%); z-index: 2; }

/* a generic dashboard "window" */
.gd-mock { position: relative; background: var(--gd-surface); border: 1px solid var(--gd-border); border-radius: .8rem;
    box-shadow: 0 10px 30px -14px rgba(15, 23, 42, .3); font-size: .82rem; color: var(--bs-body-color); min-width: 0; }
.gd-mock-bar { display: flex; align-items: center; gap: .35rem; padding: .45rem .7rem; border-bottom: 1px solid var(--gd-border); background: var(--gd-soft);
    border-radius: .8rem .8rem 0 0; font-size: .74rem; color: var(--gd-muted); }
.gd-mock-bar::before { content: ""; width: .5rem; height: .5rem; border-radius: 50%; background: #f87171; box-shadow: .8rem 0 0 #fbbf24, 1.6rem 0 0 #34d399; margin-inline-end: 2rem; }
.gd-mock-body { padding: .75rem; }
.gd-mock-row { position: relative; display: flex; align-items: center; gap: .5rem; padding: .42rem .6rem; border-radius: .5rem; }
.gd-mock-row > i { width: 1.1rem; text-align: center; color: var(--gd-muted); }
.gd-mock-row.is-head { font-weight: 700; color: var(--gd-text); background: rgba(var(--gd-accent-rgb), .08); }
.gd-mock-row.is-head > i { color: var(--gd-accent); }
.gd-mock-row.is-active { background: rgba(var(--gd-accent-rgb), .12); color: var(--gd-accent); font-weight: 600; }
.gd-mock-row.is-sub { padding-inline-start: 1.6rem; }
.gd-mock-dot { width: .5rem; height: .5rem; border-radius: 50%; background: #10b981; margin-inline-start: auto; }
.gd-mock-title { font-weight: 800; font-size: .95rem; color: var(--gd-text); }
.gd-mock-sub { color: var(--gd-muted); font-size: .76rem; }
.gd-mock-btn { position: relative; display: inline-flex; align-items: center; gap: .3rem; padding: .3rem .65rem; border-radius: .45rem; font-size: .76rem; font-weight: 600;
    border: 1px solid var(--gd-border); background: var(--gd-surface); color: var(--gd-text); white-space: nowrap; }
.gd-mock-btn.is-primary { background: var(--gd-accent); border-color: var(--gd-accent); color: #fff; }
.gd-mock-btn.is-danger { color: #dc2626; border-color: rgba(220, 38, 38, .35); }
.gd-mock-btn .gd-pin { position: absolute; top: -.6rem; inset-inline-end: -.6rem; transform: none; }
.gd-mock-chips { display: flex; flex-wrap: wrap; gap: .35rem; }
.gd-chip { position: relative; display: inline-flex; align-items: center; gap: .3rem; padding: .22rem .65rem; border-radius: 999px; font-size: .74rem; font-weight: 600;
    border: 1px solid var(--gd-border); background: var(--gd-surface); color: var(--gd-text); white-space: nowrap; }
.gd-chip b { font-weight: 700; padding: 0 .35rem; border-radius: 999px; background: var(--gd-soft); font-size: .7rem; }
.gd-chip.is-on { background: var(--gd-text); color: var(--gd-surface); border-color: transparent; }
.gd-chip.is-on b { background: rgba(255, 255, 255, .2); }
.gd-chip .gd-pin { position: absolute; top: -.65rem; inset-inline-end: -.5rem; transform: none; }
.gd-field { position: relative; display: flex; flex-direction: column; gap: .2rem; min-width: 7rem; flex: 1; }
.gd-field > span { font-size: .7rem; color: var(--gd-muted); font-weight: 600; }
.gd-field > div { padding: .3rem .55rem; border: 1px solid var(--gd-border); border-radius: .45rem; background: var(--gd-surface); color: var(--gd-muted); font-size: .76rem; min-height: 1.8rem; }
.gd-field .gd-pin { position: absolute; top: -.55rem; inset-inline-end: -.4rem; transform: none; }
.gd-switch { position: relative; display: inline-block; width: 1.9rem; height: 1.05rem; border-radius: 999px; background: #cbd5e1; flex: none; }
.gd-switch::after { content: ""; position: absolute; top: .15rem; inset-inline-start: .15rem; width: .75rem; height: .75rem; border-radius: 50%; background: #fff; }
.gd-switch.is-on { background: var(--gd-accent); }
.gd-switch.is-on::after { inset-inline-start: auto; inset-inline-end: .15rem; }
.gd-badge { display: inline-flex; align-items: center; gap: .25rem; padding: .1rem .5rem; border-radius: 999px; font-size: .7rem; font-weight: 700; white-space: nowrap; }
.gd-badge.t-warning { background: rgba(245, 158, 11, .16); color: #b45309; }
.gd-badge.t-info { background: rgba(14, 165, 233, .15); color: #0369a1; }
.gd-badge.t-primary { background: rgba(var(--gd-accent-rgb), .14); color: var(--gd-accent); }
.gd-badge.t-purple { background: rgba(124, 58, 237, .14); color: #6d28d9; }
.gd-badge.t-success { background: rgba(16, 185, 129, .16); color: #047857; }
.gd-badge.t-danger { background: rgba(220, 38, 38, .13); color: #b91c1c; }
.gd-badge.t-muted { background: var(--gd-soft); color: var(--gd-muted); border: 1px solid var(--gd-border); }

/* flows: a row of steps with arrows (wraps on phones) */
.gd-flow { display: flex; flex-wrap: wrap; align-items: stretch; justify-content: center; gap: .5rem; }
.gd-flow-step { position: relative; display: flex; flex-direction: column; align-items: center; gap: .3rem; padding: .7rem .8rem; min-width: 7.5rem; max-width: 10rem; flex: 1 1 7.5rem;
    text-align: center; border-radius: .8rem; background: var(--gd-surface); border: 1px solid var(--gd-border); box-shadow: var(--gd-shadow); }
.gd-flow-step > i { font-size: 1.25rem; }
.gd-flow-step small { color: var(--gd-muted); font-size: .72rem; line-height: 1.35; }
.gd-flow-arrow { align-self: center; color: var(--gd-muted); font-size: 1.1rem; }
/* the dashboard's rtl.css already mirrors .bi-arrow-right::before; the print page has no rtl.css */
@container gd (max-width: 560px) { .gd-flow { flex-direction: column; align-items: stretch; } .gd-flow-step { max-width: none; } .gd-flow-arrow { display: none; } }
.gd-flow-branch { flex-basis: 100%; display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; padding-top: .6rem; margin-top: .2rem; border-top: 1px dashed var(--gd-border); }
.gd-flow-branch-label { flex-basis: 100%; text-align: center; font-size: .74rem; color: var(--gd-muted); }

/* a sum: stacked lines with + / − / = */
.gd-sum { width: min(100%, 24rem); }
.gd-sum-line { display: flex; justify-content: space-between; gap: 1rem; padding: .38rem .2rem; border-bottom: 1px dashed var(--gd-border); }
.gd-sum-line > span:first-child { display: flex; gap: .4rem; align-items: center; }
.gd-sum-op { display: inline-grid; place-items: center; width: 1.2rem; height: 1.2rem; border-radius: 50%; font-weight: 800; font-size: .8rem; background: var(--gd-soft); }
.gd-sum-op.is-minus { color: #059669; }
.gd-sum-op.is-plus { color: #b45309; }
.gd-sum-line.is-total { border-bottom: 0; border-top: 2px solid var(--gd-text); font-weight: 800; color: var(--gd-text); margin-top: .2rem; }

/* a day timeline (time slots / reminders) */
.gd-timeline { position: relative; width: 100%; }
.gd-tl-track { position: relative; height: 3.2rem; border-radius: .6rem; background: var(--gd-surface); border: 1px solid var(--gd-border); overflow: hidden; }
.gd-tl-block { position: absolute; top: .45rem; bottom: .45rem; border-radius: .45rem; display: flex; align-items: center; justify-content: center; font-size: .68rem; font-weight: 700; overflow: hidden; white-space: nowrap; padding: 0 .3rem; }
.gd-tl-block.is-open { background: rgba(16, 185, 129, .16); color: #047857; border: 1px solid rgba(16, 185, 129, .4); }
.gd-tl-block.is-booked { background: rgba(var(--gd-accent-rgb), .18); color: var(--gd-accent); border: 1px solid rgba(var(--gd-accent-rgb), .4); }
.gd-tl-block.is-buffer { background: repeating-linear-gradient(45deg, rgba(100, 116, 139, .18) 0 4px, transparent 4px 8px); color: var(--gd-muted); }
.gd-tl-block.is-blocked { background: repeating-linear-gradient(45deg, rgba(220, 38, 38, .2) 0 5px, rgba(220, 38, 38, .08) 5px 10px); color: #b91c1c; border: 1px solid rgba(220, 38, 38, .35); }
.gd-tl-block.is-off { background: var(--gd-soft); color: var(--gd-muted); }
.gd-tl-scale { position: relative; height: 1.2rem; font-size: .66rem; color: var(--gd-muted); }
.gd-tl-scale span { position: absolute; translate: var(--gd-half); }
.gd-tl-legend { display: flex; flex-wrap: wrap; gap: .35rem 1rem; justify-content: center; margin-top: .6rem; font-size: .74rem; color: var(--gd-muted); }
.gd-tl-legend span { display: inline-flex; gap: .3rem; align-items: center; }
.gd-tl-legend i { display: inline-block; width: .85rem; height: .6rem; border-radius: .2rem; }

/* settings shell mock (left: sections, right: one section) */
.gd-shell { display: grid; grid-template-columns: minmax(9rem, 13rem) minmax(0, 1fr); width: min(100%, 44rem); }
.gd-shell-nav { padding: .6rem; border-inline-end: 1px solid var(--gd-border); background: var(--gd-soft); border-end-start-radius: .8rem; }
.gd-shell-group { font-size: .66rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--gd-muted); padding: .55rem .5rem .25rem; }
.gd-shell-pane { padding: .8rem; display: flex; flex-direction: column; gap: .55rem; }
.gd-set-row { position: relative; display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding: .5rem .6rem; border: 1px solid var(--gd-border); border-radius: .55rem; }
.gd-set-row > span { display: flex; flex-direction: column; }
.gd-set-row small { color: var(--gd-muted); font-size: .7rem; }
.gd-savebar { position: relative; display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .5rem .7rem; border-radius: .6rem; background: var(--gd-text); color: var(--gd-surface); font-size: .76rem; font-weight: 600; }
.gd-savebar .gd-mock-btn { border-color: transparent; }
@container gd (max-width: 560px) {
    .gd-shell { grid-template-columns: minmax(0, 1fr); }
    .gd-shell-nav { display: flex; overflow-x: auto; gap: .3rem; border-inline-end: 0; border-bottom: 1px solid var(--gd-border); border-radius: 0; }
    .gd-shell-group { display: none; }
    .gd-shell-nav .gd-mock-row { white-space: nowrap; flex: none; }
}

/* a "wireframe" of a page: named regions with pins */
.gd-wire { display: grid; gap: .5rem; width: min(100%, 44rem); }
.gd-wire-box { position: relative; padding: .55rem .7rem; border: 1px dashed rgba(var(--gd-accent-rgb), .45); border-radius: .55rem; background: rgba(var(--gd-accent-rgb), .04); }
.gd-wire-box > b { display: block; font-size: .76rem; color: var(--gd-text); }
.gd-wire-box > small { display: block; color: var(--gd-muted); font-size: .7rem; }
.gd-wire-box .gd-pin { position: absolute; top: -.55rem; inset-inline-start: -.55rem; inset-inline-end: auto; transform: none; }
.gd-wire-cols { display: grid; gap: .5rem; grid-template-columns: 2fr 1fr; }
@container gd (max-width: 560px) { .gd-wire-cols { grid-template-columns: 1fr; } }

/* a meter (trust score) */
.gd-meter { width: min(100%, 26rem); }
.gd-meter-bar { position: relative; height: .7rem; border-radius: 999px; background: linear-gradient(to var(--gd-end), #ef4444 0 50%, #f59e0b 50% 80%, #10b981 80% 100%); }
.gd-meter-mark { position: absolute; top: -.35rem; width: .2rem; height: 1.4rem; border-radius: 2px; background: var(--gd-text); }
.gd-meter-scale { display: flex; justify-content: space-between; font-size: .7rem; color: var(--gd-muted); margin-top: .3rem; }
.gd-meter-labels { display: grid; grid-template-columns: 50fr 30fr 20fr; text-align: center; font-size: .72rem; font-weight: 700; margin-top: .2rem; }

/* phone frame (mobile tab bar etc.) */
.gd-phone { width: 15rem; border: 6px solid #1e293b; border-radius: 1.6rem; overflow: hidden; background: var(--gd-surface); box-shadow: 0 14px 30px -14px rgba(15, 23, 42, .45); }
.gd-phone-screen { padding: .6rem; min-height: 8rem; font-size: .76rem; }
.gd-tabbar { display: flex; justify-content: space-around; padding: .35rem .2rem; border-top: 1px solid var(--gd-border); background: var(--gd-soft); font-size: .62rem; color: var(--gd-muted); }
.gd-tabbar span { display: flex; flex-direction: column; align-items: center; gap: .1rem; }
.gd-tabbar span.is-on { color: var(--gd-accent); font-weight: 700; }
.gd-tabbar i { font-size: .95rem; }

/* ---------- print booklet ---------- */
.gd-print-body { background: #eef1f5; }
.gd-print-bar { position: sticky; top: 0; z-index: 5; display: flex; gap: .5rem; justify-content: space-between; padding: .6rem 1rem; background: rgba(255, 255, 255, .92); border-bottom: 1px solid #dde2ea; backdrop-filter: blur(6px); }
.gd-print { max-width: 52rem; margin: 1.5rem auto; padding: 0 1rem 3rem; }
.gd-print > section { background: #fff; border-radius: 1rem; padding: 2.25rem clamp(1rem, 4vw, 3rem); margin-bottom: 1.25rem; box-shadow: 0 1px 3px rgba(15, 23, 42, .08); }
.gd-print-cover { text-align: center; padding-block: 4rem !important; border-top: 6px solid var(--gd-tone); }
.gd-print-cover .gd-cover-icon { margin: 0 auto 1rem; width: 4.5rem; height: 4.5rem; font-size: 2.2rem; }
.gd-print-cover h1 { font-size: 2.2rem; font-weight: 800; }
.gd-print-kicker { text-transform: uppercase; letter-spacing: .1em; color: var(--gd-muted); font-size: .8rem; margin-bottom: .4rem; }
.gd-print-sub { color: var(--gd-muted); font-size: 1.1rem; max-width: 32rem; margin: .5rem auto 1.5rem; }
.gd-print-date { color: var(--gd-muted); font-size: .85rem; }
.gd-print-contents ol { font-weight: 700; }
.gd-print-contents ol a { color: var(--gd-text); text-decoration: none; }
.gd-print-contents ul { font-weight: 400; color: var(--gd-muted); font-size: .9rem; margin: .2rem 0 .6rem; }

@media print {
    @page { size: A4; margin: 16mm 14mm 18mm; }
    [data-gd-noprint], .gd-print-bar { display: none !important; }
    .gd-print-body { background: #fff; }
    .gd-print { max-width: none; margin: 0; padding: 0; }
    .gd-print > section { box-shadow: none; border-radius: 0; padding: 0 !important; margin: 0; }
    .gd-print-cover { min-height: 240mm; display: flex; flex-direction: column; justify-content: center; border-top: 0 !important; }
    .gd-print-contents, .gd-print-chapter { break-before: page; }
    .gd-prose { font-size: 10.5pt; }
    .gd-prose h2, .gd-prose h3 { break-after: avoid; }
    .gd-fig, .gd-prose .admonition, .gd-table, .gd-prose tr { break-inside: avoid; }
    .gd-table { overflow: visible; }
    .gd-prose a { color: inherit; text-decoration: none; }
    * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* heading "copy link" anchors (help-center.js) */
.gd-anchor { margin-inline-start: .4rem; font-size: .8em; color: var(--gd-muted); opacity: 0; text-decoration: none; transition: opacity .15s; }
.gd-prose h2:hover .gd-anchor, .gd-prose h3:hover .gd-anchor, .gd-anchor:focus { opacity: 1; }
.gd-anchor.is-copied { color: #059669; opacity: 1; }
.gd-anchor.is-copied i::before { content: "\f26e"; } /* check-lg */
@media print { .gd-anchor { display: none; } }

/* a help sentence quoted from the dashboard ({{ui:...}} with a whole sentence) */
.gd-ui-quote { font-style: normal; color: var(--gd-text); background: rgba(var(--gd-accent-rgb), .06); border-radius: .3rem; padding: 0 .2em; }
.gd-ui-quote:lang(fa), [dir="rtl"] .gd-ui-quote { quotes: "«" "»"; }
.gd-ui-quote:lang(de) { quotes: "„" "“"; }

/* Persian step numbers and pins in RTL articles */
.gd-prose:lang(fa) ol > li::before, [lang="fa"] .gd-prose ol > li::before { content: counter(gd-step, persian); }
.gd-field .gd-pin { inset-inline-end: auto; inset-inline-start: -.5rem; top: -.5rem; }
.gd-guide-chapters:lang(fa), .gd-print-contents ol:lang(fa) { list-style-type: persian; }
.gd-tl-block { font-size: .62rem; text-overflow: ellipsis; display: block; line-height: 2.1rem; text-align: center; }
.gd-tl-track { height: 2.6rem; }
.gd-tl-block { top: .25rem; bottom: .25rem; line-height: 2rem; }

/* =====================================================================================================
   Public help site frame (support/help/_layout.html): site header + coloured band + full-width body.
   ===================================================================================================== */
.gd-site { background: var(--bs-body-bg); }
.gd-band { padding: 1.25rem 0 1.5rem !important; border-bottom: 1px solid var(--bs-border-color);
    background: radial-gradient(120% 160% at 50% 0%, rgba(var(--bs-primary-rgb), .09), transparent 65%), var(--bs-tertiary-bg, #f6f8fb); }
.gd-band .gd-crumbs { margin-bottom: .75rem; color: var(--bs-secondary-color); }
.gd-band .gd-crumbs a { color: var(--bs-secondary-color); }
.gd-band-top { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; align-items: center; justify-content: space-between; }
.gd-band-top .gd-crumbs { margin: 0; }
.gd-band .gd-hero { background: none; border: 0; box-shadow: none; padding: 1rem 0 .5rem; margin: 0; }
.gd-band .gd-hero.is-slim { padding-top: .25rem; }
.gd-band .gd-hero-title { font-size: clamp(1.7rem, 1.3rem + 1.6vw, 2.4rem); }
.gd-band .gd-cover { margin: 1rem 0 0; box-shadow: none; }
.gd-search.is-compact { margin: 0; width: min(100%, 22rem); }
.gd-search.is-compact .form-control { min-height: 2.35rem; font-size: .9rem; background: var(--bs-body-bg); }
.gd-site-body { padding-top: 1.75rem; padding-bottom: 3.5rem; }
.gd-site .gd-section-title { margin-top: 0; font-size: 1.1rem; }
.gd-site .gd-article { border: 0; box-shadow: none; background: transparent; padding-inline: clamp(0rem, 2cqi, 1.5rem); padding-top: .25rem; }
.gd-site .gd-nav-box { box-shadow: none; }
.gd-site .gd-toc-box { box-shadow: none; border: 0; border-inline-start: 1px solid var(--bs-border-color); border-radius: 0; }
.gd-site .gd-toc-top { border-top: 0; }
@container gd (min-width: 1080px) {
    .gd-site .gd-layout { grid-template-columns: 15rem minmax(0, 1fr) 13rem; }
    .gd-site .gd-toc { display: block; position: sticky; top: var(--gd-top); max-height: calc(100vh - var(--gd-top) - 1rem); overflow: auto; }
    .gd-site .gd-toc-inline { display: none; }
}
@media print { .gd-band, header, footer { display: none !important; } }
/* the public theme's --bs-secondary-color is near-white (pages/base): use a readable muted tone instead */
.gd-site, .gd-site .gd-root { --gd-muted: color-mix(in srgb, var(--bs-body-color, #4b5563) 78%, var(--bs-body-bg, #fff)); }
.gd-band .gd-crumbs, .gd-band .gd-crumbs a { color: var(--gd-muted); }
.gd-site .gd-text, .gd-site .gd-prose { color: var(--bs-heading-color, #1f2937); }

/* ---------- right-to-left (fa) ----------------------------------------------------------------------------
   Arrows and chevrons point along the reading direction. The help pages do this themselves (the site's rtl.css
   flip does not reach these icons, and the print page has no rtl.css): mirror the glyph once, on ::before. */
.gd-root, .gd-print-body { --gd-end: right; --gd-half: -50% 0; }
[dir="rtl"] .gd-root, [dir="rtl"].gd-root, .gd-root [dir="rtl"], .gd-print-body.rtl { --gd-end: left; --gd-half: 50% 0; }
:is([dir="rtl"], .rtl) :is(.gd-flow-arrow, .gd-dir-icon, .gd-crumb-sep)::before { display: inline-block; transform: scaleX(-1) !important; }
.gd-dir-icon, .gd-flow-arrow, .gd-crumb-sep { transform: none !important; }
.gd-sep-icon { font-size: .75em; opacity: .6; margin: 0 .1rem; }
/* five steps + arrows fit one line in the article column (a wrapped arrow would point at nothing) */
.gd-flow { gap: .35rem; }
.gd-flow-step { min-width: 6rem; flex: 1 1 6rem; padding: .6rem .45rem; }
.gd-flow-arrow { flex: none; font-size: .95rem; }
