/* ============================================================================
   Auditoria Help Center — v5.9.40
   Color palette tuned for WCAG 2.1 AA contrast on default settings.
   ============================================================================ */

:root {
  /* Palette: minimal, near-monochrome with a single accent.
     ServiceNow uses navy + green; we keep the configured Auditoria brand color
     as the link/accent so the theme still feels Auditoria-branded. */
  --aud-color-bg:           #ffffff;
  --aud-color-bg-alt:       #f4f5f7;
  --aud-color-bg-banner:    #e6f0fb;
  --aud-color-text:         #1f2329;
  --aud-color-text-muted:   #4a5563;
  --aud-color-text-subtle:  #6b7380;
  --aud-color-rule:         #e5e7eb;
  --aud-color-rule-strong:  #cdd2d8;

  --aud-color-link:         #0066D6;
  --aud-color-link-hover:   #0E5E84;
  --aud-color-brand:        #0066D6;
  --aud-color-brand-text:   #FFFFFF;

  /* Hero gradient — darker stops than v5.8 so white text on the start of
     the gradient meets WCAG AA (4.5:1) instead of failing at 2.84:1. */
  --aud-color-hero-bg-start: #1F7B98;
  --aud-color-hero-bg-mid:   #144E7E;
  --aud-color-hero-bg-end:   #0F3C61;
  --aud-color-hero-bg:       linear-gradient(90deg, var(--aud-color-hero-bg-start) 0%, var(--aud-color-hero-bg-mid) 55%, var(--aud-color-hero-bg-end) 100%);
  --aud-color-hero-text:     #ffffff;
  --aud-color-hero-muted:    #E2EFFB;

  /* Topbar is white with dark navy utility bar above (corporate strip).
     Utility bar stays darker than the hero so it reads as "system chrome"
     rather than competing with the hero for attention. */
  --aud-color-topbar-utility-bg:   #002F60;
  --aud-color-topbar-utility-text: #ffffff;
  --aud-color-topbar-bg:           #ffffff;
  --aud-color-topbar-text:         #1f2329;

  /* Callouts: kept colored per user choice, but toned way down (very subtle tints). */
  --aud-color-note-bg:      #f3f7fc;
  --aud-color-note-bar:     #5b8fb9;
  --aud-color-tip-bg:       #f3f9f4;
  --aud-color-tip-bar:      #6ba776;
  --aud-color-important-bg: #fbf6ee;
  --aud-color-important-bar:#c89855;

  /* Spacing scale (4px base) */
  --aud-space-1: 4px;
  --aud-space-2: 8px;
  --aud-space-3: 12px;
  --aud-space-4: 16px;
  --aud-space-5: 24px;
  --aud-space-6: 32px;
  --aud-space-7: 48px;
  --aud-space-8: 64px;

  /* Typography */
  --aud-font-body:  -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --aud-font-heading: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --aud-font-mono:  ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --aud-fs-1:  13px;
  --aud-fs-2:  14px;
  --aud-fs-3:  15px;
  --aud-fs-4:  16px;
  --aud-fs-5:  17px;
  --aud-fs-6:  19px;
  --aud-fs-7:  22px;
  --aud-fs-8:  26px;
  --aud-fs-9:  34px;
  --aud-lh-tight: 1.25;
  --aud-lh-normal: 1.55;
  --aud-lh-prose: 1.65;

  /* Layout */
  --aud-content-max: 1600px;
  --aud-prose-max:   720px;
  --aud-rail-w:      260px;
  --aud-radius-sm:   3px;
  --aud-radius-md:   4px;
}

/* Honor user motion preference. The theme has minimal motion today
   (dropdown toggles, mobile drawer slide), but reduced-motion users
   should not see any of it. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ----------------------------------------------------------------------------
   Reset & base
---------------------------------------------------------------------------- */
* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--aud-font-body);
  font-size: var(--aud-fs-4);
  line-height: var(--aud-lh-normal);
  color: var(--aud-color-text);
  background: var(--aud-color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { max-width: 100%; height: auto; vertical-align: middle; }

a { color: var(--aud-color-link); text-decoration: none; }
a:hover { color: var(--aud-color-link-hover); text-decoration: underline; }
a:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 2px;
  border-radius: var(--aud-radius-sm);
}

button { font-family: inherit; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--aud-font-heading);
  color: var(--aud-color-text);
  font-weight: 600;
  line-height: var(--aud-lh-tight);
  margin: 0 0 var(--aud-space-3);
}
h1 { font-size: var(--aud-fs-9); font-weight: 600; letter-spacing: -0.01em; }
h2 { font-size: var(--aud-fs-8); margin-top: var(--aud-space-7); }
h3 { font-size: var(--aud-fs-7); margin-top: var(--aud-space-6); }
h4 { font-size: var(--aud-fs-6); margin-top: var(--aud-space-5); }

p { margin: 0 0 var(--aud-space-4); line-height: var(--aud-lh-prose); }

/* ----------------------------------------------------------------------------
   Horizontal rules. Authors insert <hr> between sections as visual breaks.
   The base hr rule applies everywhere; the .aud-prose hr override tightens
   it inside articles since H2 already provides the primary section rhythm.
   The hr+h2/h3 collapse rule lives below the .aud-prose h2 rule (search for
   "hr-followed-by-heading collapse") so it wins by source order without
   needing !important.
---------------------------------------------------------------------------- */
hr {
  border: 0;
  border-top: 1px solid var(--aud-color-rule);
  margin: var(--aud-space-4) 0;
}
.aud-prose hr {
  margin: var(--aud-space-3) 0;
  border-top: 0.5px solid var(--aud-color-rule);
}

ul, ol { padding-left: var(--aud-space-6); margin: 0 0 var(--aud-space-4); }
li { margin-bottom: var(--aud-space-2); line-height: var(--aud-lh-prose); }

code {
  font-family: var(--aud-font-mono);
  font-size: 0.9em;
  background: var(--aud-color-bg-alt);
  padding: 1px 4px;
  border-radius: var(--aud-radius-sm);
  border: 1px solid var(--aud-color-rule);
}

pre {
  font-family: var(--aud-font-mono);
  font-size: var(--aud-fs-2);
  background: var(--aud-color-bg-alt);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-sm);
  padding: var(--aud-space-4);
  overflow-x: auto;
  margin: var(--aud-space-4) 0;
  line-height: 1.5;
}
pre code { background: none; border: none; padding: 0; }

/* Base table — structural defaults only. Visual styling (borders, header
   tints, etc.) lives in .aud-prose table where article tables are scoped.
   Tables outside articles (e.g., admin UI, dashboard) inherit from here. */
table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--aud-space-4) 0;
  font-size: var(--aud-fs-3);
}
th, td {
  text-align: left;
  padding: var(--aud-space-3) var(--aud-space-4);
  vertical-align: top;
}
th {
  font-weight: 600;
  color: var(--aud-color-text);
}

blockquote {
  margin: var(--aud-space-4) 0;
  padding: var(--aud-space-3) var(--aud-space-4);
  background: var(--aud-color-bg-alt);
  border-left: 3px solid var(--aud-color-rule-strong);
  color: var(--aud-color-text-muted);
}

/* ----------------------------------------------------------------------------
   Skip links (FR-008)
---------------------------------------------------------------------------- */
.aud-skip-links { position: absolute; top: 0; left: 0; z-index: 10000; }
.aud-skip-link {
  position: absolute;
  left: -10000px;
  top: 0;
  background: var(--aud-color-text);
  color: #fff;
  padding: var(--aud-space-3) var(--aud-space-4);
  font-weight: 600;
  font-size: var(--aud-fs-3);
}
.aud-skip-link:focus, .aud-skip-link:focus-visible {
  left: var(--aud-space-3); top: var(--aud-space-3);
  outline: 2px solid #fff; outline-offset: 2px;
}

/* ----------------------------------------------------------------------------
   Header / Topbar — two stacked bars (corporate utility + docs subnav)

   The utility bar is now WHITE with the centered full-color logo. Locale
   switcher / CTA / user identity sit on the right side. A symmetrical
   left-side region (empty by default) keeps the centered logo balanced.
---------------------------------------------------------------------------- */
.aud-utilitybar {
  background: #ffffff;
  color: var(--aud-color-text);
  font-size: var(--aud-fs-2);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-utilitybar__inner {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-3) var(--aud-space-5);
  display: grid;
  /* Three-column layout: empty left spacer | centered logo | right-side
     controls (locale, CTA, user pill). The 1fr side columns balance each
     other so the logo stays optically centered in the bar. */
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--aud-space-4);
}
.aud-utilitybar__side {
  display: flex;
  align-items: center;
  gap: var(--aud-space-3);
  min-height: 1px;
}
.aud-utilitybar__side--right {
  justify-self: end;
}
.aud-utilitybar__logo-wrap {
  justify-self: center;
}
.aud-utilitybar__logo-link {
  display: inline-block;
  line-height: 0;
}
.aud-utilitybar__logo {
  height: 88px;
  width: auto;
  display: block;
}
.aud-utilitybar__cta {
  background: var(--aud-color-brand);
  color: var(--aud-color-brand-text);
  padding: var(--aud-space-2) var(--aud-space-4);
  border-radius: var(--aud-radius-md);
  font-weight: 600;
  font-size: var(--aud-fs-2);
  border: none;
  cursor: pointer;
  text-decoration: none;
}
.aud-utilitybar__cta:hover { opacity: 0.9; text-decoration: none; color: var(--aud-color-brand-text); }

/* User pill — avatar + name + chevron (signed-in state) */
.aud-userpill__toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--aud-space-2);
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-link);
  padding: var(--aud-space-1) var(--aud-space-2);
  border-radius: var(--aud-radius-md);
}
.aud-userpill__toggle:hover { background: var(--aud-color-bg-alt); }
.aud-userpill__toggle:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
}
.aud-userpill__avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  flex: 0 0 auto;
}
.aud-userpill__name {
  font-weight: 500;
  color: var(--aud-color-link);
}
.aud-userpill__signin {
  font-size: var(--aud-fs-3);
  color: var(--aud-color-link);
  text-decoration: none;
}
.aud-userpill__signin:hover { text-decoration: underline; }

/* v5.9.27: Top-level "Submit a request" link in the utility bar.
   Sits next to the user pill when signed in. Plain text-link styled —
   matches the original Auditoria layout the team approved. Buried in
   the dropdown was a discoverability problem; this puts it in the
   header where customers expect it. */
.aud-utilitybar__submit {
  font-size: var(--aud-fs-3);
  color: var(--aud-color-link);
  text-decoration: none;
  white-space: nowrap;
}
@media (hover: hover) {
  .aud-utilitybar__submit:hover {
    text-decoration: underline;
    color: var(--aud-color-link);
  }
}
.aud-utilitybar__submit:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 2px;
  border-radius: 2px;
}
@media (max-width: 720px) {
  /* Hide the text link on phones — Submit a request remains accessible
     via the My Requests page empty-state CTA and via direct URL. The
     header gets crowded on narrow screens. */
  .aud-utilitybar__submit { display: none; }
}

/* Doc subnav: white strip below the utility bar */
.aud-docsnav {
  background: var(--aud-color-bg);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-docsnav__inner {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: 0 var(--aud-space-5);
  display: flex;
  align-items: center;
  gap: var(--aud-space-6);
  height: 56px;
}
.aud-docsnav__title {
  font-family: var(--aud-font-heading);
  font-weight: 600;
  font-size: var(--aud-fs-6);
  color: var(--aud-color-text);
  text-decoration: none;
}
/* v5.9.28: turn blue on hover for visual parity with Release Notes /
   Integration Documentation links. When you're on the help_center home
   page, Zendesk renders this link as a <span> (since you're already on
   that page) — this rule applies to both <a> and <span> forms. */
@media (hover: hover) {
  .aud-docsnav__title:hover {
    color: var(--aud-color-link);
    text-decoration: none;
  }
}
.aud-docsnav__links {
  display: flex;
  gap: var(--aud-space-5);
  list-style: none;
  padding: 0;
  margin: 0;
}
.aud-docsnav__links li { margin: 0; }
.aud-docsnav__links a {
  color: var(--aud-color-text);
  font-size: var(--aud-fs-3);
  font-weight: 500;
}
.aud-docsnav__links a:hover { color: var(--aud-color-link); text-decoration: none; }

.aud-docsnav__spacer { flex: 1; }

.aud-docsnav__search {
  flex: 0 1 280px;
  min-width: 200px;
}
/* v5.9.12: search input replaced with custom HTML form (no Zendesk helper).
   The form is the positioning context; icon sits absolutely inside it on
   the left, input has padding-left to leave room for the icon. No visible
   submit button — Enter submits the form. */
.aud-docsnav__search {
  position: relative;
}

/* v5.9.38: hide the docsnav search on pages that already have a more
   prominent search input. Two search boxes on the same page is a UX
   anti-pattern — it creates decision paralysis ("which one do I
   use?"), dilutes the visual weight of the primary search, and offers
   no functional benefit since all variants submit to the same
   /hc/{locale}/search endpoint with the same `query` param.

   Target pages:
   - Home page: contains the big hero search (.aud-hero__search)
   - Search results page: contains an inline refinement search
     (.aud-search-page__form) showing the current query

   On every other page (article, category, section, request list,
   single ticket, etc.) the docsnav search remains visible as the
   only search affordance, exactly as needed.

   :has() browser support: Chrome 105+, Edge 105+, Safari 15.4+,
   Firefox 121+. Safe for Auditoria's enterprise customer base. Old
   browsers gracefully fall back to showing both (same as today —
   no regression for them). */
body:has(.aud-hero__search) .aud-docsnav__search,
body:has(.aud-search-page__form) .aud-docsnav__search {
  display: none;
}
.aud-search-form {
  position: relative;
  display: block;
  margin: 0;
  width: 100%;
}
.aud-search-form__icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--aud-color-text-subtle);
  pointer-events: none;
}
.aud-search-form__input {
  width: 100%;
  padding: 6px 12px 6px 32px;
  font-size: var(--aud-fs-3);
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: var(--aud-radius-md);
  background: #fff;
  color: var(--aud-color-text);
  font-family: inherit;
  /* Reset browser defaults on type=search (Safari adds rounded corners,
     Chrome adds a magnifier of its own that conflicts with our icon). */
  -webkit-appearance: none;
  appearance: none;
}
.aud-search-form__input::-webkit-search-decoration,
.aud-search-form__input::-webkit-search-cancel-button,
.aud-search-form__input::-webkit-search-results-button,
.aud-search-form__input::-webkit-search-results-decoration {
  -webkit-appearance: none;
}
.aud-search-form__input:focus {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
  border-color: transparent;
}
.aud-search-form__input:focus + .aud-search-form__icon,
.aud-search-form:focus-within .aud-search-form__icon {
  color: var(--aud-color-link);
}

.aud-docsnav__signin {
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
  border: 1px solid var(--aud-color-rule-strong);
  padding: var(--aud-space-2) var(--aud-space-4);
  border-radius: var(--aud-radius-md);
  background: #fff;
}
.aud-docsnav__signin:hover {
  border-color: var(--aud-color-link);
  color: var(--aud-color-link);
  text-decoration: none;
  background: #fff;
}
.aud-docsnav__signin:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
}

/* ----------------------------------------------------------------------------
   Dropdown component (used in utility bar locale switcher, signin menu)
---------------------------------------------------------------------------- */
.aud-dropdown { position: relative; }

.aud-dropdown__toggle {
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: var(--aud-fs-2);
  color: inherit;
  padding: var(--aud-space-2) var(--aud-space-3);
  display: inline-flex;
  align-items: center;
  gap: var(--aud-space-2);
  border-radius: var(--aud-radius-md);
}
.aud-dropdown__toggle:hover { background: var(--aud-color-bg-alt); }
.aud-dropdown__toggle:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
}

.aud-dropdown__chevron {
  transition: transform 120ms;
  flex: 0 0 auto;
}
.aud-dropdown__toggle[aria-expanded="true"] .aud-dropdown__chevron {
  transform: rotate(180deg);
}

.aud-dropdown__menu {
  position: absolute;
  right: 0;
  top: calc(100% + 4px);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  padding: var(--aud-space-1) 0;
  margin: 0;
  list-style: none;
  min-width: 200px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  z-index: 1000;
}
/* v5.9.28: explicit reset on direct children so browser bullets don't
   leak through on pages that override <ul> default styling (notably
   the user profile and contributions pages). */
.aud-dropdown__menu > li {
  list-style: none;
  margin: 0;
  padding: 0;
}
.aud-dropdown__menu > li::before {
  content: none;
}

.aud-dropdown__item {
  display: block;
  padding: var(--aud-space-2) var(--aud-space-4);
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
  text-decoration: none;
  white-space: nowrap;
}
.aud-dropdown__item:hover,
.aud-dropdown__item:focus-visible {
  background: var(--aud-color-bg-alt);
  color: var(--aud-color-text);
  text-decoration: none;
  outline: none;
}

.aud-dropdown__sep {
  height: 1px;
  background: var(--aud-color-rule);
  margin: var(--aud-space-1) 0;
  list-style: none;
}

/* User name and avatar in signin button */
.aud-dropdown__user-name {
  font-weight: 500;
}
.aud-dropdown .user-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
}

/* Utility bar dropdown toggles inherit the dark text color (white bar) */
.aud-utilitybar .aud-dropdown__toggle { color: var(--aud-color-text); }
.aud-utilitybar .aud-dropdown__toggle:hover { background: var(--aud-color-bg-alt); }
.aud-utilitybar__locale-name { font-size: var(--aud-fs-2); }

/* Mobile rail toggle (only shown < 900px) */
.aud-rail-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--aud-color-rule-strong);
  padding: 6px 8px;
  border-radius: var(--aud-radius-md);
  cursor: pointer;
  color: var(--aud-color-text);
}

/* ----------------------------------------------------------------------------
   Hero (home page only) — flat dark navy strip
---------------------------------------------------------------------------- */
.aud-hero {
  background: var(--aud-color-hero-bg);
  color: var(--aud-color-hero-text);
  padding: var(--aud-space-8) var(--aud-space-5);
}
.aud-hero__inner {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  text-align: center;
}
.aud-hero h1 {
  color: var(--aud-color-hero-text);
  font-size: 44px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 var(--aud-space-3);
}
.aud-hero p {
  color: var(--aud-color-hero-muted);
  font-size: var(--aud-fs-5);
  margin: 0 auto var(--aud-space-6);
  max-width: 640px;
}

/* Pill-shaped search bar with integrated Search button (matches reference) */
.aud-hero__search {
  max-width: 720px;
  margin: 0 auto;
  background: #ffffff;
  border-radius: 999px;
  padding: 6px;
  display: flex;
  align-items: stretch;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.10);
}
.aud-hero__search-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--aud-space-3) 0 var(--aud-space-4);
  color: var(--aud-color-text-subtle);
  flex: 0 0 auto;
}
.aud-hero__search-input-wrap {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  min-width: 0;
}
.aud-hero__search input,
.aud-hero__search .search-input {
  flex: 1 1 auto;
  width: 100%;
  padding: var(--aud-space-3) 0;
  font-size: var(--aud-fs-4);
  border: none;
  outline: none;
  background: transparent;
  color: var(--aud-color-text);
  font-family: inherit;
  min-width: 0;
}
.aud-hero__search input::placeholder { color: var(--aud-color-text-subtle); }
.aud-hero__search-btn {
  background: var(--aud-color-brand);
  color: var(--aud-color-brand-text);
  border: none;
  padding: var(--aud-space-3) var(--aud-space-6);
  font-weight: 600;
  font-size: var(--aud-fs-3);
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  flex: 0 0 auto;
}
.aud-hero__search-btn:hover { opacity: 0.92; }
.aud-hero__search-btn:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* ----------------------------------------------------------------------------
   Home page — Quick links / Video / Releases — flat 3-column
---------------------------------------------------------------------------- */
.aud-home {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-7) var(--aud-space-5);
}

/* ─── Shortcuts and Releases sections ───────────────────────────────────
   Both sit above the Browse Documentation directory and reuse the same
   visual language: small-caps section labels, white background, and the
   same card pattern as the directory below. No special panel styling, no
   gray background — single design system across the whole page. */

.aud-home--shortcuts {
  max-width: 1200px;
  padding-bottom: 0;
}

/* Still need help? — bottom-of-page contact section. Single card centered
   so it reads as an intentional CTA. Sits visually separated from the
   directory above by a subtle top border. */
.aud-home--help {
  max-width: 1200px;
  padding-top: var(--aud-space-7);
  margin-top: var(--aud-space-5);
  border-top: 1px solid var(--aud-color-rule);
}

/* Center modifier for the card grid — used when a section has 1 or 2
   cards (Quick links, Still need help) so they don't sit awkwardly to
   the left of an empty grid. The 3-card directory rows stay left-aligned
   (default) since they fill the row naturally. */
.aud-family__grid--center {
  justify-content: center;
}

/* Quick-link card colors. Cards on the home page (above the directory)
   reuse the .aud-card pattern but get their own muted color identities
   to differentiate them from category cards. */
.aud-card--quicklink-new      { --aud-card-color: #2a5cdb; --aud-card-bg: #eef2fb; }
.aud-card--quicklink-support  { --aud-card-color: #4a5563; --aud-card-bg: #eef0f3; }
/* .aud-card--integrations already defined below for the directory; the
   quick-link card reuses that same teal token for visual continuity with
   the integration card in the directory itself. */

/* Section labels in the shortcuts and help sections inherit the
   .aud-family__label style (small caps) but use a neutral gray since
   they aren't tied to a product family. */
.aud-home--shortcuts .aud-family__label,
.aud-home--help .aud-family__label {
  color: var(--aud-color-text-subtle);
  text-align: center;
}

/* Support note (replaces the v5.9.9 email-support card). Single centered
   line of prose with the email as an inline link — reads as a friendly
   closer, not a CTA card. The card pattern was overweight for a fallback
   contact line; users who scrolled this far have already scanned the
   directory. */
.aud-home--help .aud-home__support-note {
  max-width: 540px;
  margin: var(--aud-space-3) auto 0;
  text-align: center;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-3);
  line-height: var(--aud-lh-prose);
}
.aud-home__support-mail,
.aud-home__support-link {
  color: var(--aud-color-link);
  font-weight: 500;
}
/* ─── End Shortcuts and Help ─────────────────────────────────────────── */

/* ─── Request pages: new request form, single ticket, ticket list ───────
   Wraps Zendesk's React-rendered form components in a styled, themed
   container. The form internals are owned by Zendesk's new-request-form
   module and can't be restyled directly — we override the Garden CSS
   variables they use to bring colors, radii, and fonts in line with the
   theme tokens. */

/* Hero strip — same gradient as the home page hero, shorter */
.aud-request-hero {
  background: linear-gradient(135deg, #2a8ab8 0%, #1f4e7a 100%);
  padding: var(--aud-space-7) var(--aud-space-5) var(--aud-space-6);
  margin-bottom: 0;
  color: #fff;
}
.aud-request-hero__inner {
  max-width: 1200px;
  margin: 0 auto;
}
.aud-request-hero__inner .breadcrumbs,
.aud-request-hero__inner ol.breadcrumbs {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--aud-space-2);
  padding: 0;
  margin: 0 0 var(--aud-space-3);
  font-size: var(--aud-fs-3);
  color: rgba(255, 255, 255, 0.85);
}
.aud-request-hero__inner .breadcrumbs li,
.aud-request-hero__inner ol.breadcrumbs li {
  margin: 0;
}
.aud-request-hero__inner .breadcrumbs li::after,
.aud-request-hero__inner ol.breadcrumbs li::after {
  content: "›";
  margin-left: var(--aud-space-2);
  color: rgba(255, 255, 255, 0.6);
}
.aud-request-hero__inner .breadcrumbs li:last-child::after,
.aud-request-hero__inner ol.breadcrumbs li:last-child::after {
  content: "";
}
.aud-request-hero__inner .breadcrumbs a,
.aud-request-hero__inner ol.breadcrumbs a {
  color: rgba(255, 255, 255, 0.95);
  text-decoration: none;
}
.aud-request-hero__inner .breadcrumbs a:hover,
.aud-request-hero__inner ol.breadcrumbs a:hover {
  text-decoration: underline;
}
.aud-request-hero__title {
  margin: 0 0 var(--aud-space-2);
  font-size: 32px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #fff;
}
.aud-request-hero__lede {
  margin: 0;
  font-size: var(--aud-fs-4);
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.92);
  max-width: 720px;
}

/* Page body — two-column layout: form on the left, tips card on the right */
.aud-request {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--aud-space-7) var(--aud-space-5) var(--aud-space-8);
}
.aud-request__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: var(--aud-space-6);
  align-items: start;
}
.aud-request__main { min-width: 0; }

/* Form card — gives Zendesk's React form a neutral surface to render on */
.aud-request__card {
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  padding: var(--aud-space-6);
}

/* Override Zendesk Garden form variables so the form internals pick up
   our colors and radii. Garden uses --button-color-primary etc. for
   primary buttons, which maps to our link color. */
.aud-request__card #new-request-form {
  --zd-color-primary: var(--aud-color-link);
  --zd-color-foreground: var(--aud-color-text);
  --zd-color-background: #fff;
  --zd-border-radius: var(--aud-radius-md);
  font-family: var(--aud-font-family);
  color: var(--aud-color-text);
}

/* v5.9.33: HIDE article-suggestion popups inside the Submit a Request
   form. When customers type into the Subject field, Zendesk's form
   module queries the help center for matching articles and pops them
   up inline. Auditoria's customers found this disruptive — they're
   filing tickets BECAUSE they couldn't find an answer, so re-suggesting
   articles at the moment of submission feels redundant.

   Earlier attempt (v5.9.31) tried to disable this via the answerBot
   prop — that crashed the form module entirely, leaving an empty
   container. This pure-CSS approach is safer: form renders normally,
   we just hide the suggestion UI after the fact.

   Selectors are broad/defensive because Zendesk's React form uses
   generated class names AND data-* attributes; we cast a wide net
   without targeting form fields the customer needs (subject, body,
   submit button). */
#new-request-form [data-garden-id*="answerbot" i],
#new-request-form [data-test-id*="answer-bot" i],
#new-request-form [data-test-id*="suggestion" i],
#new-request-form [class*="answer-bot" i],
#new-request-form [class*="suggested-articles" i],
#new-request-form [aria-label*="suggested articles" i],
#new-request-form [aria-label*="suggestions" i] {
  display: none !important;
}

/* Form labels — Zendesk renders these as <label> elements; tighten and
   align with theme typography. The `&` selectors descend into the React
   subtree which uses generic markup. */
.aud-request__card label {
  font-weight: 600;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
  margin-bottom: 6px;
  display: block;
}

/* Inputs and textareas — Zendesk's defaults are too rounded and use a
   washed-out border. Replace with theme tokens. */
.aud-request__card input[type="text"],
.aud-request__card input[type="email"],
.aud-request__card input[type="search"],
.aud-request__card input[type="tel"],
.aud-request__card input[type="url"],
.aud-request__card input[type="number"],
.aud-request__card textarea,
.aud-request__card select {
  width: 100%;
  padding: 10px 12px;
  font-size: var(--aud-fs-4);
  font-family: inherit;
  color: var(--aud-color-text);
  background: #fff;
  border: 1px solid var(--aud-color-rule-strong, #d1d5db);
  border-radius: 6px;
  box-shadow: none;
  transition: border-color 120ms, box-shadow 120ms;
}
.aud-request__card input[type="text"]:focus,
.aud-request__card input[type="email"]:focus,
.aud-request__card input[type="search"]:focus,
.aud-request__card input[type="tel"]:focus,
.aud-request__card input[type="url"]:focus,
.aud-request__card input[type="number"]:focus,
.aud-request__card textarea:focus,
.aud-request__card select:focus {
  outline: none;
  border-color: var(--aud-color-link);
  box-shadow: 0 0 0 3px rgba(42, 138, 184, 0.15);
}

.aud-request__card textarea {
  min-height: 140px;
  line-height: 1.5;
}

/* Submit button — Zendesk's default is plain blue. Match our link color
   token and add a subtle hover state. */
.aud-request__card button[type="submit"],
.aud-request__card .button-primary,
.aud-request__card input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 24px;
  font-size: var(--aud-fs-4);
  font-weight: 600;
  font-family: inherit;
  color: #fff;
  background: var(--aud-color-link);
  border: 1px solid var(--aud-color-link);
  border-radius: 6px;
  cursor: pointer;
  transition: background 120ms, transform 120ms;
}
.aud-request__card button[type="submit"]:hover,
.aud-request__card .button-primary:hover,
.aud-request__card input[type="submit"]:hover {
  background: var(--aud-color-link-hover, #1f6f93);
  transform: translateY(-1px);
}
.aud-request__card button[type="submit"]:focus-visible,
.aud-request__card .button-primary:focus-visible,
.aud-request__card input[type="submit"]:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 2px;
}

/* Field hints / descriptions / error messages */
.aud-request__card .form-field-hint,
.aud-request__card .help-text,
.aud-request__card .form-help {
  font-size: 13px;
  color: var(--aud-color-text-muted);
  margin-top: 4px;
  line-height: 1.5;
}
.aud-request__card .form-field-error,
.aud-request__card .error-message {
  font-size: 13px;
  color: #c0392b;
  margin-top: 4px;
}

/* Spacing between fields */
.aud-request__card .form-field,
.aud-request__card .ticket-form-field,
.aud-request__card > div > div {
  margin-bottom: var(--aud-space-4);
}

/* Tips sidebar — secondary, helpful context */
.aud-request__aside { min-width: 0; }
.aud-request__tipcard {
  background: var(--aud-color-bg-alt);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  padding: var(--aud-space-5);
  position: sticky;
  top: var(--aud-space-5);
}
.aud-request__tipcard-title {
  margin: 0 0 var(--aud-space-3);
  font-size: var(--aud-fs-4);
  font-weight: 600;
  color: var(--aud-color-text);
}
.aud-request__tiplist {
  list-style: none;
  padding: 0;
  margin: 0 0 var(--aud-space-4);
}
.aud-request__tiplist li {
  position: relative;
  padding-left: 22px;
  margin-bottom: 10px;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text-muted);
  line-height: 1.5;
}
.aud-request__tiplist li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--aud-color-link);
}
.aud-request__tipcard-divider {
  border-top: 1px solid var(--aud-color-rule);
  margin: var(--aud-space-4) 0;
}
.aud-request__tipcard-foot {
  margin: 0;
  font-size: 13px;
  color: var(--aud-color-text-muted);
  line-height: 1.5;
}
.aud-request__tipcard-foot a {
  color: var(--aud-color-link);
  font-weight: 600;
}

/* Tablet and below: stack the sidebar under the form */
@media (max-width: 900px) {
  .aud-request__layout {
    grid-template-columns: 1fr;
  }
  .aud-request__tipcard {
    position: static;
  }
}

/* Mobile: reduce padding */
@media (max-width: 600px) {
  .aud-request-hero {
    padding: var(--aud-space-5) var(--aud-space-4) var(--aud-space-5);
  }
  .aud-request-hero__title {
    font-size: 24px;
  }
  .aud-request {
    padding: var(--aud-space-5) var(--aud-space-4) var(--aud-space-7);
  }
  .aud-request__card {
    padding: var(--aud-space-5) var(--aud-space-4);
  }
}
/* ─── End Request pages ──────────────────────────────────────────────── */


/* ─── Browse documentation: audience-grouped card grid ──────────────────
   Design intent:
   - Uniform card grid. Every category looks identical regardless of which
     family it's in. Family identity is signaled by section label color and
     card icon tint, not by changing the card's shape.
   - Tight content max-width (1200px) keeps the grid readable on wide
     monitors without stretching cards into banners.
   - Single-card families (Admin, SmartResearch, Integrations) fill column 1
     of a 3-column grid; columns 2 and 3 stay empty. Cards are the same
     width as cards in multi-card families — no special "solo" sizing. */

.aud-home--directory {
  max-width: 1200px;
  padding: var(--aud-space-7) var(--aud-space-5) var(--aud-space-8);
}

.aud-home__intro {
  margin: 0 0 var(--aud-space-6);
}
.aud-home__title {
  margin: 0 0 6px;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--aud-color-text);
}
.aud-home__lede {
  margin: 0;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-3);
  line-height: 1.5;
}

.aud-families {
  display: flex;
  flex-direction: column;
  gap: var(--aud-space-6);
}
.aud-families__loading,
.aud-families__error {
  color: var(--aud-color-text-subtle);
  font-style: italic;
  padding: var(--aud-space-5) 0;
}

.aud-family {
  /* No borders, no rules — spacing alone provides separation. */
}

.aud-family__label {
  margin: 0 0 var(--aud-space-3);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--aud-family-color, var(--aud-color-text-subtle));
}

.aud-family__grid {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--aud-space-3);
}
.aud-card {
  /* basis 280 + grow 1 means: at least 280px, grow to fill available row.
     max-width 380 caps it so a single card doesn't stretch into a banner.
     Three cards in a row fit comfortably at ~370-380px each on a 1152px
     grid. One card alone sits at 380px with empty space to its right —
     same width as cards in multi-card sections, preserving visual
     consistency across families. */
  flex: 1 1 280px;
  max-width: 380px;
  min-width: 0;
  margin: 0;
}

/* Family color tokens applied to the family wrapper (drives label color
   for multi-card families) AND replicated on each card (drives card icon
   tint and hover border). The card-level classes let solo families combine
   into one row while keeping per-card color identity. */
.aud-family--administration { --aud-family-color: #2a5cdb; }
.aud-family--ap            { --aud-family-color: #0a8f4e; }
.aud-family--ar            { --aud-family-color: #b8730a; }
.aud-family--smartresearch { --aud-family-color: #6b3eb5; }
.aud-family--integrations  { --aud-family-color: #0a7a8c; }
/* The combined Platform row contains cards from multiple families, so its
   label uses a neutral gray umbrella color rather than any single family's
   color. Individual cards inside still get their per-family icon tint. */
.aud-family--more          { --aud-family-color: #5a6268; }

/* Per-card family identity (works both inside multi-card sections and in
   the combined "more" row at the bottom of the page). */
.aud-card--administration { --aud-card-color: #2a5cdb; --aud-card-bg: #eef2fb; }
.aud-card--ap            { --aud-card-color: #0a8f4e; --aud-card-bg: #e9f6ee; }
.aud-card--ar            { --aud-card-color: #b8730a; --aud-card-bg: #faf2e3; }
.aud-card--smartresearch { --aud-card-color: #6b3eb5; --aud-card-bg: #f1ebfa; }
.aud-card--integrations  { --aud-card-color: #0a7a8c; --aud-card-bg: #e6f2f5; }

/* Combined "Platform" row. The label itself provides the section-break
   visual cue, same as every other family. The parent .aud-families
   container is a flex column with gap: var(--aud-space-6) between
   sections, which already gives uniform spacing automatically.

   v5.9.10 added a margin-top here trying to "make spacing consistent",
   but the flex gap was already doing that — so the extra margin made
   the gap between AR and PLATFORM larger than the gap between AP and
   AR. v5.9.22 removes the margin-top to restore even rhythm. */
.aud-family--more {
  /* No extra margin — flex gap on parent handles section spacing. */
}

/* The card itself — same shape regardless of family. */
.aud-card a {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: var(--aud-space-3);
  height: 100%;
  padding: var(--aud-space-4) var(--aud-space-5) var(--aud-space-4) var(--aud-space-4);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  text-decoration: none;
  color: var(--aud-color-text);
  transition: border-color 140ms, box-shadow 140ms, transform 140ms;
}
.aud-card a:hover {
  border-color: var(--aud-card-color, var(--aud-family-color, var(--aud-color-link)));
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
  text-decoration: none;
  color: var(--aud-color-text);
  transform: translateY(-1px);
}
.aud-card a:focus-visible {
  outline: 2px solid var(--aud-card-color, var(--aud-family-color, var(--aud-color-link)));
  outline-offset: 2px;
}

.aud-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--aud-card-bg, var(--aud-color-bg-alt));
  color: var(--aud-card-color, var(--aud-family-color, var(--aud-color-link)));
}

.aud-card__body {
  flex: 1 1 auto;
  min-width: 0;
}
.aud-card__title {
  display: block;
  font-weight: 600;
  font-size: var(--aud-fs-4);
  line-height: 1.35;
  color: var(--aud-color-text);
  margin-bottom: 4px;
}
.aud-card__title-ext {
  margin-left: 5px;
  vertical-align: -2px;
  color: var(--aud-color-text-subtle);
}
.aud-card__desc {
  display: block;
  font-size: 13px;
  color: var(--aud-color-text-muted);
  line-height: 1.5;
}

.aud-card__arrow {
  position: absolute;
  right: var(--aud-space-4);
  top: 50%;
  transform: translateY(-50%) translateX(-4px);
  opacity: 0;
  color: var(--aud-card-color, var(--aud-family-color, var(--aud-color-link)));
  transition: opacity 140ms, transform 140ms;
  pointer-events: none;
}
.aud-card a:hover .aud-card__arrow {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}

/* Tablet: cards stay at flex-natural sizing (280-380px each). */
@media (max-width: 900px) {
  .aud-card { flex-basis: calc(50% - var(--aud-space-3) / 2); max-width: none; }
}

/* Mobile: single column. */
@media (max-width: 600px) {
  .aud-card { flex-basis: 100%; max-width: none; }
  .aud-home--directory { padding: var(--aud-space-5) var(--aud-space-4); }
  .aud-card a { padding: var(--aud-space-3) var(--aud-space-4); }
}
/* ─── End Browse documentation ──────────────────────────────────────── */


.aud-home__pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--aud-space-7);
  margin-bottom: var(--aud-space-8);
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.aud-home__triplet {
  display: grid;
  grid-template-columns: 1fr 1.4fr 1fr;
  gap: var(--aud-space-6);
  margin-bottom: var(--aud-space-8);
}

.aud-home__col-title {
  font-size: var(--aud-fs-3);
  font-weight: 600;
  color: var(--aud-color-text);
  margin: 0 0 var(--aud-space-4);
  text-align: center;
  letter-spacing: 0.02em;
}

/* Quick links container — single block (replaces the 2-column home pair) */
.aud-home__quicklinks-wrap {
  max-width: 920px;
  margin: 0 auto;
}
.aud-home__quicklinks-wrap .aud-home__col-title {
  text-align: center;
  font-size: var(--aud-fs-7);
  font-weight: 600;
  margin: 0 0 var(--aud-space-4);
}

.aud-quicklinks {
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  overflow: hidden;
  background: #fff;
}
.aud-quicklinks a {
  display: flex;
  align-items: center;
  gap: var(--aud-space-3);
  padding: var(--aud-space-4);
  border-bottom: 1px solid var(--aud-color-rule);
  color: var(--aud-color-link);
  font-weight: 500;
  font-size: var(--aud-fs-3);
  text-decoration: none;
}
.aud-quicklinks a:last-child { border-bottom: none; }
.aud-quicklinks a:hover { background: var(--aud-color-bg-alt); text-decoration: none; }
.aud-quicklinks__icon {
  flex: 0 0 28px;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--aud-color-bg-banner);
  color: var(--aud-color-link);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.aud-quicklinks__arrow {
  margin-left: auto;
  color: var(--aud-color-text-subtle);
}

/* Two-column variant — render the 5+ links as a 2-up grid on wider viewports */
.aud-quicklinks--two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-radius: var(--aud-radius-md);
  overflow: hidden;
}
.aud-quicklinks--two-col a {
  border-bottom: 1px solid var(--aud-color-rule);
}
/* Right column items have a left border to create grid lines */
.aud-quicklinks--two-col a:nth-child(2n) {
  border-left: 1px solid var(--aud-color-rule);
}
/* Last item(s) — drop bottom border. With odd item count, the last
   single item spans both columns to avoid awkward whitespace. */
.aud-quicklinks--two-col a:last-child:nth-child(odd) {
  grid-column: 1 / -1;
  border-left: none;
}
.aud-quicklinks--two-col a:last-child { border-bottom: none; }
.aud-quicklinks--two-col a:nth-last-child(2):nth-child(odd) { border-bottom: none; }

.aud-home__video {
  background: var(--aud-color-bg-alt);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  aspect-ratio: 16/9;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--aud-color-text-subtle);
  font-size: var(--aud-fs-3);
}

.aud-releases {
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  padding: var(--aud-space-4);
  background: #fff;
}
.aud-releases ul { list-style: none; padding: 0; margin: 0; }
.aud-releases li { margin: 0; }
.aud-releases a {
  display: block;
  padding: var(--aud-space-2) 0;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-link);
  font-weight: 500;
}
.aud-releases__sep {
  border-top: 1px solid var(--aud-color-rule);
  margin: var(--aud-space-3) 0;
}

/* Explore products — card grid (3-col on desktop, 2-col on tablet, 1-col mobile) */
.aud-explore {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-7) var(--aud-space-5);
}
.aud-explore__head {
  margin-bottom: var(--aud-space-5);
  text-align: center;
}
.aud-explore__head h2 {
  margin: 0 0 var(--aud-space-2);
  font-size: var(--aud-fs-8);
  font-weight: 600;
}
.aud-explore__lede {
  margin: 0;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-4);
}
.aud-explore__cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--aud-space-4);
  list-style: none;
  padding: 0;
  margin: 0;
}
.aud-explore__card { margin: 0; }
.aud-explore__card a {
  display: flex;
  align-items: flex-start;
  gap: var(--aud-space-3);
  padding: var(--aud-space-4);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  text-decoration: none;
  color: var(--aud-color-text);
  transition: border-color 120ms, box-shadow 120ms, transform 120ms;
  height: 100%;
}
.aud-explore__card a:hover {
  border-color: var(--aud-color-link);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  text-decoration: none;
  color: var(--aud-color-text);
  transform: translateY(-1px);
}
.aud-explore__card a:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
}
.aud-explore__card-icon {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--aud-color-bg-alt);
  border-radius: var(--aud-radius-sm);
  color: var(--aud-color-link);
}
.aud-explore__card-body {
  display: flex;
  flex-direction: column;
  gap: var(--aud-space-1);
  min-width: 0;
}
.aud-explore__card-name {
  font-size: var(--aud-fs-4);
  font-weight: 600;
  color: var(--aud-color-text);
}
.aud-explore__card-desc {
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text-muted);
  line-height: 1.45;
}

/* ----------------------------------------------------------------------------
   Browse by guide — home page audience-oriented IA
   4 cards in 2x2 grid on desktop, 1 column on mobile.
   Larger and more prominent than the previous Explore Products tiles
   since there are fewer of them and they're the primary IA.
---------------------------------------------------------------------------- */
.aud-guides {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-7) var(--aud-space-5);
}
.aud-guides__head {
  margin-bottom: var(--aud-space-6);
  text-align: center;
}
.aud-guides__head h2 {
  margin: 0 0 var(--aud-space-2);
  font-size: var(--aud-fs-8);
  font-weight: 600;
}
.aud-guides__lede {
  margin: 0;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-4);
}
.aud-guides__cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--aud-space-4);
  list-style: none;
  padding: 0;
  margin: 0;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
}
.aud-guides__card { margin: 0; }
.aud-guides__card a {
  display: flex;
  align-items: flex-start;
  gap: var(--aud-space-4);
  padding: var(--aud-space-5);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  text-decoration: none;
  color: var(--aud-color-text);
  transition: border-color 120ms, box-shadow 120ms, transform 120ms;
  height: 100%;
}
.aud-guides__card a:hover {
  border-color: var(--aud-color-link);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  text-decoration: none;
  color: var(--aud-color-text);
  transform: translateY(-2px);
}
.aud-guides__card a:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 2px;
}
.aud-guides__icon {
  flex: 0 0 48px;
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--aud-color-bg-alt);
  border-radius: var(--aud-radius-md);
  color: var(--aud-color-link);
}
/* Subtle per-audience accent on the icon background */
.aud-guides__card--admin .aud-guides__icon         { background: #EFF6FF; color: #1D4ED8; }
.aud-guides__card--ap .aud-guides__icon            { background: #ECFDF5; color: #047857; }
.aud-guides__card--ar .aud-guides__icon            { background: #FEF3C7; color: #B45309; }
.aud-guides__card--smartresearch .aud-guides__icon { background: #F5F3FF; color: #6D28D9; }
.aud-guides__card--integrations .aud-guides__icon  { background: #ECFEFF; color: #0E7490; }

.aud-guides__card-body {
  display: flex;
  flex-direction: column;
  gap: var(--aud-space-2);
  min-width: 0;
}
.aud-guides__card-name {
  font-size: var(--aud-fs-5);
  font-weight: 600;
  color: var(--aud-color-text);
}
.aud-guides__card-desc {
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text-muted);
  line-height: 1.5;
}

/* Medium: 2-col, last row will have 1 orphan */
@media (max-width: 1100px) {
  .aud-guides__cards { grid-template-columns: repeat(2, 1fr); }
}
/* Mobile: stack to single column */
@media (max-width: 700px) {
  .aud-guides__cards { grid-template-columns: 1fr; }
}

/* ----------------------------------------------------------------------------
   Browse by Products variant — same visual family as Browse by Guides
   but denser grid (more product cards fit). Per-product accent colors
   inherited from .aud-guides__card--{admin|ap|ar|smartresearch} which
   are applied at runtime by the home page script based on category name.
---------------------------------------------------------------------------- */
.aud-guides--products {
  /* Same outer wrapper as aud-guides */
  padding-top: 0;
}
.aud-guides__cards--products {
  /* 4 columns on wide, falls back to 3, 2, 1 */
  grid-template-columns: repeat(4, 1fr);
  max-width: 1280px;
}
@media (max-width: 1300px) {
  .aud-guides__cards--products { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 1100px) {
  .aud-guides__cards--products { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 700px) {
  .aud-guides__cards--products { grid-template-columns: 1fr; }
}
/* Slightly tighter padding on product cards since there are more of them */
.aud-guides__card--product a {
  padding: var(--aud-space-4);
  gap: var(--aud-space-3);
}
.aud-guides__card--product .aud-guides__icon {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
}
.aud-guides__card--product .aud-guides__icon svg {
  width: 20px;
  height: 20px;
}
.aud-guides__card--product .aud-guides__card-name {
  font-size: var(--aud-fs-4);
}

/* ----------------------------------------------------------------------------
   Audience guide landing pages (/p/admin-guide, /p/ap-guide, etc.)
   Vertical list of category cards belonging to that audience.
---------------------------------------------------------------------------- */
.aud-aud-guide {
  max-width: 880px;
  margin: 0 auto;
}
.aud-aud-guide__header {
  margin-bottom: var(--aud-space-6);
  padding-bottom: var(--aud-space-5);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-aud-guide__title {
  margin: 0 0 var(--aud-space-3);
  font-size: 32px;
  font-weight: 600;
}
.aud-aud-guide__lede {
  margin: 0;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-4);
  line-height: 1.5;
}
.aud-aud-guide__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--aud-space-3);
}
.aud-aud-guide__loading,
.aud-aud-guide__empty {
  padding: var(--aud-space-5);
  color: var(--aud-color-text-subtle);
  text-align: center;
  font-style: italic;
}
.aud-aud-guide__card { margin: 0; }
.aud-aud-guide__card-link {
  display: block;
  padding: var(--aud-space-4) var(--aud-space-5);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  text-decoration: none;
  color: var(--aud-color-text);
  transition: border-color 120ms, box-shadow 120ms;
}
.aud-aud-guide__card-link:hover {
  border-color: var(--aud-color-link);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  text-decoration: none;
  color: var(--aud-color-text);
}
.aud-aud-guide__card-title {
  margin: 0 0 var(--aud-space-2);
  font-size: var(--aud-fs-5);
  font-weight: 600;
}
.aud-aud-guide__card-desc {
  margin: 0 0 var(--aud-space-3);
  color: var(--aud-color-text-muted);
  line-height: 1.5;
}
.aud-aud-guide__card-cta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--aud-color-link);
  font-size: var(--aud-fs-3);
  font-weight: 500;
}

/* ----------------------------------------------------------------------------
   Article / Section / Category page layout

   Default 2-column (left rail + body) caps at content max.
   Article 3-column variant goes FLUID: left rail anchored left edge,
   right TOC anchored right edge, body in the middle capped at ~880px
   for line-length readability. Wide-screen extra space lives between
   the body and the TOC, not as outer margins.
---------------------------------------------------------------------------- */
.aud-page {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-5) var(--aud-space-5) var(--aud-space-8);
  display: grid;
  grid-template-columns: var(--aud-rail-w) 1fr;
  gap: var(--aud-space-7);
}
.aud-page--no-rail {
  grid-template-columns: 1fr;
}

/* 3-column variant — left rail + center body + right TOC.

   Layout choices:
   - Outer page caps at 1500px (centered when viewport is wider).
   - Body grows fluidly up to 1100px max (~110 chars per line at 17px,
     readable but not luxuriously short like 880px).
   - TOC sits flush against the body with normal gap (var(--aud-space-6)).
   - No invisible spacer column — extra width on huge monitors goes to
     outer page margins, not into a void between body and TOC.

   On wide monitors the page is centered. On 1280–1500px viewports it
   fills naturally. Below 1100px the TOC collapses (see media query). */
.aud-page--with-toc {
  max-width: 1500px;
  margin: 0 auto;
  padding: var(--aud-space-5) var(--aud-space-6) var(--aud-space-8);
  grid-template-columns: var(--aud-rail-w) minmax(0, 1fr) 240px;
  gap: var(--aud-space-7);
}
.aud-page--with-toc .aud-page__rail {
  /* default grid placement */
}
.aud-page--with-toc .aud-page__main {
  max-width: 1100px;
  min-width: 0;
}
.aud-page--with-toc .aud-page__toc {
  /* default grid placement */
}

/* When buildToc() determines the article has too few headings, the TOC
   element hides itself — but we keep the grid columns the same so the
   article body width stays IDENTICAL to articles that do have a TOC.

   v5.9.24: previously this rule collapsed the grid to 2 columns
   (`var(--aud-rail-w) 1fr`), which let the body expand into the empty
   TOC space and made short articles read with much longer line lengths
   than long articles — a jarring inconsistency stakeholders noticed
   when comparing pages. Now the layout shape stays the same; the only
   change with --no-toc is that the right column is empty rather than
   occupied. The reserved empty space is preferable to inconsistent
   reading widths across the help center. */
.aud-page--with-toc.aud-page--no-toc {
  /* No grid override — inherit the 3-column layout from
     .aud-page--with-toc above so body width stays at max 1100px. */
}

.aud-page__rail {
  border-right: 1px solid var(--aud-color-rule);
  padding-right: var(--aud-space-5);
}

/* ----------------------------------------------------------------------------
   Right rail — Table of contents (built client-side from H2/H3 in body)
---------------------------------------------------------------------------- */
.aud-page__toc {
  position: sticky;
  top: var(--aud-space-5);
  align-self: start;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  padding-left: var(--aud-space-4);
  border-left: 1px solid var(--aud-color-rule);
  font-size: var(--aud-fs-2);
}
.aud-toc__heading {
  font-size: var(--aud-fs-2);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--aud-color-text-muted);
  margin: 0 0 var(--aud-space-3);
}
.aud-toc__list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.aud-toc__item {
  margin: 0;
}
.aud-toc__item a {
  display: block;
  padding: 6px 8px;
  color: var(--aud-color-text-muted);
  text-decoration: none;
  border-left: 2px solid transparent;
  margin-left: -10px;
  padding-left: 10px;
  line-height: 1.4;
  font-size: var(--aud-fs-3);
  transition: color 120ms, border-color 120ms;
}
.aud-toc__item a:hover {
  color: var(--aud-color-link);
  text-decoration: none;
}
.aud-toc__item a.is-active {
  color: var(--aud-color-link);
  border-left-color: var(--aud-color-link);
  font-weight: 500;
}
/* H3 nesting under H2 */
.aud-toc__item--h3 a {
  padding-left: 24px;
  margin-left: -10px;
  font-size: var(--aud-fs-2);
}

/* Mobile TOC — collapsed disclosure widget above the article body */
.aud-toc-mobile {
  display: none;  /* shown only via media query below */
  margin: 0 0 var(--aud-space-5);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-sm);
  background: var(--aud-color-bg-alt);
}
.aud-toc-mobile__summary {
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
  padding: var(--aud-space-3) var(--aud-space-4);
  cursor: pointer;
  font-weight: 600;
  font-size: var(--aud-fs-3);
  list-style: none;
}
.aud-toc-mobile__summary::-webkit-details-marker { display: none; }
.aud-toc-mobile[open] .aud-toc-mobile__summary {
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-toc-mobile .aud-toc__list {
  padding: var(--aud-space-2) var(--aud-space-3);
}
.aud-toc-mobile .aud-toc__item a {
  padding: 6px 8px;
  margin: 0;
  border-left: none;
}

/* Anchor target offset so headings don't disappear under sticky topbar */
.aud-prose h2[id], .aud-prose h3[id] {
  scroll-margin-top: 80px;
}

/* ----------------------------------------------------------------------------
   Prev / Next pagination — appears at the bottom of every article
---------------------------------------------------------------------------- */
.aud-pagination {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  gap: var(--aud-space-4);
  margin: var(--aud-space-7) 0 var(--aud-space-5);
  padding-top: var(--aud-space-5);
  border-top: 1px solid var(--aud-color-rule);
}
.aud-pagination__slot {
  /* Empty placeholder — JS replaces this with a real button or removes it */
  display: none;
}
.aud-pagination__btn {
  display: inline-flex;
  align-items: center;
  gap: var(--aud-space-3);
  padding: var(--aud-space-3) var(--aud-space-4);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  background: #fff;
  text-decoration: none;
  color: var(--aud-color-text);
  /* v5.9.23: flex: 0 1 auto (was 0 1 50%) so buttons size to their
     content. With justify-content: space-between on the parent, this
     pushes Prev to the left edge and Next to the right edge with the
     space distributed in between — the standard pager layout users
     expect. The previous 50% basis made each button try to be 50% wide,
     filling the row entirely and leaving space-between with nothing to
     distribute. max-width caps a single very long title so the layout
     stays balanced even when one direction has a much longer title
     than the other. */
  flex: 0 1 auto;
  max-width: 45%;
  min-width: 0;
  transition: border-color 120ms, box-shadow 120ms;
}
.aud-pagination__btn:hover {
  border-color: var(--aud-color-link);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  text-decoration: none;
  color: var(--aud-color-text);
}
.aud-pagination__btn:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
}
.aud-pagination__icon {
  flex: 0 0 20px;
  color: var(--aud-color-text-subtle);
}
.aud-pagination__btn--next {
  margin-left: auto;
  text-align: right;
}
.aud-pagination__label {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.aud-pagination__label--right {
  align-items: flex-end;
}
.aud-pagination__direction {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.aud-pagination__title {
  font-size: var(--aud-fs-3);
  font-weight: 500;
  color: var(--aud-color-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

/* Page-local rail header pill */
.aud-pagerail__header {
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
  padding: var(--aud-space-3);
  background: var(--aud-color-bg-alt);
  border-radius: var(--aud-radius-sm);
  font-weight: 600;
  font-size: var(--aud-fs-3);
  margin-bottom: var(--aud-space-3);
  color: var(--aud-color-text);
}
.aud-pagerail__header svg { color: var(--aud-color-text-subtle); }

/* v5.9.39: switcher-enhanced rail header. When JS replaces the static
   header with the interactive switcher, .aud-pagerail__header--switcher
   gets added. The container loses its own padding/background so the
   inner <button> can be the full clickable target with native button
   semantics. Visual styling moves to the inner button — looks identical
   to the static version, but the whole header pill is now clickable. */
.aud-pagerail__header--switcher {
  padding: 0;
  background: transparent;
  position: relative;     /* anchor for the dropdown menu */
  display: block;
}
.aud-pagerail__switcher-toggle {
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
  padding: var(--aud-space-3);
  background: var(--aud-color-bg-alt);
  border: none;
  border-radius: var(--aud-radius-sm);
  width: 100%;
  font-family: inherit;
  font-weight: 600;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
  cursor: pointer;
  text-align: left;
}
@media (hover: hover) {
  .aud-pagerail__switcher-toggle:hover {
    background: var(--aud-color-rule);
  }
}
.aud-pagerail__switcher-toggle:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
}
.aud-pagerail__switcher-toggle svg {
  color: var(--aud-color-text-subtle);
  flex: 0 0 auto;
}
.aud-pagerail__switcher-label {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.aud-pagerail__switcher-chevron {
  transition: transform 120ms ease;
}
.aud-pagerail__switcher-toggle[aria-expanded="true"] .aud-pagerail__switcher-chevron {
  transform: rotate(180deg);
}

/* Dropdown menu - styled like the header dropdown but full-width to
   the rail. Positioned absolutely below the toggle so it overlays
   content beneath, not pushing it down (which would shift the page
   rail and feel jumpy). */
.aud-pagerail__switcher-menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  margin: 0;
  padding: var(--aud-space-1) 0;
  list-style: none;
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  z-index: 100;
  max-height: 360px;
  overflow-y: auto;
}
.aud-pagerail__switcher-menu > li { margin: 0; padding: 0; list-style: none; }
.aud-pagerail__switcher-menu > li::before { content: none; }

.aud-pagerail__switcher-link {
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
  padding: var(--aud-space-2) var(--aud-space-3);
  font-size: var(--aud-fs-3);
  font-weight: 400;
  color: var(--aud-color-text);
  text-decoration: none;
  white-space: nowrap;
}
@media (hover: hover) {
  .aud-pagerail__switcher-link:hover {
    background: var(--aud-color-bg-alt);
    color: var(--aud-color-text);
    text-decoration: none;
  }
}
.aud-pagerail__switcher-link:focus-visible {
  background: var(--aud-color-bg-alt);
  outline: 2px solid var(--aud-color-link);
  outline-offset: -2px;
}
.aud-pagerail__switcher-item.is-current .aud-pagerail__switcher-link {
  background: rgba(0, 102, 214, 0.08);   /* tint of --aud-color-link */
  color: var(--aud-color-link);
  font-weight: 600;
}
.aud-pagerail__switcher-item.is-current .aud-pagerail__switcher-link svg {
  color: var(--aud-color-link);
  flex: 0 0 auto;
}
.aud-pagerail__switcher-spacer {
  display: inline-block;
  width: 12px;            /* same width as the check icon so labels align */
  flex: 0 0 auto;
}

.aud-pagerail__expand-all {
  background: none;
  border: none;
  color: var(--aud-color-link);
  font-size: var(--aud-fs-2);
  cursor: pointer;
  padding: var(--aud-space-2) var(--aud-space-3);
  margin-bottom: var(--aud-space-2);
}
.aud-pagerail__expand-all:hover { text-decoration: underline; }

/* Flat nested list, no chrome */
.aud-pagerail__list {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: var(--aud-fs-3);
}
.aud-pagerail__list li { margin: 0; }

.aud-pagerail__group {
  border-top: 0.5px solid var(--aud-color-rule);
  padding: var(--aud-space-1) 0 var(--aud-space-2);
}
.aud-pagerail__group:first-child { border-top: none; padding-top: 0; }
.aud-pagerail__group:last-child { border-bottom: none; }

/* Section toggle — reads as a heading via weight contrast (600 bold vs 400
   regular articles below it). Same font-size as articles so children never
   look bigger than parents; the bold weight + slightly darker color does
   the hierarchy work. */
.aud-pagerail__toggle {
  width: 100%;
  background: none;
  border: none;
  padding: var(--aud-space-3) var(--aud-space-3) var(--aud-space-2);
  text-align: left;
  font-size: 13px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--aud-color-text);
  font-weight: 600;
  cursor: pointer;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: inherit;
  line-height: 1.35;
}
.aud-pagerail__toggle:hover { color: var(--aud-color-link); }

/* Reset old ::before chevron and place a new right-aligned one */
.aud-pagerail__toggle::before { content: none; }
.aud-pagerail__toggle::after {
  content: "+";
  font-weight: 400;
  color: var(--aud-color-text-subtle);
  font-size: 14px;
  margin-left: var(--aud-space-2);
  transition: transform 120ms;
}
.aud-pagerail__toggle[aria-expanded="true"]::after { content: "−"; }

/* Article sublist — visibly indented under the section label */
.aud-pagerail__sublist {
  list-style: none;
  padding: 0 0 var(--aud-space-2);
  margin: 0;
}
.aud-pagerail__item a {
  display: block;
  padding: var(--aud-space-2) var(--aud-space-3) var(--aud-space-2) 28px;
  color: var(--aud-color-text-muted);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.45;
  border-left: 2px solid transparent;
  transition: background-color 100ms, color 100ms, border-color 100ms;
}
.aud-pagerail__item a:hover {
  color: var(--aud-color-link);
  background: var(--aud-color-bg-alt);
  text-decoration: none;
}
.aud-pagerail__item--current a {
  color: var(--aud-color-link);
  font-weight: 500;
  background: var(--aud-color-bg-alt);
  border-left-color: var(--aud-color-link);
}

/* Main column */
.aud-page__main {
  min-width: 0;
  max-width: 940px;
}

/* v5.9.32: list-style pages (My Requests, Contributions, User Profile,
   Subscriptions) use the .aud-page--no-rail modifier and benefit from
   full available width — tables, stat grids, and filter toolbars look
   awkward when capped at the article reading width of 940px. The page
   itself stays capped at --aud-content-max (1600px) for outer
   centering on big monitors. */
.aud-page--no-rail .aud-page__main {
  max-width: none;
}

/* Breadcrumbs */
.aud-page__main .breadcrumbs,
.aud-search-page__main .breadcrumbs,
.aud-breadcrumbs,
.aud-crumbs__list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--aud-space-2);
  padding: 0;
  margin: 0 0 var(--aud-space-4);
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
}
.aud-page__main .breadcrumbs li,
.aud-search-page__main .breadcrumbs li,
.aud-breadcrumbs li,
.aud-crumbs__list li { margin: 0; }
.aud-page__main .breadcrumbs li::after,
.aud-search-page__main .breadcrumbs li::after,
.aud-breadcrumbs li::after,
.aud-crumbs__list li::after {
  content: "›";
  margin-left: var(--aud-space-2);
  color: var(--aud-color-text-subtle);
}
.aud-page__main .breadcrumbs li:last-child::after,
.aud-search-page__main .breadcrumbs li:last-child::after,
.aud-breadcrumbs li:last-child::after,
.aud-crumbs__list li:last-child::after { content: ""; }
.aud-page__main .breadcrumbs a,
.aud-search-page__main .breadcrumbs a,
.aud-breadcrumbs a,
.aud-crumbs__list a { color: var(--aud-color-link); }
/* Current page crumb (non-link span) — darker text, no underline */
.aud-crumbs__list [aria-current="page"] {
  color: var(--aud-color-text);
  font-weight: 500;
}

/* Article header — title, version pill, updated, read-time */
.aud-article__header {
  margin-bottom: var(--aud-space-5);
}
.aud-article__title {
  font-size: 28px;
  font-weight: 600;
  margin: 0 0 var(--aud-space-3);
}
.aud-article__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--aud-space-3);
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
  padding-bottom: var(--aud-space-4);
  border-bottom: 1px solid var(--aud-color-rule);
}

/* Article attachments — rendered below body, above prev/next pagination.
   Visual language intentionally mirrors .aud-ticket__attachment so the
   two surfaces feel consistent. */
.aud-article__attachments-section {
  margin: var(--aud-space-5) 0 var(--aud-space-4);
  padding-top: var(--aud-space-4);
  border-top: 1px solid var(--aud-color-rule);
}
.aud-article__attachments-heading {
  font-size: var(--aud-fs-3);
  font-weight: 600;
  margin: 0 0 var(--aud-space-2);
  color: var(--aud-color-text);
}
.aud-article__attachments {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--aud-space-1);
}
.aud-article__attachment {
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
  padding: 8px 12px;
  background: var(--aud-color-bg-alt);
  border-radius: var(--aud-radius-sm, 6px);
  font-size: var(--aud-fs-2);
  flex-wrap: wrap;
}
.aud-article__attachment svg {
  flex: 0 0 16px;
  color: var(--aud-color-text-subtle);
}
.aud-article__attachment-name {
  color: var(--aud-color-link);
  text-decoration: none;
  font-weight: 500;
  word-break: break-all;
}
@media (hover: hover) {
  .aud-article__attachment-name:hover { text-decoration: underline; }
}
.aud-article__attachment-size {
  color: var(--aud-color-text-muted);
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}
/* Byline — author avatar + "Written by [Name]" link */
.aud-byline {
  display: inline-flex;
  align-items: center;
  gap: var(--aud-space-2);
  text-decoration: none;
  color: var(--aud-color-text);
}
.aud-byline:hover { text-decoration: none; }
.aud-byline:hover .aud-byline__name { text-decoration: underline; }
.aud-byline__avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 auto;
  background: var(--aud-color-bg-alt);
  border: 1px solid var(--aud-color-rule);
}
.aud-byline__text {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.2;
}
.aud-byline__by {
  font-size: 11px;
  color: var(--aud-color-text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.aud-byline__name {
  font-size: var(--aud-fs-3);
  font-weight: 500;
  color: var(--aud-color-text);
}

.aud-meta-sep { color: var(--aud-color-rule-strong); }
.aud-meta-date { color: var(--aud-color-text-muted); }
.aud-meta-readtime { color: var(--aud-color-text-subtle); }

/* Download PDF button — icon-only, sits in the article meta row next to
   "5 min read". Compact square button; tooltip on hover (via title attr)
   and aria-label for screen readers. Matches the pattern used by
   GitHub Docs and Vercel Docs. Hidden in print output. */
.aud-pdf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  margin-left: 4px;
  color: var(--aud-color-text-muted);
  background: transparent;
  border: 1px solid var(--aud-color-rule);
  border-radius: 4px;
  cursor: pointer;
  transition: color 120ms, border-color 120ms, background 120ms;
}
.aud-pdf-btn:hover {
  color: var(--aud-color-link);
  border-color: var(--aud-color-link);
  background: var(--aud-color-bg-alt);
}
.aud-pdf-btn:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 2px;
}
.aud-pdf-btn svg { flex-shrink: 0; }
.aud-meta-sep--pdf { margin: 0 4px; }

/* Prose */
.aud-prose {
  max-width: var(--aud-prose-max);
  font-size: var(--aud-fs-4);
  line-height: var(--aud-lh-prose);
  color: var(--aud-color-text);
}
.aud-prose h2 {
  font-size: var(--aud-fs-7);
  margin-top: var(--aud-space-7);
  margin-bottom: var(--aud-space-3);
}
.aud-prose h2:first-child { margin-top: var(--aud-space-4); }
.aud-prose h3 {
  font-size: var(--aud-fs-6);
  margin-top: var(--aud-space-5);
  margin-bottom: var(--aud-space-2);
}

/* hr-followed-by-heading collapse. When an author puts <hr> immediately
   before an H2 or H3 (very common "section break + new section" pattern),
   the heading's full top-margin would stack with the hr's own margins and
   create excessive dead space. This rule collapses the heading's top
   margin to a small visual gap. Placed AFTER the base .aud-prose h2/h3
   rules so it wins by source order — no !important required. */
.aud-prose hr + h2,
.aud-prose hr + h3 {
  margin-top: var(--aud-space-3);
  padding-top: 0;
  border-top: none;
}

/* ----------------------------------------------------------------------------
   Defensive: collapse paragraphs that are truly empty or contain only a
   <br>. The Zendesk WYSIWYG editor leaves these behind when authors hit
   Enter accidentally or paste from Word/Google Docs. Without this rule
   they create surprise gaps in the rendered article (most commonly between
   a heading and the first list item below it).

   This rule deliberately does NOT target paragraphs containing actual text
   content (even just a stray period or whitespace character) — those are
   intentional content the author typed and should be fixed in the article
   itself, not silently hidden by CSS.
---------------------------------------------------------------------------- */
.aud-prose p:empty,
.aud-prose p:has(> br:only-child) {
  display: none;
}

/* ----------------------------------------------------------------------------
   Defensive: Zendesk's content "layout" feature wraps content in
   <div data-layout="..."> elements that, without their accompanying
   stylesheet, can cause severe overlap between siblings (table content
   stacking on top of subsequent paragraphs, callouts overlapping headings,
   etc.). The Zendesk layout CSS isn't loaded reliably in our help-center
   context, so we force these containers to behave like normal block flow.

   We reset the wrapper itself but DON'T force display/width on its
   children — we let each child element use its own native rendering
   (tables stay tables, images stay images). The key fix is removing any
   absolute positioning, floats, or constrained heights on the wrapper. */
.aud-prose div[data-layout],
.aud-prose [data-layout-section],
.aud-prose [data-layout-column] {
  display: block;
  width: 100%;
  position: static;
  float: none;
  clear: both;
  height: auto;
  min-height: 0;
  max-height: none;
  overflow: visible;
}
/* ============================================================================
   Figure / table / caption spacing — UNIFIED RHYTHM (v5.9.2)

   Authors mix three patterns in the WYSIWYG editor and v5.8 had a different
   rule for each, producing inconsistent gaps. The unified system below uses
   ONE outer rhythm (24px above + below any visual block) and ONE caption gap
   (8px) regardless of pattern.

   Patterns handled:
   1. Proper figure:    <figure><img/></figure>
   2. Loose image:      <p><img></p>
   3. Caption + table:  <p><strong>Table N. Title</strong></p> <table>...
   4. Caption + figure: <p><strong>Figure N. Title</strong></p> <figure>...
   5. Figure + caption: <figure>...</figure> <p><strong>Figure N. Title</strong></p>
   6. Wrapped table:    <p><strong>Table N…</strong></p> <div data-layout><div><figure.wysiwyg-table>

   Spacing target:
     [content paragraph]
       ↕ 24px              ← outer rhythm (figure/table block separator)
     [caption (above)]
       ↕ 8px               ← inner caption gap
     [figure / table]
       ↕ 8px               ← inner caption gap
     [caption (below)]
       ↕ 24px              ← outer rhythm
     [next content]

   Implementation strategy:
   - Every figure / table / loose image gets a consistent 24px (`--aud-space-5`)
     outer margin top + bottom by default.
   - When a bold-paragraph caption immediately precedes a visual block, both
     elements collapse their adjacent margins to 0, and the visual block gets
     8px (`--aud-space-2`) padding-top to create the inner gap. This keeps
     the caption-and-block reading as one tight unit.
   - When a paragraph immediately follows a figure (figure-then-caption
     pattern), the figure's bottom margin shrinks to 0 and the paragraph
     gets 8px top margin.
   - !important is used only where it has to compete with the WYSIWYG
     editor's inline `style="..."` injections — those win over class
     selectors otherwise.
============================================================================ */

/* --- 1. Outer rhythm: 24px above and below the OUTERMOST visual block ---
   "Visual block" = <figure>, <div data-layout>, <table> direct child of
   prose, or <p> containing only an image. Anything nested inside one of
   these is structural and gets margin: 0 from Rule 1a below.

   IMPORTANT: this selector MUST use `div[data-layout]` and NOT `[data-layout]`.
   The Confluence-style WYSIWYG editor puts `data-layout="default"` on the
   <table> element itself (not just on wrapping divs). Using the broad
   `[data-layout]` selector caused Rule 1 to also match <table data-layout>,
   stacking 24px on the table on top of the 24px on its wrapping figure.
   That was the v5.9.0–v5.9.5 stacking bug. */
.aud-prose figure,
.aud-prose div[data-layout],
.aud-prose > table,
.aud-prose p:has(> img:only-child) {
  margin-top: var(--aud-space-5);
  margin-bottom: var(--aud-space-5);
}

/* --- 1a. Reset every nested visual block to zero margin -----------------
   ONE PRINCIPLE: only the outermost visual block carries outer rhythm.
   Anything nested inside any visual block is structural and contributes
   no margin. This rule fires for all six WYSIWYG patterns the editor
   produces (single, double-nested data-layout, figure-in-figure, etc.)
   so spacing is identical regardless of how the author wrapped the
   content. */
.aud-prose figure figure,
.aud-prose figure table,
.aud-prose figure div[data-layout],
.aud-prose figure p:has(> img:only-child),
.aud-prose div[data-layout] figure,
.aud-prose div[data-layout] table,
.aud-prose div[data-layout] div[data-layout],
.aud-prose div[data-layout] p:has(> img:only-child),
.aud-prose div[data-layout] > div {
  margin: 0 !important;
}

/* --- 1b. Author-typed whitespace paragraphs are honored ------------------
   Earlier theme versions (v5.9.0–v5.9.6) hid `<p></p>` and `<p><br></p>`
   to fix the WYSIWYG editor injecting accidental whitespace. The
   side-effect was that authors who typed Enter twice in the editor to
   add deliberate spacing between elements saw the spacing stripped. As
   of v5.9.7 we honor whatever the author put in the editor — empty
   paragraphs render with default <p> margins and add the gap the
   author intended. The next rule (1c) handles the special case of
   visually-hidden anchor paragraphs that the renderer adds without
   author input. */

/* --- 1c. Collapse visually-hidden heading-anchor paragraphs --------------
   Confluence-imported articles place `<p><span data-testid=
   "visually-hidden-heading-anchor"></span></p>` between sections as
   accessibility landmarks. The empty <p> wrapper takes 16-32px of vertical
   space between every section in the article — a major source of the
   "spacing varies between articles" bug, since not every article has these
   in the same places.

   We can't display:none the <p> (that would remove the inner span from
   the accessibility tree). Instead, collapse the <p>'s box to zero while
   keeping the span reachable to assistive technology. */
.aud-prose p:has(> [data-testid="visually-hidden-heading-anchor"]:only-child) {
  margin: 0 !important;
  padding: 0 !important;
  height: 0;
  overflow: visible;
  font-size: 0;
  line-height: 0;
}

/* --- 1d. Sibling visual blocks inside one wrapper need gaps between them
   (v5.9.7) --------------------------------------------------------------
   Authors sometimes put multiple visual blocks in ONE <div data-layout>
   wrapper (e.g., a table immediately followed by a screenshot+caption).
   Rule 1a zeroes the margins on those blocks because they're nested inside
   the data-layout, but that means consecutive blocks end up touching each
   other with no gap. Rule 1d adds the 24px outer rhythm BETWEEN siblings —
   only the first block has 0 against the wrapper's top edge; the second
   onwards gets 24px above. */
.aud-prose div[data-layout] figure + figure,
.aud-prose div[data-layout] figure + table,
.aud-prose div[data-layout] figure + p:has(> img:only-child),
.aud-prose div[data-layout] table + figure,
.aud-prose div[data-layout] table + table,
.aud-prose div[data-layout] table + p:has(> img:only-child),
.aud-prose div[data-layout] p:has(> img:only-child) + figure,
.aud-prose div[data-layout] p:has(> img:only-child) + table,
.aud-prose div[data-layout] p:has(> img:only-child) + p:has(> img:only-child) {
  margin-top: var(--aud-space-5) !important;
}

/* --- 2. Image and figure layout (positioning, sizing) -------------------- */
.aud-prose img {
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-sm);
  /* Margins live on the wrapping figure/p, not the img itself, so spacing
     stays in one place. Loose <img> with no wrapper falls back to the base
     img margin below. */
}
.aud-prose > img {
  margin: var(--aud-space-5) 0;
}

.aud-prose figure {
  text-align: center;
  /* Force the figure to span the full content width. Zendesk's wysiwyg-image
     figure can default to shrink-to-fit, which leaves no horizontal space
     for text-align:center to actually center anything. */
  display: block;
  width: 100%;
}
.aud-prose figure img {
  margin: 0 auto;
  display: block;
  max-width: 100%;
  height: auto;
}

/* --- 3. Zendesk's data-layout / wysiwyg-table wrapper bug --------------- */
/* Zendesk's editor wraps tables in a buggy structure with inline
   `height: 1px` that collapses the figure box, causing subsequent content
   to render ON TOP OF the table. Override the inline height (it must be
   !important to beat inline styles) and reset width so the table can flow
   naturally. */
.aud-prose figure.wysiwyg-table {
  height: auto !important;
  width: 100% !important;
  max-width: 100%;
  display: block;
  overflow-x: auto; /* horizontal scroll for very wide tables on mobile */
}
.aud-prose figure.wysiwyg-table table {
  /* Let our scoped table styling control width instead of the editor's
     data-table-width / inline width. */
  width: 100% !important;
  max-width: 100%;
}
.aud-prose figure.wysiwyg-table-align-left { text-align: left; }
.aud-prose figure.wysiwyg-table-align-center { text-align: center; }
.aud-prose figure.wysiwyg-table-align-right { text-align: right; }

/* --- 4. Caption above visual block (the "Table N. Title" pattern) ------- */
/* When a bold paragraph (<p><strong>X</strong></p>) is immediately followed
   by a visual block, treat it as a caption: zero the gap between them,
   then insert a single 8px gap via padding-top on the visual block.
   Captions still keep their 24px outer rhythm above (separation from prior
   content). */
.aud-prose p:has(> strong):has(+ table),
.aud-prose p:has(> strong):has(+ div[data-layout]),
.aud-prose p:has(> strong):has(+ figure),
.aud-prose p:has(> strong):has(+ p:has(> img:only-child)) {
  margin-top: var(--aud-space-5);
  margin-bottom: 0;
}

/* The block immediately following the caption: zero its outer top margin,
   add 8px padding-top so the visible inner gap is consistent. */
.aud-prose p:has(> strong) + table,
.aud-prose p:has(> strong) + div[data-layout],
.aud-prose p:has(> strong) + figure,
.aud-prose p:has(> strong) + p:has(> img:only-child) {
  margin-top: 0 !important;
  padding-top: var(--aud-space-1) !important;
}

/* --- 5. Caption below visual block (the "Figure N. Title" pattern) -----
   When a paragraph immediately follows a figure or image, treat it as a
   caption below: shrink the figure's bottom margin to 0, give the caption
   8px top margin for the inner gap. Caption keeps its default 16px
   bottom margin (which margin-collapses with whatever follows).

   Pattern C handling: when an image is wrapped in <div data-layout>, the
   caption is the LAST CHILD of the wrapping div, not a sibling. The
   `figure + p` selector still fires for the figure-caption pair inside
   the data-layout, so the inner gap stays at 8px regardless of
   wrapping. */
.aud-prose figure:has(+ p),
.aud-prose p:has(> img:only-child):has(+ p) {
  margin-bottom: 0;
}
.aud-prose figure + p,
.aud-prose p:has(> img:only-child) + p {
  margin-top: var(--aud-space-2);
}

/* --- 6. Figcaption (proper <figure><figcaption> pattern) ---------------- */
.aud-prose figcaption,
.aud-prose .figure-caption {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
  text-align: center;
  font-style: italic;
  margin-top: var(--aud-space-2);
}

/* --- 7. Author alignment classes on inline images ----------------------- */
.aud-prose p.wysiwyg-text-align-center img,
.aud-prose .wysiwyg-text-align-center img {
  margin-left: auto !important;
  margin-right: auto !important;
  display: block;
}
.aud-prose p.wysiwyg-text-align-right img,
.aud-prose .wysiwyg-text-align-right img {
  margin-left: auto !important;
  margin-right: 0 !important;
  display: block;
}

/* ============================================================================
   When an author drags a column edge in the Zendesk WYSIWYG editor, the
   editor adds .wysiwyg-table-resized to the <table> AND writes pixel widths
   inline onto every <th>/<td> (e.g. style="width: 130px"). With width:100%
   on the table the browser stretches those pixel widths by ratio — so a
   130px / 260px split renders as 33% / 67% on desktop and ~35% / 65% on
   mobile. The author's editor-time guess gets baked into every viewport,
   regardless of viewport, regardless of label length.

   Two real problems this caused:
     - Short labels ("Payment No") wasted 33% of the table on desktop.
     - Short labels CROPPED on mobile when the resized width fell below the
       label's natural width (e.g. "Vendor Name" forced to two lines).

   Fix: switch resized tables to table-layout:auto so columns size from
   their content, neutralise the inline widths, and give the first column
   a sensible min/max band so it doesn't waste space or crush. */
.aud-prose figure.wysiwyg-table table.wysiwyg-table-resized {
  table-layout: auto !important;
}
.aud-prose figure.wysiwyg-table table.wysiwyg-table-resized th[style*="width"],
.aud-prose figure.wysiwyg-table table.wysiwyg-table-resized td[style*="width"],
.aud-prose figure.wysiwyg-table table.wysiwyg-table-resized th[width],
.aud-prose figure.wysiwyg-table table.wysiwyg-table-resized td[width] {
  width: auto !important;
}
.aud-prose figure.wysiwyg-table table.wysiwyg-table-resized th:first-child,
.aud-prose figure.wysiwyg-table table.wysiwyg-table-resized td:first-child {
  min-width: 140px;
  max-width: 240px;
}

/* When an author resizes an image in the editor, Zendesk wraps it in
   <figure class="wysiwyg-image wysiwyg-image-resized" style="width: NN%">.
   The figure has a percentage width (e.g., 65%) but no auto margin, so
   it sits left-anchored in the column instead of centered. This makes
   the image appear "left-aligned" even when the author intended center.

   We center the figure with auto margins. The base .aud-prose figure
   rule sets width: 100%, but figures with inline width: NN% will keep
   the inline value (inline beats class) and just use the auto margins. */
.aud-prose figure.wysiwyg-image,
.aud-prose figure.wysiwyg-image-resized {
  margin-left: auto !important;
  margin-right: auto !important;
}

.aud-prose div[data-layout] > div {
  display: block;
  width: 100%;
}

/* Zendesk WYSIWYG editor uses these classes when authors set alignment.
   Honor them so author intent (center, right) survives in the rendered
   article. The !important is needed because these paragraphs sometimes
   live inside Zendesk's <div data-layout> wrappers which can constrain
   the paragraph's effective width and prevent text-align from working. */
.aud-prose .wysiwyg-text-align-center {
  text-align: center !important;
  display: block;
  width: 100%;
}
.aud-prose .wysiwyg-text-align-right {
  text-align: right !important;
  display: block;
  width: 100%;
}
.aud-prose .wysiwyg-text-align-left {
  text-align: left !important;
  display: block;
  width: 100%;
}

/* Spacing for figures, images, captions is handled by the unified rhythm
   block earlier in this file (search "UNIFIED RHYTHM"). Don't add
   margin/padding rules for those elements here — keep all spacing in one
   place to avoid regressing back to the v5.8 inconsistency.  */

/* ----------------------------------------------------------------------------
   Article body tables — TRADITIONAL bordered style (v5.9.4).

   Every cell has a visible 1px border on all four sides. Outer table border
   and header divider are slightly stronger to bracket the table cleanly.
   Header keeps a subtle background tint so the title row reads as a
   different rank from data cells.

   Color hierarchy:
     - var(--aud-color-rule)         #e5e7eb  — light gray, body cell borders
     - var(--aud-color-rule-strong)  #cdd2d8  — medium gray, outer + header

   The Zendesk WYSIWYG editor often injects inline border="1" or
   style="border:..." on author-created tables. Inline attributes always beat
   CSS class selectors regardless of source order, which is why the rules
   below use !important — it's the only mechanism that overrides inline
   styles. Removing !important here will cause editor-injected styles to
   leak through.
---------------------------------------------------------------------------- */
.aud-prose table {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0;
  font-size: var(--aud-fs-3);
  border: 1px solid var(--aud-color-rule-strong) !important;
  /* No margin here — outer rhythm comes from the parent
     (figure / data-layout / .aud-prose > table from Rule 1). */
}
.aud-prose table[border] { border: 1px solid var(--aud-color-rule-strong) !important; }
.aud-prose table th,
.aud-prose table td {
  text-align: left;
  padding: 10px 14px;
  border: 1px solid var(--aud-color-rule) !important;
  vertical-align: top;
  line-height: 1.5;
}
.aud-prose table thead th,
.aud-prose table tr:first-child > th {
  font-weight: 600;
  color: var(--aud-color-text);
  background: var(--aud-color-bg-alt) !important;
  border: 1px solid var(--aud-color-rule-strong) !important;
  /* No font-size override — inherit the table's 15px so headers are not
     visually smaller than body cells. */
  letter-spacing: 0.01em;
}

/* Perimeter reinforcement (v5.9.5).
   With border-collapse: collapse, when a cell's border meets the table's
   outer border at the same 1px / solid spec, browsers fall back to color
   conflict resolution — and cells generally win over tables. That made the
   table's outer edge render at the lighter cell color (#e5e7eb) instead of
   the stronger outer color (#cdd2d8), so the bottom edge looked thinner /
   weaker than the row dividers. Forcing the outermost cells' edge color to
   the stronger gray makes the resolution come out the way we want. */
.aud-prose table tr:first-child > th,
.aud-prose table tr:first-child > td {
  border-top-color: var(--aud-color-rule-strong) !important;
}
.aud-prose table tr:last-child > td,
.aud-prose table tr:last-child > th {
  border-bottom-color: var(--aud-color-rule-strong) !important;
}
.aud-prose table tr > td:first-child,
.aud-prose table tr > th:first-child {
  border-left-color: var(--aud-color-rule-strong) !important;
}
.aud-prose table tr > td:last-child,
.aud-prose table tr > th:last-child {
  border-right-color: var(--aud-color-rule-strong) !important;
}

/* Hide truly-empty tables that the WYSIWYG editor sometimes leaves behind.
   With v5.9.4's border style, an empty <table> renders as a stray bordered
   rectangle. JS cleanup in script.js handles tables with empty rows; this
   covers the literal :empty case synchronously with no flash. */
.aud-prose table:empty {
  display: none;
}
/* Lists inside cells should hug their cell, not float far below. */
.aud-prose table td ul,
.aud-prose table td ol {
  margin: 4px 0 0;
  padding-left: 18px;
}
.aud-prose table td li {
  margin-bottom: 2px;
  line-height: 1.45;
}

/* ----------------------------------------------------------------------------
   Paragraphs inside table cells inherit the article's default <p> margins
   (~16px top + 16px bottom), which collapse to a 16px gap between sibling
   paragraphs. Inside one cell that gap reads as two unrelated answers
   rather than one continuous explanation (e.g. the Status row in the
   Payments fields article had "Current state of the payment." floating
   16px above "Possible values include:"). Tighten to 6px so multi-paragraph
   cells read as one block. */
.aud-prose table td p,
.aud-prose table th p {
  margin: 0;
}
.aud-prose table td p + p,
.aud-prose table th p + p {
  margin-top: 6px;
}
.aud-prose table td p + ul,
.aud-prose table td p + ol {
  margin-top: 4px;
}

/* Table caption pattern: a paragraph immediately preceding a table acts
   as the table's label (e.g., "Table 2. Common Payments Filter Fields").
   See the UNIFIED RHYTHM block earlier in this file for caption / figure /
   table spacing — kept in one place to avoid the v5.8 inconsistency where
   different patterns produced different gaps. */

.aud-prose .table-caption {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
  text-align: right;
  font-style: italic;
  margin-top: var(--aud-space-1);
}

/* Callouts — toned-down colored variants */
.aud-prose blockquote {
  margin: var(--aud-space-4) 0;
  padding: var(--aud-space-3) var(--aud-space-4);
  border-left: 2px solid var(--aud-color-note-bar);
  background: var(--aud-color-note-bg);
  color: var(--aud-color-text);
}
.aud-prose blockquote p { margin-bottom: 0; line-height: var(--aud-lh-prose); }
.aud-prose blockquote.aud-callout--tip {
  border-left-color: var(--aud-color-tip-bar);
  background: var(--aud-color-tip-bg);
}
.aud-prose blockquote.aud-callout--important {
  border-left-color: var(--aud-color-important-bar);
  background: var(--aud-color-important-bg);
}
.aud-prose blockquote.aud-callout--warning {
  border-left-color: var(--aud-color-important-bar);
  background: var(--aud-color-important-bg);
}
.aud-prose blockquote em strong:first-child,
.aud-prose blockquote strong:first-child {
  font-style: normal;
  color: var(--aud-color-text);
  font-weight: 600;
}

/* Inline code & pre inside prose */
.aud-prose code { font-size: 0.9em; }

/* Anchor links on headings */
.aud-anchor {
  margin-left: var(--aud-space-2);
  color: var(--aud-color-text-subtle);
  opacity: 0;
  transition: opacity 120ms;
  font-weight: 400;
  text-decoration: none;
  font-size: 0.85em;
}
.aud-prose h2:hover .aud-anchor,
.aud-prose h3:hover .aud-anchor,
.aud-prose h4:hover .aud-anchor { opacity: 1; }

/* Code-block copy button */
.aud-code-wrap { position: relative; }
.aud-code-copy {
  position: absolute;
  top: 6px;
  right: 6px;
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  padding: 2px 8px;
  font-size: var(--aud-fs-1);
  color: var(--aud-color-text-muted);
  cursor: pointer;
  border-radius: var(--aud-radius-sm);
}
.aud-code-copy:hover { color: var(--aud-color-link); border-color: var(--aud-color-link); }

/* Was this topic helpful — bottom-of-article trigger button */
.aud-feedback-trigger {
  margin-top: var(--aud-space-7);
  padding-top: var(--aud-space-5);
  border-top: 1px solid var(--aud-color-rule);
  text-align: center;
}
.aud-feedback-trigger__btn {
  background: none;
  border: none;
  padding: var(--aud-space-2) var(--aud-space-3);
  display: inline-flex;
  align-items: center;
  gap: var(--aud-space-2);
  font-size: var(--aud-fs-3);
  font-weight: 600;
  color: var(--aud-color-text);
  cursor: pointer;
}
.aud-feedback-trigger__btn:hover { color: var(--aud-color-link); }
.aud-feedback-trigger__btn svg { color: var(--aud-color-text-subtle); }

/* Feedback modal */
.aud-feedback-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--aud-space-4);
}
.aud-feedback-modal[hidden] { display: none; }
.aud-feedback-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
}
.aud-feedback-modal__panel {
  position: relative;
  background: #fff;
  border-radius: var(--aud-radius-md);
  width: 100%;
  max-width: 540px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  max-height: 90vh;
}
.aud-feedback-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--aud-space-4) var(--aud-space-5) var(--aud-space-3);
  border-bottom: none;
}
.aud-feedback-modal__title {
  margin: 0;
  font-size: var(--aud-fs-6);
  font-weight: 600;
}
.aud-feedback-modal__close {
  background: none;
  border: none;
  color: var(--aud-color-text-subtle);
  cursor: pointer;
  padding: 4px;
  border-radius: var(--aud-radius-sm);
}
.aud-feedback-modal__close:hover { color: var(--aud-color-text); background: var(--aud-color-bg-alt); }
.aud-feedback-modal__body {
  padding: 0 var(--aud-space-5) var(--aud-space-4);
  overflow-y: auto;
}
.aud-feedback-modal__rate-label,
.aud-feedback-modal__review-label {
  display: block;
  font-size: var(--aud-fs-3);
  font-weight: 600;
  margin-bottom: var(--aud-space-2);
  color: var(--aud-color-text);
}
.aud-feedback-modal__review-label {
  margin-top: var(--aud-space-5);
}
.aud-feedback-modal__buttons {
  display: inline-flex;
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: 24px;
  overflow: hidden;
  margin-bottom: 4px;
}
.aud-feedback-vote {
  background: #fff;
  border: none;
  padding: 8px var(--aud-space-4);
  font-size: var(--aud-fs-3);
  font-weight: 600;
  color: var(--aud-color-text);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: inherit;
}
.aud-feedback-vote + .aud-feedback-vote { border-left: 1px solid var(--aud-color-rule-strong); }
.aud-feedback-vote svg { color: var(--aud-color-text-subtle); }
.aud-feedback-vote:hover { background: var(--aud-color-bg-alt); }
.aud-feedback-vote.is-selected {
  background: var(--aud-color-topbar-utility-bg);
  color: #fff;
}
.aud-feedback-vote.is-selected svg { color: #fff; }
.aud-feedback-modal__rated {
  margin: 4px 0 0;
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
}
.aud-feedback-modal__textarea {
  width: 100%;
  min-height: 100px;
  padding: var(--aud-space-3);
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: var(--aud-radius-md);
  font-family: inherit;
  font-size: var(--aud-fs-3);
  resize: vertical;
}
.aud-feedback-modal__textarea:focus {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
  border-color: transparent;
}

/* Optional email field shown to anonymous users below the textarea. */
.aud-feedback-modal__email-label {
  display: block;
  margin: var(--aud-space-3) 0 var(--aud-space-2);
  font-weight: 600;
  font-size: var(--aud-fs-3);
}
.aud-feedback-modal__email-label[hidden] { display: none; }
.aud-feedback-modal__email-hint {
  margin-left: 6px;
  font-weight: 400;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-2);
}
.aud-feedback-modal__email {
  width: 100%;
  padding: var(--aud-space-3);
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: var(--aud-radius-md);
  font-family: inherit;
  font-size: var(--aud-fs-3);
  box-sizing: border-box;
}
.aud-feedback-modal__email:focus {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 1px;
  border-color: transparent;
}
.aud-feedback-modal__email[hidden] { display: none; }
.aud-feedback-modal__success,
.aud-feedback-modal__error {
  margin: var(--aud-space-3) 0 0;
  font-size: var(--aud-fs-3);
}
.aud-feedback-modal__success { color: #2d7a3d; }
.aud-feedback-modal__error { color: #c0392b; }
.aud-feedback-modal__footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--aud-space-2);
  padding: var(--aud-space-3) var(--aud-space-5) var(--aud-space-4);
  border-top: 1px solid var(--aud-color-rule);
}
.aud-feedback-modal__footer .aud-btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* ----------------------------------------------------------------------------
   Category & Section pages — flat list
---------------------------------------------------------------------------- */
.aud-cat-header {
  margin-bottom: var(--aud-space-5);
  padding-bottom: var(--aud-space-4);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-cat-header h1 {
  font-size: 28px;
  margin: 0 0 var(--aud-space-2);
}
.aud-cat-header p {
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-4);
  margin: 0;
  max-width: 700px;
}

.aud-sec-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.aud-sec-list li { margin: 0; }
.aud-sec-row {
  padding: var(--aud-space-4) 0;
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-sec-row__title {
  font-size: var(--aud-fs-6);
  font-weight: 600;
  margin: 0 0 4px;
}
.aud-sec-row__title a { color: var(--aud-color-link); }
.aud-sec-row__meta {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
  display: flex;
  gap: var(--aud-space-3);
  flex-wrap: wrap;
}
.aud-sec-row__desc {
  margin: 4px 0 0;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-3);
  max-width: 700px;
}

.aud-article-row {
  padding: var(--aud-space-3) 0;
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-article-row__title {
  font-size: var(--aud-fs-5);
  font-weight: 500;
  margin: 0 0 2px;
}
.aud-article-row__title a { color: var(--aud-color-link); }
.aud-article-row__meta {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
}

/* ----------------------------------------------------------------------------
   Search results
---------------------------------------------------------------------------- */
.aud-search-page {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-5) var(--aud-space-5) var(--aud-space-8);
  display: grid;
  grid-template-columns: var(--aud-rail-w) 1fr;
  gap: var(--aud-space-7);
}
.aud-search-page__main { min-width: 0; }
.aud-search-page__refine {
  border-right: 1px solid var(--aud-color-rule);
  padding-right: var(--aud-space-5);
  font-size: var(--aud-fs-3);
}

/* Refine sidebar styles consolidated below in the v5.9.14 design refresh
   block — using single-class selectors so they don't lose to descendant
   selectors elsewhere in the cascade. */

/* Search page header */
.aud-search-page__header {
  margin-bottom: var(--aud-space-5);
  padding-bottom: var(--aud-space-4);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-search-page__title {
  font-size: var(--aud-fs-7);
  margin: 0 0 var(--aud-space-2);
}
.aud-search-page__meta {
  color: var(--aud-color-text-muted);
  margin: 0;
  font-size: var(--aud-fs-3);
}
.aud-search-page__query {
  color: var(--aud-color-text);
}

/* ============================================================================
   Search page — v5.9.14 design refresh

   Goals:
     • Promote the search input into the page itself (was only top-right,
       too small for a refine action)
     • Result cards instead of plain text rows — clearer scan affordance,
       hover lift, "Read article →" cue
     • Refine sidebar: cleaner spacing, count chip on the right, active
       state via filled pill
     • Quick Overview block: more visual weight, clearer hierarchy
     • Pagination: styled buttons instead of raw text links
============================================================================ */

/* --- Results column: card layout ----------------------------------------- */
.aud-results {
  list-style: none;
  margin: 0;
  padding: 0;
}
.aud-result {
  margin: 0 0 var(--aud-space-3);
  padding: 0;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}
.aud-result:hover {
  border-color: var(--aud-color-link);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transform: translateY(-1px);
}
.aud-result__link {
  display: block;
  padding: var(--aud-space-4) var(--aud-space-5);
  color: inherit;
  text-decoration: none;
  position: relative;
}
.aud-result__link:hover,
.aud-result__link:focus-visible {
  text-decoration: none;
  outline: none;
}
.aud-result__link:focus-visible {
  box-shadow: inset 0 0 0 2px var(--aud-color-link);
  border-radius: var(--aud-radius-md);
}
.aud-result__title {
  font-size: var(--aud-fs-5);
  font-weight: 600;
  margin: 0 0 var(--aud-space-2);
  color: var(--aud-color-link);
  line-height: 1.35;
}
.aud-result__link:hover .aud-result__title {
  text-decoration: underline;
}
.aud-result__text {
  margin: 0;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-3);
  line-height: var(--aud-lh-prose);
  /* Cap snippet at 2 lines to keep result cards consistent height —
     long snippets pushed result count below the fold. */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.aud-result__cta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: var(--aud-space-3);
  font-size: var(--aud-fs-2);
  font-weight: 500;
  color: var(--aud-color-link);
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.aud-result__link:hover .aud-result__cta,
.aud-result__link:focus-visible .aud-result__cta {
  opacity: 1;
  transform: translateX(0);
}
/* Search-term highlight (client-side <mark> wrapping). The default <mark>
   yellow background is too loud on a documentation surface — use a soft
   tint of the brand link color so highlights feel like UI affordance, not
   construction tape. */
.aud-result__highlight {
  background: rgba(0, 102, 214, 0.12);
  color: inherit;
  padding: 0 1px;
  border-radius: 2px;
  font-style: normal; /* Override Zendesk's default italic on <em> matches */
}

/* --- Featured excerpt block (v5.9.16) ----------------------------------
   Sits ABOVE the Quick Overview. Reads the first paragraph from the top
   result's actual article body (via Zendesk API). Deterministic content
   — no AI, no synthesis, just a verbatim excerpt grounded in a single
   named article so users get immediate context. Design weight is higher
   than the Quick Overview because this is the most useful element on
   the page for understanding what the docs actually say about the term.
*/
.aud-search-featured {
  margin: var(--aud-space-2) 0 var(--aud-space-3);
  padding: var(--aud-space-5) var(--aud-space-5) var(--aud-space-4);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-left: 4px solid var(--aud-color-link);
  border-radius: var(--aud-radius-md);
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.aud-search-featured[hidden] { display: none; }
.aud-search-featured__header {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: var(--aud-space-2);
  margin-bottom: var(--aud-space-2);
}
.aud-search-featured__label {
  font-size: var(--aud-fs-1);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--aud-color-link);
}
.aud-search-featured__source {
  font-size: var(--aud-fs-3);
  font-weight: 500;
  color: var(--aud-color-text);
  text-decoration: none;
}
.aud-search-featured__source:hover {
  color: var(--aud-color-link);
  text-decoration: underline;
}
.aud-search-featured__source::before {
  content: "from ";
  color: var(--aud-color-text-muted);
  font-weight: 400;
}
.aud-search-featured__excerpt {
  margin: 0 0 var(--aud-space-3);
  font-size: var(--aud-fs-3);
  line-height: 1.6;
  color: var(--aud-color-text);
}
.aud-search-featured__cta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: var(--aud-fs-2);
  font-weight: 500;
  color: var(--aud-color-link);
  text-decoration: none;
}
.aud-search-featured__cta:hover {
  text-decoration: underline;
}


.aud-search-page__form {
  position: relative;
  display: block;
  margin: var(--aud-space-3) 0 var(--aud-space-3);
  max-width: 640px;
}
.aud-search-page__form-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--aud-color-text-subtle);
  pointer-events: none;
  transition: color 0.15s ease;
}
.aud-search-page__form:focus-within .aud-search-page__form-icon {
  color: var(--aud-color-link);
}
.aud-search-page__form-input {
  width: 100%;
  padding: 12px 16px 12px 48px;
  font-size: var(--aud-fs-4);
  font-family: inherit;
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: var(--aud-radius-md);
  background: #fff;
  color: var(--aud-color-text);
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.aud-search-page__form-input::-webkit-search-decoration,
.aud-search-page__form-input::-webkit-search-cancel-button,
.aud-search-page__form-input::-webkit-search-results-button,
.aud-search-page__form-input::-webkit-search-results-decoration {
  -webkit-appearance: none;
}
.aud-search-page__form-input:focus {
  outline: none;
  border-color: var(--aud-color-link);
  box-shadow: 0 0 0 3px rgba(0, 102, 214, 0.15);
}

/* --- Refine sidebar ----------------------------------------------------- */
.aud-results__refine-group h3 {
  font-size: var(--aud-fs-1);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--aud-color-text-muted);
  margin: 0 0 var(--aud-space-2);
  padding: 0 var(--aud-space-2);
}
.aud-results__refine-group ul {
  list-style: none;
  margin: 0 0 var(--aud-space-5);
  padding: 0;
}
.aud-results__refine-group li {
  margin: 1px 0;
}
.aud-results__refine-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--aud-space-2);
  padding: 6px var(--aud-space-2);
  border-radius: var(--aud-radius-sm);
  color: var(--aud-color-text);
  text-decoration: none;
  font-size: var(--aud-fs-3);
  line-height: 1.3;
  transition: background 0.12s ease, color 0.12s ease;
}
.aud-results__refine-link:hover {
  background: var(--aud-color-bg-alt);
  text-decoration: none;
}
.aud-results__refine-link.is-selected {
  background: rgba(0, 102, 214, 0.1);
  color: var(--aud-color-link);
  font-weight: 500;
}
.aud-results__refine-name {
  flex: 1;
  min-width: 0;
}
.aud-results__refine-count {
  flex-shrink: 0;
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
  font-variant-numeric: tabular-nums;
}
.aud-results__refine-link.is-selected .aud-results__refine-count {
  color: var(--aud-color-link);
}

/* --- Quick Overview ----------------------------------------------------- */
.aud-search-summary {
  margin: var(--aud-space-2) 0 var(--aud-space-4);
  padding: var(--aud-space-4) var(--aud-space-5);
  background: linear-gradient(180deg, rgba(0,102,214,0.03) 0%, rgba(0,102,214,0.01) 100%);
  border: 1px solid var(--aud-color-rule);
  border-left: 3px solid var(--aud-color-link);
  border-radius: var(--aud-radius-md);
}
.aud-search-summary__header {
  margin-bottom: var(--aud-space-2);
}
.aud-search-summary__label {
  font-size: var(--aud-fs-1);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--aud-color-link);
}
.aud-search-summary__line {
  margin: 0;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
  line-height: 1.5;
}
.aud-search-summary__line strong {
  font-weight: 600;
  color: var(--aud-color-text);
}
.aud-search-summary__top {
  margin-top: var(--aud-space-3);
  padding-top: var(--aud-space-3);
  border-top: 1px solid var(--aud-color-rule);
}
.aud-search-summary__top-label {
  display: block;
  font-size: var(--aud-fs-2);
  font-weight: 500;
  color: var(--aud-color-text-muted);
  margin-bottom: var(--aud-space-1);
}
.aud-search-summary__top-list {
  margin: 0;
  padding-left: 1.25em;
  font-size: var(--aud-fs-3);
}
.aud-search-summary__top-list li {
  margin: 2px 0;
}
.aud-search-summary__top-list a {
  color: var(--aud-color-link);
  text-decoration: none;
}
.aud-search-summary__top-list a:hover,
.aud-search-summary__top-list a:focus-visible {
  text-decoration: underline;
}

/* AI summary mount point — hidden by default. */
.aud-ai-summary {
  margin-top: var(--aud-space-3);
  padding-top: var(--aud-space-3);
  border-top: 1px solid var(--aud-color-rule);
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
  line-height: 1.5;
}
.aud-ai-summary[hidden] { display: none; }

/* --- Pagination --------------------------------------------------------- */
/* Zendesk's {{pagination}} renders <ul class="pagination"> with anchor
   children. Style each link as a button. */
.aud-search-page__pagination {
  margin: var(--aud-space-5) 0;
}
.aud-search-page__pagination .pagination,
.aud-search-page__pagination ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
}
.aud-search-page__pagination li { margin: 0; }
.aud-search-page__pagination a,
.aud-search-page__pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  padding: 6px 12px;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-sm);
  color: var(--aud-color-text);
  font-size: var(--aud-fs-3);
  text-decoration: none;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.aud-search-page__pagination a:hover {
  background: var(--aud-color-bg-alt);
  border-color: var(--aud-color-link);
  text-decoration: none;
}
.aud-search-page__pagination .current,
.aud-search-page__pagination .active a,
.aud-search-page__pagination [aria-current="page"] {
  background: var(--aud-color-link);
  border-color: var(--aud-color-link);
  color: #fff;
}
.aud-search-page__pagination .disabled,
.aud-search-page__pagination .disabled a {
  opacity: 0.5;
  pointer-events: none;
}

/* End search page redesign */

/* ----------------------------------------------------------------------------
   Empty states & generic boxes
---------------------------------------------------------------------------- */
.aud-empty {
  padding: var(--aud-space-7);
  text-align: center;
  color: var(--aud-color-text-muted);
  border: 1px dashed var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  background: var(--aud-color-bg-alt);
}
.aud-empty h2 { margin-top: 0; font-size: var(--aud-fs-6); }
.aud-empty__action {
  margin-top: var(--aud-space-5);
}
.aud-empty__mailto {
  color: var(--aud-color-link);
  font-weight: 500;
}

.aud-btn {
  display: inline-block;
  padding: var(--aud-space-2) var(--aud-space-4);
  background: var(--aud-color-brand);
  color: var(--aud-color-brand-text);
  border-radius: var(--aud-radius-md);
  font-weight: 500;
  font-size: var(--aud-fs-3);
  border: none;
  cursor: pointer;
}
.aud-btn:hover { opacity: 0.9; text-decoration: none; color: var(--aud-color-brand-text); }
.aud-btn--ghost {
  background: transparent;
  color: var(--aud-color-text);
  border: 1px solid var(--aud-color-rule-strong);
}
.aud-btn--ghost:hover {
  border-color: var(--aud-color-link);
  color: var(--aud-color-link);
}

/* ----------------------------------------------------------------------------
   Footer
---------------------------------------------------------------------------- */
.aud-footer {
  background: var(--aud-color-bg-alt);
  border-top: 1px solid var(--aud-color-rule);
  padding: var(--aud-space-6) var(--aud-space-5);
  margin-top: var(--aud-space-7);
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-2);
}
.aud-footer__inner {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: var(--aud-space-5);
  flex-wrap: wrap;
}
.aud-footer__brand {
  display: flex;
  align-items: center;
  gap: var(--aud-space-3);
  font-weight: 600;
  color: var(--aud-color-text);
}
.aud-footer__logo-link {
  display: inline-flex;
  align-items: center;
  gap: var(--aud-space-2);
  text-decoration: none;
  color: inherit;
}
.aud-footer__logo-link:hover { text-decoration: none; }
.aud-footer__logo {
  /* Symbol-only image (square aspect ~217x259). At 36x44 px display the
     downscale is ~5.9x — same as v5.9.8 — but without the thin wordmark
     letterforms that were the actual blur source, the rendering is crisp.
     The brand name is rendered as HTML text in .aud-footer__wordmark
     beside the symbol so it stays sharp at any size. */
  height: 44px;
  width: auto;
  display: block;
  image-rendering: -webkit-optimize-contrast;
}
.aud-footer__wordmark {
  font-size: var(--aud-fs-4);
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--aud-color-text);
  line-height: 1;
}
.aud-footer__tagline {
  color: var(--aud-color-text-muted);
  font-weight: 400;
  font-size: var(--aud-fs-2);
}
.aud-footer__spacer { flex: 1; }
.aud-footer__links {
  display: flex;
  gap: var(--aud-space-4);
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}
.aud-footer__links li { margin: 0; }
.aud-footer__links a { color: var(--aud-color-text-muted); font-size: var(--aud-fs-2); }
.aud-footer__links a:hover { color: var(--aud-color-link); text-decoration: none; }
.aud-footer__legal {
  width: 100%;
  border-top: 1px solid var(--aud-color-rule);
  margin-top: var(--aud-space-4);
  padding-top: var(--aud-space-4);
  font-size: var(--aud-fs-1);
  color: var(--aud-color-text-subtle);
  text-align: right;
}

/* ============================================================================
   Help widget — floating "?" badge with slide-up panel (v5.9.11)

   Pattern: disclosure widget (NOT modal). Lives at fixed bottom-right,
   above all page content but below any future system modals. The badge
   toggles state; the panel slides up + fades in when opened.

   Design choices:
     • Brand-blue badge (theme link color) instead of the Pendo pink in
       the reference design — matches Auditoria's existing palette.
     • Panel uses a subtle 8px-blue top border to echo Pendo's accent
       stripe pattern without copying the color.
     • Modules are clickable rows with icon + title + subtitle + chevron,
       hover state lifts the row's left tint.
     • Mobile (<640px): panel becomes near-fullscreen so the same
       interaction works on small viewports.

   Performance: panel content is rendered via JS (fetch + innerHTML)
   after page load. It's hidden via the [hidden] attribute (not just
   display:none) so screen readers skip it when closed.
============================================================================ */
.aud-help-widget {
  position: fixed;
  bottom: var(--aud-space-5);
  right: var(--aud-space-5);
  z-index: 9000;
  font-size: var(--aud-fs-3);
}

.aud-help-widget__badge {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: none;
  background: var(--aud-color-link);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15), 0 2px 4px rgba(0, 0, 0, 0.08);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  position: relative;
}
@media (hover: hover) {
  .aud-help-widget__badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18), 0 2px 4px rgba(0, 0, 0, 0.1);
  }
}
.aud-help-widget__badge:focus-visible {
  outline: 3px solid rgba(0, 102, 214, 0.35);
  outline-offset: 3px;
}
.aud-help-widget__badge:active {
  transform: translateY(0);
}

/* Two icons inside the badge (question mark and X) — we cross-fade between
   them based on widget state instead of rotating a single icon, which is
   smoother and works better with screen readers. */
.aud-help-widget__badge-icon {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.15s ease;
}
.aud-help-widget__badge-icon--close { opacity: 0; }
.aud-help-widget.is-open .aud-help-widget__badge-icon--question { opacity: 0; }
.aud-help-widget.is-open .aud-help-widget__badge-icon--close { opacity: 1; }

/* Panel — sits ABOVE the badge, anchored to right edge. */
.aud-help-widget__panel {
  position: absolute;
  bottom: calc(56px + var(--aud-space-3));
  right: 0;
  width: 380px;
  max-width: calc(100vw - var(--aud-space-5) * 2);
  max-height: calc(100vh - 56px - var(--aud-space-5) * 3);
  background: #fff;
  border-radius: var(--aud-radius-md);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18), 0 4px 12px rgba(0, 0, 0, 0.08);
  border-top: 4px solid var(--aud-color-link);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  /* Hidden default state — the open state is animated in via .is-open */
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.aud-help-widget.is-open .aud-help-widget__panel {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
/* When closed, the [hidden] attribute also display:none-s the panel so
   keyboard tab order doesn't reach it. Browsers honor [hidden] even when
   we have CSS opacity transitions defined. */
.aud-help-widget__panel[hidden] {
  display: none;
}

.aud-help-widget__header {
  padding: var(--aud-space-4) var(--aud-space-5) var(--aud-space-3);
  border-bottom: 1px solid var(--aud-color-rule);
  display: flex;
  align-items: flex-start;
  gap: var(--aud-space-2);
}
.aud-help-widget__back {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  cursor: pointer;
  border-radius: var(--aud-radius-sm);
  color: var(--aud-color-text-muted);
  margin-top: 2px;
  transition: background 0.12s ease, color 0.12s ease;
}
@media (hover: hover) {
  .aud-help-widget__back:hover {
    background: var(--aud-color-bg-alt);
    color: var(--aud-color-text);
  }
}
.aud-help-widget__back:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 2px;
}
.aud-help-widget__back[hidden] { display: none; }
.aud-help-widget__heading {
  flex: 1;
  min-width: 0;
}
.aud-help-widget__title {
  margin: 0 0 var(--aud-space-1);
  font-size: var(--aud-fs-5);
  font-weight: 600;
  color: var(--aud-color-text);
}
.aud-help-widget__subtitle {
  margin: 0;
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
  line-height: 1.4;
}
.aud-help-widget__subtitle[hidden] { display: none; }

.aud-help-widget__modules {
  list-style: none;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.aud-help-widget__module {
  margin: 0;
  padding: 0;
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-help-widget__module:last-child {
  border-bottom: none;
}
/* .aud-help-widget__module-link applies to BOTH the <a> (navigate
   modules + drill-down items) AND the <button> (drill-down triggers).
   Single class keeps visual parity between the two interaction
   patterns — users shouldn't see a styling difference between "Browse
   documentation" (a button that drills) and "Email support" (a link
   that navigates). The button reset below normalizes browser default
   button styling. */
.aud-help-widget__module-link {
  display: flex;
  align-items: center;
  gap: var(--aud-space-3);
  width: 100%;
  padding: var(--aud-space-3) var(--aud-space-5);
  color: var(--aud-color-text);
  text-decoration: none;
  background: transparent;
  border: none;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s ease;
}
/* Hover styles ONLY on devices with real hover capability. On touch
   devices (iOS Safari, Android Chrome), :hover styles cause a double-tap
   bug: first tap activates the hover state, second tap fires the click.
   Wrapping in @media (hover: hover) restricts these styles to mouse/
   trackpad users and lets touch users get a single-tap experience. */
@media (hover: hover) {
  .aud-help-widget__module-link:hover {
    background: var(--aud-color-bg-alt);
    text-decoration: none;
  }
}
/* Focus-visible always works regardless of input modality — keyboard
   users on any device, including touch devices with external keyboards,
   need focus indicators. */
.aud-help-widget__module-link:focus-visible {
  background: rgba(0, 102, 214, 0.06);
  box-shadow: inset 3px 0 0 var(--aud-color-link);
  text-decoration: none;
  outline: none;
}
/* Active state — tap/click feedback that works on every device. Brief
   background flash gives users immediate "I clicked" confirmation
   without the iOS double-tap problem hover causes. */
.aud-help-widget__module-link:active {
  background: var(--aud-color-bg-alt);
}

.aud-help-widget__module-icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: var(--aud-radius-sm);
  background: var(--aud-color-bg-alt);
  color: var(--aud-color-link);
  display: flex;
  align-items: center;
  justify-content: center;
}
.aud-help-widget__module-body {
  flex: 1;
  min-width: 0;
}
.aud-help-widget__module-title {
  display: block;
  font-weight: 500;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
  line-height: 1.3;
}
.aud-help-widget__module-subtitle {
  display: block;
  margin-top: 2px;
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
  line-height: 1.4;
}
.aud-help-widget__module-chev {
  flex-shrink: 0;
  color: var(--aud-color-text-subtle);
}
@media (hover: hover) {
  .aud-help-widget__module-link:hover .aud-help-widget__module-chev {
    color: var(--aud-color-link);
  }
}
.aud-help-widget__module-link:focus-visible .aud-help-widget__module-chev {
  color: var(--aud-color-link);
}
.aud-help-widget__module-ext {
  display: inline;
  margin-left: 4px;
  vertical-align: -1px;
  color: var(--aud-color-text-subtle);
}

/* Drill-down items don't show the round colored icon (it's not
   meaningful for individual articles/categories — those don't have
   per-item icons in the data). Keeps the row visually lighter so
   users can scan a longer list. */
.aud-help-widget__module-link--drilldown {
  padding-left: var(--aud-space-5);
}

/* "Latest" badge for the top release in the Release Notes drill-down.
   Inline-block, sits to the right of the title text. Uses brand blue
   filled style — same affordance as a button, signaling action-worthy. */
.aud-help-widget__badge-latest {
  display: inline-block;
  margin-left: var(--aud-space-2);
  padding: 1px 8px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: var(--aud-color-link);
  color: #fff;
  border-radius: 999px;
  vertical-align: 1px;
}

/* Subtle highlight for the latest release row — soft tinted background
   plus a left accent stripe. Distinct from the focus state (which uses
   a different hover styling) so both can be visible together. */
.aud-help-widget__module-link.is-latest {
  background: linear-gradient(90deg, rgba(0,102,214,0.05) 0%, rgba(0,102,214,0) 100%);
  box-shadow: inset 3px 0 0 var(--aud-color-link);
}
@media (hover: hover) {
  .aud-help-widget__module-link.is-latest:hover {
    background: linear-gradient(90deg, rgba(0,102,214,0.1) 0%, rgba(0,102,214,0.02) 100%);
  }
}
.aud-help-widget__module-link.is-latest:focus-visible {
  background: linear-gradient(90deg, rgba(0,102,214,0.1) 0%, rgba(0,102,214,0.02) 100%);
}

.aud-help-widget__loading,
.aud-help-widget__empty {
  padding: var(--aud-space-5);
  color: var(--aud-color-text-muted);
  text-align: center;
  font-size: var(--aud-fs-2);
}

/* Mobile responsive — at narrow viewports, the floating panel pattern
   stops working (panel would overflow viewport edges). Switch to a
   bottom-anchored sheet that takes near-full width. */
@media (max-width: 640px) {
  .aud-help-widget {
    bottom: var(--aud-space-3);
    right: var(--aud-space-3);
  }
  .aud-help-widget__badge {
    width: 48px;
    height: 48px;
  }
  .aud-help-widget__panel {
    bottom: calc(48px + var(--aud-space-2));
    right: 0;
    width: calc(100vw - var(--aud-space-3) * 2);
    max-height: calc(100vh - 48px - var(--aud-space-3) * 3);
  }
}

/* Respect prefers-reduced-motion: drop the slide animation, keep only
   opacity. Users who set this in OS preferences expect minimal motion. */
@media (prefers-reduced-motion: reduce) {
  .aud-help-widget__panel,
  .aud-help-widget__badge,
  .aud-help-widget__badge-icon,
  .aud-help-widget__module-link,
  .aud-help-widget__back {
    transition-duration: 0s;
  }
  .aud-help-widget__panel {
    transform: none;
  }
}

/* Print: hide the widget — it's interactive UI, not content. */
@media print {
  .aud-help-widget { display: none !important; }
}

/* ----------------------------------------------------------------------------
   Mobile responsive
---------------------------------------------------------------------------- */
/* TOC breakpoint — at 1100px and below, collapse the right TOC rail and
   show a mobile disclosure widget above the article body instead. The
   left rail still shows. */
@media (max-width: 1100px) {
  .aud-page--with-toc {
    grid-template-columns: var(--aud-rail-w) 1fr;
  }
  .aud-page--with-toc .aud-page__main {
    max-width: none;
  }
  .aud-page__toc { display: none; }
  .aud-toc-mobile { display: block; }
}

@media (max-width: 900px) {
  .aud-page,
  .aud-search-page {
    grid-template-columns: 1fr;
  }
  .aud-page__rail,
  .aud-search-page__refine {
    border-right: none;
    border-bottom: 1px solid var(--aud-color-rule);
    padding-right: 0;
    padding-bottom: var(--aud-space-4);
    margin-bottom: var(--aud-space-4);
    display: none;
  }
  .aud-page--rail-open .aud-page__rail,
  .aud-search-page--rail-open .aud-search-page__refine {
    display: block;
  }
  .aud-rail-toggle { display: inline-flex; }

  .aud-home__triplet,
  .aud-home__pair {
    grid-template-columns: 1fr;
    gap: var(--aud-space-5);
  }
  .aud-explore__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .aud-explore__cards {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Utility bar on phones: keep desktop's centered 3-column layout but
     tighten the inter-column gap so the logo has room on narrow screens. */
  .aud-utilitybar__inner {
    gap: var(--aud-space-2);
  }

  .aud-docsnav__inner {
    flex-wrap: wrap;
    height: auto;
    padding: var(--aud-space-3) var(--aud-space-5);
    gap: var(--aud-space-3);
  }
  .aud-docsnav__title { flex: 1 0 auto; }
  .aud-docsnav__links {
    order: 3;
    flex-basis: 100%;
    gap: var(--aud-space-4);
    flex-wrap: wrap;
    margin: var(--aud-space-2) 0;
  }
  .aud-docsnav__search {
    flex: 1 1 100%;
    order: 4;
  }

  /* Hide the Documentation title on narrow screens — the centered logo is enough */
  /* Actually: keep it, but smaller */
  .aud-docsnav__title { font-size: var(--aud-fs-5); }

  /* Hero scales down */
  .aud-hero { padding: var(--aud-space-6) var(--aud-space-4); }
  .aud-hero h1 { font-size: 32px; }
  .aud-hero p { font-size: var(--aud-fs-4); }
  .aud-hero__search { flex-direction: row; }

  /* Quick links 2-col goes to 1-col on tablet+mobile */
  .aud-quicklinks--two-col {
    grid-template-columns: 1fr;
  }
  .aud-quicklinks--two-col a:nth-child(2n) {
    border-left: none;
  }
  .aud-quicklinks--two-col a {
    border-bottom: 1px solid var(--aud-color-rule);
  }
  .aud-quicklinks--two-col a:last-child {
    grid-column: auto;
    border-bottom: none;
  }
}

@media (max-width: 540px) {
  .aud-explore__grid { grid-template-columns: 1fr; }
  .aud-explore__cards { grid-template-columns: 1fr; }
  .aud-hero h1 { font-size: 26px; }
  .aud-hero p { font-size: var(--aud-fs-3); }
  .aud-article__title { font-size: 22px; }

  /* On phones, hide the "Search" button text in the hero pill — keep just the input + search icon
     But this is a pill: better to keep things, just shorten the button */
  .aud-hero__search-btn {
    padding: var(--aud-space-2) var(--aud-space-4);
    font-size: var(--aud-fs-2);
  }
  .aud-hero__search { padding: 4px; }

  /* Logo a bit smaller on phones */
  .aud-utilitybar__logo { height: 64px; }

  /* Prev/Next on phones — stack vertically, simpler labels */
  .aud-pagination {
    flex-direction: column;
    gap: var(--aud-space-3);
  }
  .aud-pagination__btn {
    flex: 1 1 auto;
    width: 100%;
  }
  .aud-pagination__btn--next {
    margin-left: 0;
  }
}

/* ============================================================================
   My Requests page — v5.9.25 full restyle

   Design goals:
     • Match the rest of the theme (rounded cards, brand-blue accents,
       same typography scale)
     • Make Submit a request unmissable — primary blue CTA at top right
     • Status pills color-coded by ticket status for quick scanning
     • Filter tabs that look like proper tabs, not the unstyled
       collapsible-nav menu Zendesk's default uses
     • Hover styles gated for touch devices per the iOS double-tap fix

   Also defines a small generic .aud-btn / .aud-btn--primary button
   system that other pages (new_request, request, etc.) can use later.
============================================================================ */

/* --- Generic button system --- */
.aud-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--aud-space-2);
  padding: var(--aud-space-3) var(--aud-space-4);
  font-size: var(--aud-fs-3);
  font-weight: 500;
  font-family: inherit;
  border-radius: var(--aud-radius-md);
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background 120ms, border-color 120ms, box-shadow 120ms;
}
.aud-btn--primary {
  background: var(--aud-color-link);
  color: #fff;
  border-color: var(--aud-color-link);
}
@media (hover: hover) {
  .aud-btn--primary:hover {
    background: #0058B7;  /* link color slightly darkened for hover */
    border-color: #0058B7;
    color: #fff;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0, 102, 214, 0.25);
  }
}
.aud-btn--primary:focus-visible {
  outline: 2px solid var(--aud-color-link);
  outline-offset: 2px;
}
.aud-btn--primary:active {
  background: #00468f;
  border-color: #00468f;
}

/* --- Page header

   v5.9.27: simplified to plain title, no flex layout, no bottom rule.
   The page-level Submit a request CTA was removed (now in the utility
   bar header), so this is just an h1 above the filter tabs. */
.aud-requests__header {
  margin-bottom: var(--aud-space-4);
}
.aud-requests__title {
  font-size: var(--aud-fs-7);
  margin: 0;
}

/* --- Filter tabs --- */
.aud-requests__filters {
  margin-bottom: var(--aud-space-4);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-requests__filters-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--aud-space-1);
}
.aud-requests__filters-list li { margin: 0; }
.aud-requests__filter-tab {
  display: block;
  padding: var(--aud-space-3) var(--aud-space-4);
  color: var(--aud-color-text-muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  font-size: var(--aud-fs-3);
  transition: color 120ms, border-color 120ms;
}
@media (hover: hover) {
  .aud-requests__filter-tab:hover {
    color: var(--aud-color-text);
    text-decoration: none;
  }
}
.aud-requests__filter-tab.is-selected {
  color: var(--aud-color-link);
  border-bottom-color: var(--aud-color-link);
  font-weight: 500;
}

/* --- Search + status filter toolbar --- */
.aud-requests__toolbar {
  display: flex;
  gap: var(--aud-space-3);
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: var(--aud-space-4);
}
.aud-requests__search {
  position: relative;
  /* v5.9.31: changed flex from `1 1 280px` to `1 1 0` so the search
     input grows to consume all available toolbar space. The previous
     280px basis meant the search stopped at ~40-50% of the toolbar
     width, leaving an awkward empty gap before the Status filter. With
     basis=0 the search takes every leftover pixel after the filter
     group sizes itself to content. */
  flex: 1 1 0;
  min-width: 240px;
}
/* Visually hide search label but keep for screen readers. */
.aud-requests__search-label {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.aud-requests__search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--aud-color-text-subtle);
  pointer-events: none;
}
.aud-requests__search-input {
  width: 100%;
  padding: 8px 12px 8px 38px;
  font-size: var(--aud-fs-3);
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: var(--aud-radius-md);
  background: #fff;
  -webkit-appearance: none;
  appearance: none;
  font-family: inherit;
  transition: border-color 120ms, box-shadow 120ms;
}
.aud-requests__search-input:focus {
  outline: none;
  border-color: var(--aud-color-link);
  box-shadow: 0 0 0 3px rgba(0, 102, 214, 0.15);
}

.aud-requests__filter-group {
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
}
.aud-requests__filter-label {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
  white-space: nowrap;
}
.aud-requests__filter-select {
  padding: 8px 32px 8px 12px;
  font-size: var(--aud-fs-3);
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: var(--aud-radius-md);
  background-color: #fff;
  font-family: inherit;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M3 4.5l3 3 3-3'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}
.aud-requests__filter-select:focus {
  outline: none;
  border-color: var(--aud-color-link);
  box-shadow: 0 0 0 3px rgba(0, 102, 214, 0.15);
}

/* --- Empty state --- */
.aud-requests__empty {
  text-align: center;
  padding: var(--aud-space-6) var(--aud-space-5);
  background: var(--aud-color-bg-alt);
  border: 1px dashed var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
}
.aud-requests__empty p {
  margin: 0 0 var(--aud-space-4);
  color: var(--aud-color-text-muted);
}

.aud-requests__info {
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-3);
  margin: 0 0 var(--aud-space-3);
}

/* --- Requests table (open layout, no card wrapper)

   v5.9.27: removed the outer border + rounded corners + bg color so
   the table reads as plain rows with thin dividers — matches the
   original Auditoria layout. Header row also simpler: bold dark text
   instead of all-caps muted. */
.aud-requests__table-wrap {
  margin-bottom: var(--aud-space-5);
}
.aud-requests__table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--aud-fs-3);
}
.aud-requests__table th,
.aud-requests__table td {
  padding: var(--aud-space-3) var(--aud-space-4);
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-requests__table thead th {
  font-weight: 600;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-requests__table thead a {
  color: inherit;
  text-decoration: none;
}
@media (hover: hover) {
  .aud-requests__table thead a:hover {
    color: var(--aud-color-link);
    text-decoration: underline;
  }
  .aud-requests__table tbody tr:hover {
    background: var(--aud-color-bg-alt);
  }
}
.aud-requests__row.is-closed {
  opacity: 0.7;
}
.aud-requests__td-id {
  color: var(--aud-color-text-muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.aud-requests__link {
  color: var(--aud-color-link);
  text-decoration: none;
}
@media (hover: hover) {
  .aud-requests__link:hover {
    text-decoration: underline;
  }
}

/* --- Status pills (color-coded by ticket status, FILLED style)

   v5.9.27: changed from soft tinted backgrounds to bold filled badges
   per the original Auditoria layout — red Open, green
   pending/awaiting-your-reply, gray Solved, etc. The filled style
   reads more clearly at a glance, especially in dense tables. */
.aud-status-pill {
  display: inline-block;
  padding: 4px 10px;
  font-size: var(--aud-fs-2);
  font-weight: 500;
  border-radius: var(--aud-radius-sm, 4px);
  white-space: nowrap;
  color: #fff;
  letter-spacing: 0.01em;
}
.aud-status-pill--new      { background: #2563eb; }  /* blue   */
.aud-status-pill--open     { background: #dc2626; }  /* red    */
.aud-status-pill--pending  { background: #16a34a; }  /* green — "Awaiting your reply" */
.aud-status-pill--hold     { background: #d97706; }  /* amber  */
.aud-status-pill--solved   { background: #6b7280; }  /* gray   */
.aud-status-pill--closed   { background: #475569; }  /* slate  */

.aud-requests__pagination {
  display: flex;
  justify-content: center;
  margin-top: var(--aud-space-5);
}

/* --- Mobile --- */
@media (max-width: 720px) {
  .aud-requests__header {
    flex-direction: column;
    align-items: stretch;
  }
  .aud-requests__submit {
    width: 100%;
  }
  .aud-requests__toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .aud-requests__filter-group {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--aud-space-1);
  }
  .aud-requests__filter-select,
  .aud-requests__filter-group {
    width: 100%;
  }
  /* Hide ID column on small screens — it's redundant with subject */
  .aud-requests__table .aud-requests__th-id,
  .aud-requests__table .aud-requests__td-id {
    display: none;
  }
}

/* ============================================================================
   Single ticket page (request_page) — v5.9.26 full restyle

   Layout: 2-column grid on desktop (comments thread + ticket details
   sidebar), stacks vertically below 900px. Comments thread uses an
   avatar-first layout with the body to the right; agent comments get
   a tinted background + agent-badge overlay on the avatar so the
   conversation reads at a glance.

   All aud-btn / aud-status-pill classes are reused from the My Requests
   page so the list → detail flow feels visually consistent.
============================================================================ */

/* --- Page header (title + status meta + back button) --- */
.aud-ticket__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: var(--aud-space-4);
  margin-bottom: var(--aud-space-5);
  padding-bottom: var(--aud-space-4);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-ticket__heading {
  flex: 1;
  min-width: 0;
}
.aud-ticket__title {
  font-size: var(--aud-fs-7);
  margin: 0 0 var(--aud-space-2);
  word-break: break-word;
}
.aud-ticket__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--aud-space-3);
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text-muted);
}
.aud-ticket__id {
  font-variant-numeric: tabular-nums;
}
.aud-ticket__followup {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
}
.aud-ticket__back {
  flex: 0 0 auto;
}

/* --- Two-column layout: comments + sidebar --- */
.aud-ticket__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: var(--aud-space-6);
  align-items: start;
}
.aud-ticket__main {
  min-width: 0;
}
.aud-ticket__sidebar {
  position: sticky;
  top: var(--aud-space-5);
  background: var(--aud-color-bg-alt);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  padding: var(--aud-space-4);
  font-size: var(--aud-fs-3);
}

/* --- Comments thread --- */
.aud-ticket__comments {
  list-style: none;
  margin: 0 0 var(--aud-space-5);
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--aud-space-4);
}
.aud-ticket__comment {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: var(--aud-space-3);
  padding: var(--aud-space-4);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
}
.aud-ticket__comment.is-agent {
  background: #f5f9ff;
  border-color: #d6e4f5;
  border-left: 3px solid var(--aud-color-link);
}
.aud-ticket__comment-avatar {
  position: relative;
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
}
.aud-ticket__avatar-img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--aud-color-bg-alt);
  display: block;
}
.aud-ticket__agent-badge {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 16px;
  height: 16px;
  background: var(--aud-color-link);
  color: #fff;
  border-radius: 50%;
  border: 2px solid #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.aud-ticket__comment-body {
  min-width: 0;
}
.aud-ticket__comment-header {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--aud-space-2);
  margin-bottom: var(--aud-space-2);
}
.aud-ticket__comment-author {
  font-weight: 600;
  font-size: var(--aud-fs-3);
}
.aud-ticket__comment-author a {
  color: var(--aud-color-text);
  text-decoration: none;
}
@media (hover: hover) {
  .aud-ticket__comment-author a:hover {
    color: var(--aud-color-link);
    text-decoration: underline;
  }
}
.aud-ticket__comment-tag {
  display: inline-block;
  padding: 1px 8px;
  font-size: var(--aud-fs-1);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: 999px;
  background: #dbeafe;
  color: #1e40af;
}
.aud-ticket__comment-time {
  margin-left: auto;
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
}
.aud-ticket__comment-text {
  font-size: var(--aud-fs-3);
  line-height: 1.55;
  word-wrap: break-word;
}
.aud-ticket__comment-text > *:first-child { margin-top: 0; }
.aud-ticket__comment-text > *:last-child { margin-bottom: 0; }
.aud-ticket__comment-text p { margin: 0 0 var(--aud-space-3); }
.aud-ticket__comment-text a {
  color: var(--aud-color-link);
}

/* --- Attachments (in comment + in sidebar) --- */
.aud-ticket__attachments {
  list-style: none;
  margin: var(--aud-space-3) 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--aud-space-1);
}
.aud-ticket__attachment {
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
  padding: 6px 10px;
  background: var(--aud-color-bg-alt);
  border-radius: var(--aud-radius-sm, 6px);
  font-size: var(--aud-fs-2);
  flex-wrap: wrap;
}
.aud-ticket__attachment svg {
  flex: 0 0 16px;
  color: var(--aud-color-text-subtle);
}
.aud-ticket__attachment-name {
  color: var(--aud-color-link);
  text-decoration: none;
  font-weight: 500;
  word-break: break-all;
}
@media (hover: hover) {
  .aud-ticket__attachment-name:hover { text-decoration: underline; }
}
.aud-ticket__attachment-size {
  color: var(--aud-color-text-muted);
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}
.aud-ticket__attachment-action {
  color: var(--aud-color-text-muted);
  text-decoration: none;
}
@media (hover: hover) {
  .aud-ticket__attachment-action:hover {
    color: var(--aud-color-link);
    text-decoration: underline;
  }
}

/* --- Pagination --- */
.aud-ticket__pagination {
  display: flex;
  justify-content: center;
  margin: var(--aud-space-4) 0;
}
.aud-ticket__pagination:empty { display: none; }

/* --- Follow-up callout (when ticket is closed/solved) --- */
.aud-ticket__follow-up {
  padding: var(--aud-space-4);
  background: #fef3c7;
  border-left: 3px solid #f59e0b;
  border-radius: var(--aud-radius-md);
  margin-bottom: var(--aud-space-5);
  font-size: var(--aud-fs-3);
  color: #78350f;
}
.aud-ticket__follow-up a {
  color: #78350f;
  font-weight: 600;
  text-decoration: underline;
}
.aud-ticket__follow-up:empty { display: none; }

/* --- Reply form --- */
.aud-ticket__reply {
  margin-top: var(--aud-space-5);
  padding: var(--aud-space-4);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
}
.aud-ticket__reply-header {
  display: flex;
  align-items: center;
  gap: var(--aud-space-3);
  margin-bottom: var(--aud-space-3);
  padding-bottom: var(--aud-space-3);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-ticket__reply-title {
  font-size: var(--aud-fs-4);
  margin: 0;
}
.aud-ticket__reply-toggle {
  /* shown until user starts a reply; clicking expands the fields */
  width: 100%;
  text-align: left;
  justify-content: flex-start;
}
.aud-ticket__reply-toggle.is-hidden { display: none; }
.aud-ticket__reply-fields {
  display: none;
}
.aud-ticket__reply-fields.is-shown { display: block; }
.aud-ticket__reply-field {
  margin-bottom: var(--aud-space-3);
}
.aud-ticket__reply-label {
  display: block;
  font-size: var(--aud-fs-2);
  font-weight: 600;
  color: var(--aud-color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: var(--aud-space-1);
}
.aud-ticket__ccs-input,
.aud-ticket__ccs-input input {
  width: 100%;
  padding: 8px 12px;
  font-size: var(--aud-fs-3);
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: var(--aud-radius-md);
  font-family: inherit;
}
.aud-ticket__reply-editor {
  margin-bottom: var(--aud-space-3);
}
.aud-ticket__reply-editor textarea,
.aud-ticket__reply-editor .ck-editor__main,
.aud-ticket__reply-editor .ck-content {
  min-height: 140px;
  border-radius: var(--aud-radius-md);
}
.aud-ticket__reply-attachments {
  margin-bottom: var(--aud-space-3);
}
.aud-ticket__reply-controls {
  display: none;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--aud-space-3);
  padding-top: var(--aud-space-3);
  border-top: 1px solid var(--aud-color-rule);
}
.aud-ticket__reply-controls.is-shown { display: flex; }
.aud-ticket__reply-checkbox {
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text-muted);
  cursor: pointer;
}
.aud-ticket__reply-buttons {
  margin-left: auto;
  display: flex;
  gap: var(--aud-space-2);
  flex-wrap: wrap;
}

/* --- Sidebar (ticket details) --- */
.aud-ticket__sidebar-title {
  margin: 0 0 var(--aud-space-3);
  font-size: var(--aud-fs-3);
  font-weight: 600;
  color: var(--aud-color-text);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.aud-ticket__sidebar-subtitle {
  margin: var(--aud-space-4) 0 var(--aud-space-2);
  font-size: var(--aud-fs-2);
  font-weight: 600;
  color: var(--aud-color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.aud-ticket__details {
  margin: 0 0 var(--aud-space-3);
  padding: 0;
  display: grid;
  grid-template-columns: minmax(80px, 90px) 1fr;
  gap: var(--aud-space-2) var(--aud-space-3);
  font-size: var(--aud-fs-2);
}
.aud-ticket__details + .aud-ticket__details {
  padding-top: var(--aud-space-3);
  border-top: 1px solid var(--aud-color-rule);
}
.aud-ticket__details dt {
  color: var(--aud-color-text-muted);
  font-weight: 500;
  margin: 0;
}
.aud-ticket__details dd {
  margin: 0;
  word-break: break-word;
}
.aud-ticket__details-link {
  color: var(--aud-color-link);
  text-decoration: none;
  font-size: var(--aud-fs-2);
  display: inline-block;
  margin-top: 2px;
}
@media (hover: hover) {
  .aud-ticket__details-link:hover { text-decoration: underline; }
}
.aud-ticket__details-id {
  font-variant-numeric: tabular-nums;
}
.aud-ticket__collaborators {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--aud-space-1);
}
.aud-ticket__collaborators li {
  padding: 1px 8px;
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: 999px;
  font-size: var(--aud-fs-1);
  margin: 0;
}
.aud-ticket__org-form {
  margin: var(--aud-space-3) 0 0;
}
.aud-ticket__org-select {
  width: 100%;
  padding: 6px 28px 6px 10px;
  font-size: var(--aud-fs-2);
  border: 1px solid var(--aud-color-rule-strong);
  border-radius: var(--aud-radius-md);
  background-color: #fff;
  font-family: inherit;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 12 12' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M3 4.5l3 3 3-3'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
}
.aud-ticket__sidebar-attachments {
  margin-top: var(--aud-space-4);
  padding-top: var(--aud-space-3);
  border-top: 1px solid var(--aud-color-rule);
}
.aud-ticket__attachments--sidebar .aud-ticket__attachment {
  background: #fff;
  font-size: var(--aud-fs-1);
  padding: 6px 8px;
}

/* --- Mobile: stack sidebar below main, single column --- */
@media (max-width: 900px) {
  .aud-ticket__layout {
    grid-template-columns: 1fr;
  }
  .aud-ticket__sidebar {
    position: static;
  }
}
@media (max-width: 720px) {
  .aud-ticket__header {
    flex-direction: column;
    align-items: stretch;
  }
  .aud-ticket__back {
    align-self: flex-start;
  }
  .aud-ticket__comment {
    grid-template-columns: 32px 1fr;
    padding: var(--aud-space-3);
  }
  .aud-ticket__comment-avatar,
  .aud-ticket__avatar-img {
    width: 32px;
    height: 32px;
  }
  .aud-ticket__comment-time {
    margin-left: 0;
    flex-basis: 100%;
  }
  .aud-ticket__reply-buttons {
    width: 100%;
    flex-direction: column;
  }
  .aud-ticket__reply-buttons .aud-btn {
    width: 100%;
  }
}

/* ============================================================================
   User profile / Contributions / Subscriptions pages — v5.9.28

   Replaces Copenhagen-default markup that previously rendered these
   pages as bullet-pointed plain HTML (no theme styling at all). Now
   they match the My Requests page visual language.
============================================================================ */

/* --- User profile page header (avatar + name + bio) --- */
.aud-profile__header {
  display: flex;
  gap: var(--aud-space-5);
  align-items: flex-start;
  flex-wrap: wrap;
  padding: var(--aud-space-5);
  background: var(--aud-color-bg-alt);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  margin-bottom: var(--aud-space-5);
}
.aud-profile__avatar-wrap {
  position: relative;
  width: 80px;
  height: 80px;
  flex: 0 0 80px;
}
.aud-profile__avatar-img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  background: #fff;
  display: block;
}
.aud-profile__agent-badge {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 24px;
  height: 24px;
  background: var(--aud-color-link);
  color: #fff;
  border-radius: 50%;
  border: 3px solid var(--aud-color-bg-alt);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.aud-profile__info {
  flex: 1;
  min-width: 0;
}
.aud-profile__name {
  font-size: var(--aud-fs-7);
  margin: 0 0 var(--aud-space-2);
  word-break: break-word;
  /* v5.9.28: name should be the page heading, not a link.
     If Zendesk wraps in <a>, force it to look like text. */
  color: var(--aud-color-text);
}
.aud-profile__name a {
  color: inherit;
  text-decoration: none;
}
.aud-profile__private {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
  padding: 2px 8px;
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: 999px;
  margin-bottom: var(--aud-space-2);
}
.aud-profile__bio {
  margin: 0 0 var(--aud-space-3);
  color: var(--aud-color-text);
  font-size: var(--aud-fs-3);
  line-height: 1.5;
}
.aud-profile__actions {
  display: flex;
  gap: var(--aud-space-2);
  flex-wrap: wrap;
}
.aud-profile__action-menu a,
.aud-profile__action-menu button {
  display: inline-block;
  padding: 6px 12px;
  font-size: var(--aud-fs-2);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  background: #fff;
  color: var(--aud-color-text);
  text-decoration: none;
  cursor: pointer;
}
@media (hover: hover) {
  .aud-profile__action-menu a:hover,
  .aud-profile__action-menu button:hover {
    border-color: var(--aud-color-link);
    color: var(--aud-color-link);
  }
}

/* --- Stats row (Total activity, Last activity, Member since, Votes, Subs) --- */
.aud-profile__stats {
  list-style: none;
  margin: 0 0 var(--aud-space-5);
  padding: var(--aud-space-4);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: var(--aud-space-4);
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
}
.aud-profile__stat {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.aud-profile__stat-label {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.aud-profile__stat-value {
  font-size: var(--aud-fs-5);
  font-weight: 600;
  color: var(--aud-color-text);
}

/* --- Filter tabs (shared by profile, contributions, subscriptions) --- */
.aud-profile__filters,
.aud-contributions__filters {
  margin-bottom: var(--aud-space-4);
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-profile__filter-list,
.aud-contributions__filter-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--aud-space-1);
}
.aud-profile__filter-list li,
.aud-contributions__filter-list li { margin: 0; }

.aud-profile__filter-tab,
.aud-contributions__filter-tab {
  display: block;
  padding: var(--aud-space-3) var(--aud-space-4);
  color: var(--aud-color-text-muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  font-size: var(--aud-fs-3);
  transition: color 120ms, border-color 120ms;
}
@media (hover: hover) {
  .aud-profile__filter-tab:hover,
  .aud-contributions__filter-tab:hover {
    color: var(--aud-color-text);
    text-decoration: none;
  }
}
.aud-profile__filter-tab.is-selected,
.aud-contributions__filter-tab.is-selected {
  color: var(--aud-color-link);
  border-bottom-color: var(--aud-color-link);
  font-weight: 500;
}

/* --- Profile content sections (recent articles/comments/posts) --- */
.aud-profile__section {
  margin-bottom: var(--aud-space-5);
}
.aud-profile__section-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: var(--aud-space-3);
}
.aud-profile__section-title {
  font-size: var(--aud-fs-4);
  margin: 0;
}
.aud-profile__see-all {
  color: var(--aud-color-link);
  text-decoration: none;
  font-size: var(--aud-fs-3);
}
@media (hover: hover) {
  .aud-profile__see-all:hover { text-decoration: underline; }
}
.aud-profile__list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.aud-profile__list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--aud-space-3);
  padding: var(--aud-space-3) 0;
  border-bottom: 1px solid var(--aud-color-rule);
  margin: 0;
}
.aud-profile__list-item:last-child { border-bottom: none; }
.aud-profile__list-link {
  color: var(--aud-color-link);
  text-decoration: none;
  flex: 1;
  min-width: 0;
}
@media (hover: hover) {
  .aud-profile__list-link:hover { text-decoration: underline; }
}
.aud-profile__list-meta {
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-2);
  white-space: nowrap;
}
.aud-profile__empty,
.aud-contributions__empty {
  text-align: center;
  padding: var(--aud-space-6) var(--aud-space-5);
  color: var(--aud-color-text-muted);
  background: var(--aud-color-bg-alt);
  border: 1px dashed var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
}
.aud-profile__empty p,
.aud-contributions__empty p { margin: 0; }

/* --- Contributions / Subscriptions page header --- */
.aud-contributions__header {
  margin-bottom: var(--aud-space-4);
}
.aud-contributions__title {
  font-size: var(--aud-fs-7);
  margin: 0;
}

/* --- Contributions / Subscriptions table (open layout, like requests) --- */
.aud-contributions__table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--aud-fs-3);
  margin-bottom: var(--aud-space-4);
}
.aud-contributions__table th,
.aud-contributions__table td {
  padding: var(--aud-space-3) var(--aud-space-4);
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid var(--aud-color-rule);
}
.aud-contributions__table thead th {
  font-weight: 600;
  font-size: var(--aud-fs-3);
  color: var(--aud-color-text);
}
.aud-contributions__th-votes,
.aud-contributions__td-votes {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.aud-contributions__th-type,
.aud-contributions__td-type {
  color: var(--aud-color-text-muted);
  text-transform: capitalize;
}
@media (hover: hover) {
  .aud-contributions__table tbody tr:hover {
    background: var(--aud-color-bg-alt);
  }
}
.aud-contributions__link {
  color: var(--aud-color-link);
  text-decoration: none;
}
@media (hover: hover) {
  .aud-contributions__link:hover { text-decoration: underline; }
}
.aud-contributions__td-actions {
  text-align: right;
}
.aud-contributions__unsub a,
.aud-contributions__unsub button {
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-2);
  text-decoration: none;
  background: none;
  border: 1px solid var(--aud-color-rule);
  padding: 4px 10px;
  border-radius: var(--aud-radius-md);
  cursor: pointer;
  font-family: inherit;
}
@media (hover: hover) {
  .aud-contributions__unsub a:hover,
  .aud-contributions__unsub button:hover {
    color: var(--aud-color-link);
    border-color: var(--aud-color-link);
  }
}

.aud-contributions__pagination {
  display: flex;
  justify-content: center;
}

/* --- Mobile --- */
@media (max-width: 720px) {
  .aud-profile__header {
    flex-direction: column;
  }
  .aud-profile__stats {
    padding: var(--aud-space-3);
  }
  /* Hide type column on phones for table breathing room */
  .aud-contributions__table .aud-contributions__th-type,
  .aud-contributions__table .aud-contributions__td-type {
    display: none;
  }
}

/* ----------------------------------------------------------------------------
   Print
---------------------------------------------------------------------------- */
/* ----------------------------------------------------------------------------
   Print: PDF download

   The "Download PDF" button on article pages calls window.print(), which
   the user saves as PDF via the browser's print dialog. This stylesheet
   makes that output look professional:
     - Hides all chrome (header, sidebars, TOC, feedback widget, footer)
     - Cleans up article body for paper sizing
     - Adds a generated footer with article URL and date for traceability
     - Avoids awkward page breaks (orphaned headings, split code blocks)
     - Renders links with inline URLs so PDFs are useful when printed

   Page size / margins are controlled by the @page rule. Browser print
   dialog can override.
---------------------------------------------------------------------------- */
@page {
  size: A4;
  margin: 18mm 16mm 22mm 16mm;
}

/* Per-page running footer with URL and page number, shown at the bottom of
   every printed page. Uses CSS Paged Media (Chrome/Safari/Edge support this
   in the browser print engine). */
@page {
  @bottom-left {
    content: "© 2026 Auditoria.AI";
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 8pt;
    color: #6b7380;
  }
  @bottom-center {
    content: "docs.auditoria.ai";
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 8pt;
    color: #6b7380;
  }
  @bottom-right {
    content: "Page " counter(page) " of " counter(pages);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 8pt;
    color: #6b7380;
  }
}

/* Print-only letterhead — hidden on screen, shown at the top of every
   printed/PDF article. Replaces the older print-logo block. */
.aud-print-letterhead { display: none; }

@media print {
  /* Hide all theme chrome — only the article should print. */
  .aud-utilitybar, .aud-docsnav, .aud-page__rail, .aud-page__toc, .aud-toc-mobile,
  .aud-pagination, .aud-feedback, .aud-feedback-trigger,
  .aud-footer, .aud-rail-toggle, .aud-pdf-btn, .aud-meta-sep--pdf,
  .aud-search-form, .aud-search, .aud-utilitynav,
  .aud-feedback-modal, .aud-page__breadcrumbs nav button,
  header.aud-utilitybar, .aud-page__rail-mobile-toggle {
    display: none !important;
  }

  /* Print-only letterhead at the top of the first page — Auditoria logo on
     the left, "Documentation / docs.auditoria.ai" tagline on the right,
     thin separator below. Branded letterhead feel. Logo and tagline are
     sized to feel balanced — neither dwarfs the other. */
  .aud-print-letterhead {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 18pt;
    padding: 0 0 14pt;
    border-bottom: 0.5pt solid #d1d5db;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .aud-print-letterhead__logo img {
    height: 64pt;
    width: auto;
    max-width: 340pt;
    display: block;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .aud-print-letterhead__tagline {
    text-align: right;
    line-height: 1.3;
  }
  .aud-print-letterhead__tagline-line {
    display: block;
    font-size: 15pt;
    font-weight: 600;
    color: #1a202c;
    letter-spacing: 0.01em;
  }
  .aud-print-letterhead__tagline-sub {
    display: block;
    font-size: 11.5pt;
    color: #6b7380;
    margin-top: 2pt;
  }

  /* Reset layout to single column; article fills the page. */
  body {
    background: #fff;
    font-size: 10.5pt;
    line-height: 1.5;
    color: #1a202c;
    font-family: var(--aud-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
  }
  .aud-page, .aud-page--with-toc {
    display: block;
    grid-template-columns: 1fr;
    padding: 0;
    max-width: none;
    margin: 0;
  }
  .aud-page--with-toc .aud-page__main {
    max-width: none;
    padding: 0;
  }

  /* Article header — title + minimal metadata, no avatar */
  .aud-article__title {
    font-size: 22pt;
    font-weight: 700;
    color: #000;
    line-height: 1.2;
    margin: 0 0 8pt;
    page-break-after: avoid;
  }
  .aud-article__meta {
    font-size: 9pt;
    color: #4a5563;
    margin-bottom: 16pt;
    padding-bottom: 8pt;
    border-bottom: 0.5pt solid #d1d5db;
  }
  .aud-article__meta .aud-byline__avatar { display: none; }
  .aud-article__meta .aud-byline { color: #4a5563; text-decoration: none; }
  .aud-article__meta .aud-byline__by { color: #6b7380; }

  /* Breadcrumbs — keep, but small and quiet */
  .aud-breadcrumbs__list,
  .aud-page__breadcrumbs {
    font-size: 8.5pt;
    color: #6b7380;
    margin-bottom: 4pt;
  }
  .aud-page__breadcrumbs a { color: #6b7380; text-decoration: none; }

  /* Article body */
  .aud-article__body {
    font-size: 10.5pt;
    color: #1a202c;
  }

  /* Headings — keep with following content */
  .aud-article__body h1,
  .aud-article__body h2,
  .aud-article__body h3,
  .aud-article__body h4 {
    page-break-after: avoid;
    page-break-inside: avoid;
    color: #000;
  }
  .aud-article__body h2 { font-size: 14pt; margin-top: 18pt; margin-bottom: 6pt; }
  .aud-article__body h3 { font-size: 12pt; margin-top: 14pt; margin-bottom: 4pt; }
  .aud-article__body h4 { font-size: 10.5pt; margin-top: 12pt; margin-bottom: 4pt; }

  /* Paragraphs and lists */
  .aud-article__body p,
  .aud-article__body li {
    orphans: 3;
    widows: 3;
  }

  /* Links — show URL inline so PDFs remain useful when printed.
     Skip for short anchors and javascript: links. */
  .aud-article__body a[href]:not([href^="#"]):not([href^="javascript:"])::after {
    content: " (" attr(href) ")";
    font-size: 0.85em;
    color: #6b7380;
    word-break: break-all;
  }
  .aud-article__body a {
    color: #1a202c;
    text-decoration: underline;
  }

  /* Code blocks — keep together, smaller font, light background */
  .aud-article__body pre,
  .aud-article__body code {
    font-family: "SF Mono", Menlo, Consolas, monospace;
    font-size: 9pt;
  }
  .aud-article__body pre {
    page-break-inside: avoid;
    background: #f5f6f8;
    border: 0.5pt solid #d1d5db;
    border-radius: 3pt;
    padding: 8pt;
    white-space: pre-wrap;
    word-wrap: break-word;
  }
  .aud-article__body code {
    background: #f5f6f8;
    padding: 1pt 3pt;
    border-radius: 2pt;
  }

  /* Tables — never split rows across pages */
  .aud-article__body table {
    page-break-inside: avoid;
    border-collapse: collapse;
    width: 100%;
    margin: 8pt 0;
    font-size: 9.5pt;
  }
  .aud-article__body table th,
  .aud-article__body table td {
    border: 0.5pt solid #d1d5db;
    padding: 4pt 6pt;
    text-align: left;
    vertical-align: top;
  }
  .aud-article__body table th {
    background: #f5f6f8;
    font-weight: 600;
  }

  /* Images — fit to page width, keep with caption */
  .aud-article__body img {
    max-width: 100%;
    height: auto;
    page-break-inside: avoid;
  }
  .aud-article__body figure {
    page-break-inside: avoid;
    margin: 8pt 0;
  }
  .aud-article__body figcaption {
    font-size: 8.5pt;
    color: #6b7380;
    text-align: center;
    margin-top: 4pt;
  }

  /* Callouts/admonitions — keep as visible boxes */
  .aud-callout {
    page-break-inside: avoid;
    border-left: 2pt solid #2a8ab8;
    padding: 6pt 10pt;
    margin: 8pt 0;
    background: #f5f8fb;
  }

  /* Hide previous/next pagination footer */
  .aud-pagination, .aud-prev-next { display: none !important; }
}


/* ----------------------------------------------------------------------------
   Breadcrumbs (used by dashboard, products, and any future custom page)
---------------------------------------------------------------------------- */
.aud-breadcrumbs__list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--aud-space-2);
  padding: 0;
  margin: 0 0 var(--aud-space-4);
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
}
.aud-breadcrumbs__list li { margin: 0; }
.aud-breadcrumbs__list li::after {
  content: "›";
  margin-left: var(--aud-space-2);
  color: var(--aud-color-text-subtle);
}
.aud-breadcrumbs__list li:last-child::after { content: ""; }

.aud-visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* ----------------------------------------------------------------------------
   Error page (templates/error_page.hbs)
---------------------------------------------------------------------------- */
.aud-error-page {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-8) var(--aud-space-5);
  min-height: 50vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.aud-error-page__inner {
  max-width: 520px;
  text-align: center;
}
.aud-error-page__title {
  font-size: 56px;
  font-weight: 600;
  margin: 0 0 var(--aud-space-3);
  color: var(--aud-color-text);
}
.aud-error-page__subtitle {
  font-size: var(--aud-fs-7);
  font-weight: 600;
  margin: 0 0 var(--aud-space-3);
  color: var(--aud-color-text);
}
.aud-error-page__detail {
  color: var(--aud-color-text-muted);
  margin-bottom: var(--aud-space-5);
}
.aud-error-page__cta {
  margin-top: var(--aud-space-4);
}

/* ----------------------------------------------------------------------------
   Dashboard custom page (templates/custom_pages/dashboard.hbs)
---------------------------------------------------------------------------- */
.aud-dashboard {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-5) var(--aud-space-5) var(--aud-space-8);
}
.aud-dashboard__main { min-width: 0; }

.aud-dashboard__header {
  margin-bottom: var(--aud-space-6);
}
.aud-dashboard__header h1 {
  font-size: 32px;
  font-weight: 600;
  margin: 0 0 var(--aud-space-2);
}
.aud-dashboard__lede {
  margin: 0;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-4);
}

.aud-dashboard__signin {
  text-align: center;
  padding: var(--aud-space-7) var(--aud-space-5);
  background: var(--aud-color-bg-alt);
  border-radius: var(--aud-radius-md);
  border: 1px solid var(--aud-color-rule);
}
.aud-dashboard__signin p { margin: 0 0 var(--aud-space-4); color: var(--aud-color-text-muted); }
.aud-dashboard__signin p:last-child { margin: 0; }

/* Stat tiles */
.aud-dashboard__stats {
  list-style: none;
  padding: 0;
  margin: 0 0 var(--aud-space-6);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--aud-space-4);
}
.aud-stat {
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  padding: var(--aud-space-4);
  display: flex;
  flex-direction: column;
  gap: var(--aud-space-1);
}
.aud-stat__value {
  font-size: 32px;
  font-weight: 600;
  color: var(--aud-color-text);
  line-height: 1.1;
}
.aud-stat__label {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Panels grid */
.aud-dashboard__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--aud-space-5);
}
.aud-dashboard__panel {
  background: #fff;
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-md);
  padding: var(--aud-space-4);
  min-width: 0;
}
.aud-dashboard__panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--aud-space-3);
  gap: var(--aud-space-3);
}
.aud-dashboard__panel-head h2 {
  margin: 0;
  font-size: var(--aud-fs-5);
  font-weight: 600;
}
.aud-dashboard__panel-link {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-link);
  text-decoration: none;
  white-space: nowrap;
}
.aud-dashboard__panel-link:hover { text-decoration: underline; }
.aud-dashboard__list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.aud-dashboard__list li {
  padding: var(--aud-space-2) 0;
  border-bottom: 1px solid var(--aud-color-rule);
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: var(--aud-fs-3);
}
.aud-dashboard__list li:last-child { border-bottom: none; }
.aud-dashboard__list a {
  color: var(--aud-color-link);
  text-decoration: none;
  font-weight: 500;
}
.aud-dashboard__list a:hover { text-decoration: underline; }
.aud-dashboard__meta {
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-subtle);
  display: flex;
  align-items: center;
  gap: var(--aud-space-2);
}
.aud-dashboard__empty {
  color: var(--aud-color-text-subtle);
  font-style: italic;
  font-size: var(--aud-fs-3);
}

/* Status pills (open / pending / solved) */
.aud-status {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.aud-status--open { background: #fff3cd; color: #856404; }
.aud-status--pending { background: #cce5ff; color: #004085; }
.aud-status--solved { background: #d4edda; color: #155724; }
.aud-status--closed { background: var(--aud-color-bg-alt); color: var(--aud-color-text-muted); }

/* ----------------------------------------------------------------------------
   Product Directory custom page (templates/custom_pages/products.hbs)
---------------------------------------------------------------------------- */
.aud-products {
  max-width: var(--aud-content-max);
  margin: 0 auto;
  padding: var(--aud-space-5) var(--aud-space-5) var(--aud-space-8);
}
.aud-products__main { min-width: 0; }
.aud-products__header { margin-bottom: var(--aud-space-6); }
.aud-products__header h1 {
  font-size: 32px;
  font-weight: 600;
  margin: 0 0 var(--aud-space-2);
}
.aud-products__lede {
  margin: 0;
  color: var(--aud-color-text-muted);
  font-size: var(--aud-fs-4);
}
.aud-products__index {
  list-style: none;
  padding: 0;
  margin: 0;
}
.aud-products__group {
  margin-bottom: var(--aud-space-6);
  display: flex;
  gap: var(--aud-space-5);
  align-items: flex-start;
}
.aud-products__letter {
  flex: 0 0 60px;
  font-size: 36px;
  font-weight: 600;
  color: var(--aud-color-text-subtle);
  margin: 0;
  line-height: 1;
}
.aud-products__items {
  list-style: none;
  padding: 0;
  margin: 0;
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--aud-space-3);
}
.aud-products__items li { margin: 0; }
.aud-products__items a {
  display: block;
  padding: var(--aud-space-3);
  border: 1px solid var(--aud-color-rule);
  border-radius: var(--aud-radius-sm);
  text-decoration: none;
  background: #fff;
  transition: border-color 120ms;
}
.aud-products__items a:hover {
  border-color: var(--aud-color-link);
  text-decoration: none;
}
.aud-products__name {
  display: block;
  font-weight: 600;
  color: var(--aud-color-text);
  font-size: var(--aud-fs-3);
  margin-bottom: 2px;
}
.aud-products__desc {
  display: block;
  font-size: var(--aud-fs-2);
  color: var(--aud-color-text-muted);
  line-height: 1.4;
}
.aud-products__loading,
.aud-products__empty {
  text-align: center;
  padding: var(--aud-space-6);
  color: var(--aud-color-text-subtle);
  font-style: italic;
}

/* Mobile: stack groups */
@media (max-width: 700px) {
  .aud-products__group { flex-direction: column; gap: var(--aud-space-2); }
  .aud-products__letter { flex: 0 0 auto; font-size: 24px; }
  .aud-products__items { grid-template-columns: 1fr; }
  .aud-dashboard__stats { grid-template-columns: repeat(2, 1fr); }
  .aud-dashboard__grid { grid-template-columns: 1fr; }
}
