/* Responsive layout layer for the desktop template branch.
   Loaded after newsite.css and menu.css so these rules can override.
   Mobile-detection branch is unaffected (it has its own stylesheets).

   MOBILE-FIRST: base rules (no media query) are the narrow-viewport
   layout; @media (min-width: …) blocks progressively enhance as more
   room becomes available. Enhancement tiers, matching the same pixel
   thresholds the site has always used:
     - 340px  small phones -> the search box gets a little more room
     - 700px  topbar chrome only (logo/nav/search/badge/toggle) steps
              up early -- two browser windows snapped side-by-side on
              a single monitor commonly land in the 700-767px range,
              and that chrome has room to grow well before 768px
     - 768px  tablets -> row layouts for everything else (tiles,
              tables, footer, etc.)
     - 1041px desktop -> single-row topbar, static left-column menu */

/* Scroll anchoring (on by default in Chrome) watches for layout shifts
   near the top of the viewport and silently adjusts scrollY to
   compensate, so content already on screen doesn't visibly jump. The
   sticky header shrinking/growing on scroll (below) IS exactly that
   kind of shift -- each toggle nudges scrollY, which can walk it back
   across the shrink/grow thresholds in shrinkheader.js and toggle the
   class again, repeating for as long as the user keeps scrolling
   through that range. Disabling anchoring site-wide avoids the
   feedback loop; nothing else here depends on it. */
html { overflow-anchor: none; }

/* ===== Shared top bar ===== */
.aac-topbar { background-color: #d0d4d9; position: sticky; top: 0; z-index: 50; }
/* Compressed tier only, and only once shrunk (scrolled/is-shrunk, see
   shrinkheader.js): at rest .aac-bandred (the red accent normally
   sitting under the tiles) is still on screen just below the header,
   so no border is needed there -- adding one too would show two red
   lines at once. Once scrolled past SHRINK_AFTER_PX, .aac-bandred has
   already scrolled out from under the sticky header, so this border
   is the only accent visible, and (being on the sticky element itself)
   it stays put at every scroll position from then on. */
@media (max-width: 1040px) {
  .aac-topbar.is-shrunk { border-bottom: 2px solid var(--color-brand); }
}
.aac-topbar__inner {
  position: relative; /* anchors .aac-topbar__controls below 1041px */
  max-width: 1200px;
  margin: 0;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  text-align: left;
  gap: 4px 12px;
  /* Vertical padding scaled 1.33x (4px -> 5px) from the pre-compressed
     baseline below, as part of the compressed header's overall +33%
     height -- see the icon/logo/badge sizes further down, scaled the
     same factor so nothing looks undersized in the taller bar. */
  padding: 5px 8px;
}
/* At desktop width the original anchors the 1200 content block to the
   left inside the full-width bar, single row, natural DOM order. */
@media (min-width: 700px) {
  .aac-topbar__inner { gap: 2px 16px; padding: 5px 12px; }
}
@media (min-width: 1041px) {
  /* Sticky-on-scroll is a compressed/mobile-only affordance (matches
     the shrink-on-scroll behavior, also desktop-tier-excluded) -- the
     original fixed-table site never had a floating header at full
     desktop width, and it wasn't wanted here either. */
  .aac-topbar { position: static; }
}
/* The pixel-perfect layout below (reproducing www.audioauthority.com's
   original fixed-table header exactly, measured directly against it)
   needs ~1168px of width to lay out its fixed margins/widths on one
   line without overlap. 1041-1169px is still "desktop tier" (single-
   row topbar, no hamburger) but too narrow for that -- rather than
   let the fixed-margin rules either wrap the faith icon down onto the
   tiles row (flex-wrap's default behavior) or clip content out of
   view (overflow-x:auto's behavior, tried and rejected: it scrolled
   "Contact Us"/"Blogs"/part of the search box and the faith icon out
   of sight with no visible scrollbar cue), this narrow band keeps the
   older flexible/auto-margin layout instead. It won't be pixel-
   identical to the original there, but nothing is hidden or
   overlapping -- and the original itself needed real page-level
   horizontal scrolling below 1200px, so an approximation here is a
   reasonable trade, not a regression. */
@media (min-width: 1170px) {
  /* Reproduces the original fixed-table header's exact pixel layout at
     this tier (measured directly against a live render of
     www.audioauthority.com): the old table's columns summed to a fixed
     ~1200px-wide block that stayed centered in the gray bar as the
     viewport grew past 1200px, with a 22px inset before the logo and
     nothing matching it on the right -- the original isn't actually
     symmetric (measured ~374.5px logo-to-viewport-left vs ~396px
     cross-to-viewport-right at 1920px), so don't "fix" that into
     symmetry; match it. gap:0 + per-child margin-left below (not the
     container's own gap) since the original columns' spacing isn't
     uniform. align-items:flex-start + an explicit height/per-child
     margin-top replaces center-alignment because the original's
     vertical position per element (nav text and the search box both
     sit close to the bar's bottom edge, not centered) isn't a simple
     "everything centered" pattern either. */
  .aac-topbar__inner {
    gap: 0;
    padding: 0 0 0 22px;
    margin: 0 auto;
    height: 64px;
    align-items: flex-start;
    /* border-box so max-width:1200px is the box's TOTAL width
       (padding included) -- otherwise the 22px inset padding adds on
       top of it, making the true rendered box 1222px and throwing off
       the margin:auto centering math on viewports wider than 1200px. */
    box-sizing: border-box;
    flex-wrap: nowrap;
  }
  /* flex-shrink:0 -- these all carry hardcoded margins/widths designed
     for a single unbroken line (see .aac-topbar__inner above); letting
     any of them shrink under space pressure just overlaps neighboring
     text instead of degrading gracefully. Safe now that this only
     applies at/above the ~1168px content actually needs. */
  #logo,
  .aac-topnav,
  .aac-search,
  .aac-topbar__controls { flex-shrink: 0; }
}
/* Explicit width:auto so any later height cap (the 20px mobile row) or a
   horizontal squeeze rescales this by its intrinsic ratio (46x50)
   instead of squashing a fixed width. Sized up from the original 20px
   cap since that was well under the row's available height on the
   smallest phones -- free space, not spent on anything else. */
.aac-topbar__faith img { width: auto; height: 29px; max-width: 100%; }
/* Locks the badge's box to its real intrinsic ratio via CSS alone --
   without it, "width:auto" has nothing to resolve against until the
   browser has actually decoded enough of the image to know its natural
   size, which on a slower connection can lag the initial layout pass
   by tens of ms: the badge briefly lays out at 0 width, then snaps to
   its true width once the image resolves, visibly shoving
   .aac-topnav/.aac-search (everything after it in the row) sideways by
   that same amount. Modern browsers can synthesize this same ratio
   from the <img>'s width/height attributes on their own, but that
   isn't reliable enough here to skip declaring it explicitly
   (confirmed via the Layout Instability API: a real, measured shift at
   this exact spot, image-timing-dependent, without this rule -- caught
   originally on this element's now-removed sibling,
   .aac-topbar__years, an always-blank 40th-anniversary badge deleted
   entirely once its source PNG turned out to be 100% transparent). */
.aac-topbar__faith img { aspect-ratio: 46 / 50; }
/* ===== Image-link hover ("ghost" dip) =====
   One shared indicator for every link whose clickable content is a
   photographic image rather than recolorable text or a glyph (the nav
   text and admin glyphs swap color instead; an image can't). It started
   here on the header's faith icon and on the footer's social sprites,
   both of which used to carry their own copy of these three lines.
   The third selector standardizes the same feedback across the page
   body -- product grid cards and detail/gallery photos, blog card
   thumbnails, brand and dealer logos, download icons. It's written
   structurally, as "any body link containing an image", rather than as
   a class each template opts into, because ~335 of the site's image
   links are authored inside products.long_desc and pages.content and no
   class could reach those without editing the DB row by row.
   Scoped to .aac-body so it never touches the header's own logo, nav or
   category tiles, which sit outside it and have their own hover states.
   :has() is unsupported on browsers older than ~2023; there an image
   link simply doesn't dip, which is exactly today's behavior. */
.aac-topbar__faith,
.footer_links__btn a,
.aac-body a:has(img) { transition: opacity .15s ease; }
.aac-topbar__faith:hover,
.aac-topbar__faith:focus-visible,
.footer_links__btn a:hover,
.footer_links__btn a:focus-visible,
.aac-body a:has(img):hover,
.aac-body a:has(img):focus-visible { opacity: .7; }
/* Capped through the compressed (700-1040px, hamburger) tier too --
   letting these go back to their large intrinsic size there is what
   was stretching the whole two-row bar tall and leaving the short
   elements (toggle/search) looking vertically stranded. Only the
   uncompressed single-row desktop tier gets the full-size badge. */
@media (min-width: 700px) {
  .aac-topbar__faith img { height: 37px; }
}
@media (min-width: 1041px) {
  /* Explicit natural height, not "auto": with both width and height
     auto, "aspect-ratio" alone can't resolve a size for a replaced
     element (<img>) before its data has actually arrived -- see the
     comment above the aspect-ratio declaration. Pinning height to the
     badge's own real height gives the exact same rendered size ("auto"
     here was always going to land on the natural 50px anyway) but
     computes it immediately from CSS instead of waiting on the image. */
  .aac-topbar__faith img { height: 50px; }
}
/* Shrinks the sticky bar to ~2/3 size once scrolled away from the top,
   via a JS-toggled class (javascript/shrinkheader.js) -- transitions
   smoothly back to full size on scrolling back up. Targets the actual
   properties that drive the bar's rendered height (padding/gap/image
   height) rather than a CSS transform, so the sticky box's real height
   shrinks (freeing scroll space) instead of just scaling visually
   while leaving blank space beneath it. */
#logo,
.aac-topbar__inner,
.aac-topbar__faith img,
.aac-topnav .menu_links,
.aac-search-toggle,
.aac-menu-toggle,
.aac-search-toggle__icon,
.aac-search-toggle__icon::after,
.aac-sidemenu__icon {
  transition: padding .2s ease, gap .2s ease, height .2s ease, width .2s ease, right .2s ease, bottom .2s ease, top .2s ease, font-size .2s ease, background-size .2s ease;
}
/* Only applies below the 1041px desktop tier -- the compressed
   (hamburger) header shrinks on scroll, the full-width desktop bar
   does not. */
@media (max-width: 1040px) {
  .aac-topbar.is-shrunk .aac-topbar__inner { padding: 2px 4px; }
  .aac-topbar.is-shrunk #logo { width: 78px; height: 20px; }
  .aac-topbar.is-shrunk .aac-topbar__faith img { height: 14px; }
  /* Magnifying-glass and hamburger toggle buttons scale down with the
     rest of the bar -- both the tap-target padding and the glyph
     itself, so the icon doesn't end up floating in oversized empty
     button chrome once everything else has shrunk. */
  .aac-topbar.is-shrunk .aac-search-toggle,
  .aac-topbar.is-shrunk .aac-menu-toggle { padding: 6px; }
  .aac-topbar.is-shrunk .aac-search-toggle__icon { width: 10px; height: 10px; }
  .aac-topbar.is-shrunk .aac-search-toggle__icon::after { right: -4px; bottom: -4px; width: 5px; }
  .aac-topbar.is-shrunk .aac-sidemenu__icon { width: 12px; height: 10px; }
  .aac-topbar.is-shrunk .aac-sidemenu__icon span:nth-child(2) { top: 4px; }
  .aac-topbar.is-shrunk .aac-sidemenu__icon span:nth-child(3) { top: 8px; }
  /* Fingertip spacing once shrunk. The glyphs stay small, but each
     control's hit box is widened to ~44px (a fingertip) with no gap
     between them, so neighbors now meet edge to edge instead of being
     22px targets 5px apart -- tapping search no longer lands on the
     hamburger, and so on down the row. Only the width grows; the 26px
     shrunk bar height is unchanged. Worst case (both check_ip() admin
     glyphs present) is 5 x 44 = 220px, inside the 458px .aac-topnav
     already reserves for this cluster at 700-1040px. */
  .aac-topbar.is-shrunk .aac-topbar__controls { gap: 0; }
  .aac-topbar.is-shrunk .aac-search-toggle { padding: 6px 17px; }
  .aac-topbar.is-shrunk .aac-menu-toggle { padding: 6px 16px; }
  .aac-topbar.is-shrunk .aac-admin-controls--compressed { display: inline-flex; }
  .aac-topbar.is-shrunk .aac-admin-controls--compressed .aac-admin-glyph { min-width: 44px; padding: 3px 0; box-sizing: border-box; }
  .aac-topbar.is-shrunk .aac-topbar__faith { justify-content: center; min-width: 44px; padding: 4px 0; box-sizing: border-box; }
}
@media (min-width: 700px) and (max-width: 1040px) {
  .aac-topbar.is-shrunk .aac-topbar__inner { padding: 2px 6px; gap: 1px 8px; }
  .aac-topbar.is-shrunk #logo { width: 107px; height: 28px; }
  .aac-topbar.is-shrunk .aac-topbar__faith img { height: 19px; }
}
#logo { order: 1; }
.aac-topnav { order: 3; }
@media (min-width: 1041px) {
  #logo,
  .aac-topnav { order: 0; }
}
/* Search toggle, menu toggle, and the cross badge live in one wrapper
   so they always move as a unit -- previously each carried its own
   order/margin-left:auto and, at some widths, wrapped independently of
   each other (the cross ending up alone on its own line). Below
   1041px the wrapper is pinned to the top bar's right edge with
   position:absolute, which keeps the cross (and its neighbors) flush
   right at every width with nothing to wrap away from; .aac-topnav's
   own padding-right (above) reserves the room so nav text never runs
   underneath it. At 1041px+ it drops back into the normal static flow
   in its original document position (matches production: search box,
   then the cross, at the end of the row) -- only the cross stays
   visible there, since the two toggle buttons are hidden. */
.aac-topbar__controls { display: flex; align-items: center; gap: 5px; }

/* Two copies of the same Edit/Admin glyphs exist in the markup
   (templates/desktop_header.php) -- only one is ever shown per
   breakpoint:
     --compressed (below 1041px): rides in .aac-topbar__controls next
       to the hamburger, in a cluster .aac-topnav's own padding-right
       (above) already budgets room for.
     --wide (1041px+, no hamburger at this tier): .aac-topbar__inner
       has no slack anywhere in this range for a normal flex child --
       .aac-navpath tried sharing the first line as a flex item (see
       its own comment in this file for what broke), and a fixed-
       width margin-left compensation on .aac-topbar__controls (tried
       next) broke again on pages with variable-length content, and a
       third attempt letting this wrap onto .aac-navpath's own second
       line (visually correct but not "the same row as the hamburger"
       the request asked for) got overruled. So this copy is pulled
       out of flex flow entirely instead: position:absolute with
       right:100% relative to .aac-topbar__controls (itself
       position:relative from 1041px up) anchors its right edge to
       that box's LEFT edge exactly, whatever that computes to --
       contributing zero width to .aac-topbar__controls' own flex
       sizing, so that box (and the faith icon inside it) renders at
       literally the same position as if this had no content in it at
       all, on the same visual row as everything else, regardless of
       how long $navpath's own text runs. */
.aac-admin-controls--wide { display: none; }
@media (min-width: 1041px) {
  .aac-admin-controls--compressed { display: none; }
  .aac-admin-controls--wide {
    position: absolute;
    top: 50%;
    right: 100%;
    transform: translateY(-50%);
    margin-right: 10px;
    display: inline-flex;
    align-items: center;
    gap: 2px;
    white-space: nowrap;
  }
}

/* Shared glyph styling for both copies above.
   Mobile-first: base (below 700px) is the compact size. Below 700px
   .aac-topnav is already hidden (own rule further down) and nothing
   reserves room for .aac-topbar__controls the way .aac-topnav's
   padding-right does at 700-1040px -- the pinned cluster has only
   ever fit there because it stayed small, so these stay tight here
   rather than shrinking that margin against the logo on the
   narrowest phones. Sized back up from 700px, where padding-right
   on .aac-topnav already reserves the extra room. */
.aac-admin-glyph {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px;
  color: var(--color-icon);
  text-decoration: none;
}
.aac-admin-glyph:hover,
.aac-admin-glyph:focus-visible { color: var(--color-brand); }
.aac-admin-glyph__icon {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
@media (min-width: 700px) {
  /* .aac-topnav's padding-right (below) already budgets for this
     full size, so no overlap risk here the way there is below 700px. */
  .aac-admin-glyph { padding: 8px; }
  .aac-admin-glyph__icon { width: 19px; height: 19px; }
}

/* Minimal CSS-only tooltip, shared by any element carrying
   data-tooltip -- shows on hover and keyboard focus alike (unlike the
   native title attribute, which keyboard focus never triggers). */
[data-tooltip] { position: relative; }
[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translate(-50%, 4px);
  background-color: #222222;
  color: #ffffff;
  font-size: 11px;
  font-weight: normal;
  line-height: 1.4;
  white-space: nowrap;
  padding: 4px 8px;
  border-radius: 4px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .15s ease, transform .15s ease;
  z-index: 70;
}
[data-tooltip]:hover::after,
[data-tooltip]:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 8px);
}

@media (max-width: 1040px) {
  .aac-topbar__controls {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    z-index: 2;
  }
}
@media (min-width: 700px) and (max-width: 1040px) {
  .aac-topbar__controls { right: 12px; }
}
@media (min-width: 1041px) {
  /* position:relative (not static) purely so .aac-admin-controls--wide
     (above) has this box as its positioning context from this tier up
     -- relative with no top/left/right/bottom offset on the element
     itself is visually and layout-wise identical to static for its
     own flow position, so this changes nothing else. */
  .aac-topbar__controls { position: relative; gap: 24px; order: 0; }
}
@media (min-width: 1041px) and (max-width: 1169px) {
  /* Unlike the 1170px+ tier below, .aac-topbar__inner is flex-wrap:wrap
     here and .aac-topbar__controls has no fixed margin-left of its own
     -- .aac-topbar__controls just sits wherever normal flex flow (a
     plain 16px column-gap) puts it after .aac-search, ~16px away.
     .aac-admin-controls--wide needs ~72px to sit in front of it without
     overlapping the search box (confirmed by measuring a real render,
     not guessed) -- added here as extra margin-left rather than eating
     the existing 16px gap. .aac-topnav (flex:1 1 auto, the only
     flex-grow item in this row) simply grows ~74px less to compensate;
     it isn't flex-shrink:0/nowrap-constrained at this tier the way it
     is at 1170px+, so this doesn't reproduce the wrapping bug that
     forced .aac-admin-controls--wide out of flex flow in the first
     place -- confirmed in a real render across the full 1041-1169
     range, not assumed from the 1170px+ case. */
  .aac-topbar__controls { margin-left: 90px; }
}
@media (min-width: 1170px) {
  /* margin-left replaces the container's own gap (now 0 on the parent
     at this tier) as the exact spacing after the search box (measured
     ~114px against a live render of www.audioauthority.com; 112px
     reproduces it almost exactly) -- NOT margin-left:auto/flush to the
     right edge, which was tried and overshot: the original cross badge
     sits a fixed distance after the search box, not pinned to the bar's
     right inset -- see .aac-topbar__inner's comment above for why the
     original layout isn't actually left/right-symmetric in the first
     place. margin-top matches the original's faith-icon position (7px
     below the bar's top -- coincidentally already correct under plain
     vertical centering, but pinned explicitly now that the container
     uses flex-start instead). */
  .aac-topbar__controls { margin-left: 112px; margin-top: 7px; }
}
/* Matches the 8px padding on the two icon buttons beside it so the
   row reads as one evenly spaced control cluster instead of the cross
   sitting flush against its neighbors while they carry visible padding. */
@media (max-width: 1040px) {
  .aac-topbar__faith { display: inline-flex; align-items: center; padding: 11px; }
}
/* A real flex box at every tier (never display:contents -- that unwrap
   trick is inconsistently supported across browsers, particularly for
   order/gap on its children, and was the cause of the compressed-tier
   bar rendering full-height/gappy in some browsers while measuring
   correctly in headless Chromium). flex:1 1 auto + min-width:0 lets it
   shrink to share row one with the logo; margin-left:auto plus its own
   justify-content:flex-end keeps the links flush right the same way a
   real flex container naturally does. */
.aac-topnav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 4px 8px;
  flex: 1 1 auto;
  min-width: 0;
  margin-left: auto;
}
/* Caps how far .aac-topnav's flex-grow can expand at 700-1040px, so
   its right-aligned links never grow underneath .aac-topbar__controls,
   which is pinned via position:absolute at this tier and so no longer
   takes up space in the normal flex flow for anything else to defer
   to. Placed here, immediately after the base rule above (not back up
   in the earlier @media(700px) block this file otherwise groups
   tier-specific overrides into) because CSS cascade order is source
   order for equal-specificity rules, media query nesting notwithstanding
   -- a version up there was silently losing to this base rule's own
   margin-left/flex declarations every time (confirmed in a real
   render, the same way .aac-topnav's flex-shrink:0 at the 1170px tier
   loses to this same base rule's flex:1 1 auto -- see that comment
   futher down for the matching case).

   Two things had to change together:
   - max-width, not padding-right: padding counts toward the item's
     own hypothetical size for the *wrap* decision (does this line's
     content fit at all), not just its rendered size, so a 260px
     padding-right previously meant "logo + years-badge + topnav-with-
     padding" stopped fitting on one line well before the viewport was
     actually too narrow for the *visible* content (About Us/Support/
     Contact Us/Blogs) to fit, wrapping readable nav text down even
     though there was plenty of room for it (confirmed in a real
     render: topnav's own linked content measures ~235px, comfortably
     under the ~450-500px actually available at the widths that
     broke). A same-sized empty flex-basis spacer sibling was tried
     next, expecting it to hold that space open on line 1 -- instead,
     once the line didn't have room for both, flex-wrap relocated the
     *spacer* to its own line entirely while leaving topnav free to
     grow into the space the spacer would have held, reproducing the
     overlap. max-width sidesteps this: it doesn't participate in the
     initial per-line fit calculation the way flex-basis (padding, or
     a sibling's width) does, so it can't force anything to wrap -- it
     only clamps topnav's size after flex-grow has already been
     resolved for whichever line it landed on.
   - margin-left:0, overriding the base rule's auto: margin-left:auto
     fills all available space on this box's left by design -- with
     max-width alone, a narrower cap just pushed the whole (now-
     narrower) box further right via that auto margin instead of
     shrinking where its right edge lands, keeping it flush against
     the row's end and still overlapping .aac-topbar__controls
     regardless of the cap (also confirmed in a real render). 0 here
     lets the box sit at its natural flow position right after the
     years badge instead -- .aac-topnav's own justify-content:flex-end
     still right-aligns the links within that (now correctly bounded)
     box, and max-width leaves the reserved room genuinely empty
     rather than re-filled by the auto margin.

   515px leaves a ~260px max-width cap at 700px narrowing down toward
   ~500px at 1040px, matching .aac-topbar__controls' actual width --
   search-toggle (~41px) + menu-toggle (~46px) + the two check_ip()-
   gated admin glyphs (~35px each, only present for authorized
   viewers) + faith badge (~49px) + gaps -- plus its right inset
   (12px) and a buffer. Sized for the admin-glyphs-present case on
   purpose: reserving the same room whether or not they're actually
   rendered keeps this row identical for every viewer instead of only
   avoiding overlap for the public case and colliding with .aac-topnav
   for authorized ones. */
@media (min-width: 700px) and (max-width: 1040px) {
  .aac-topnav { max-width: calc(100% - 458px); margin-left: 0; }
}
/* Below 760px there's no way to fit these four links as legible text
   next to the logo and the three icon controls on the same line (the
   text alone needs roughly 200px more than a phone has left over) --
   so at that width they live in the hamburger drawer instead (see
   desktop_header.php's $aac_sidebar / $aac_sidebar_is_fallback and
   .aac-sidemenu__toplinks below), keeping the top bar to one row: logo
   + hamburger + search + cross, which always fits. From 760px up
   there's room for the real thing inline, as before. (Was 700px;
   raised once the logo/icons/badge grew ~33% for the compressed
   header's larger size -- the bigger chrome needs the extra ~60px
   before nav fits alongside it without wrapping.) */
@media (max-width: 759px) {
  .aac-topnav { display: none; }
}
@media (min-width: 1041px) {
  .aac-topnav { flex: initial; }
}
@media (min-width: 1170px) {
  /* margin-top, not align-items:center -- the original nav text sits
     close to the bar's bottom edge (7px above it), not vertically
     centered in the 64px row. margin-left:172px (not auto -- this
     comes after the unconditional margin-left:auto rule above in the
     cascade, so it wins) replaces the flex-fill-then-push-right
     pattern with the original's fixed gap after the logo: measured
     directly against a live render of www.audioauthority.com (172px
     from the logo's right edge to "About Us"), not the 39px this used
     to be -- the original table had a 150px-wide "40 Years" badge
     column between the logo and nav that this markup never
     reintroduced after the badge itself was dropped (blank/transparent
     PNG), so only the small ~22px gap trailing that column survived
     here, leaving the whole nav+search+admin+cross cluster shifted
     150px left of the original's actual position. flex-shrink:0
     repeated here (not just at the 1170px block up near #logo)
     because it needs to win over .aac-topnav's own later `flex:
     initial` rule (@media min-width:1041px, below) -- same class
     selector, so equal specificity means whichever is LAST in source
     order wins, and that unconditional rule sits after both
     flex-shrink:0 declarations. Confirmed in a real render: without
     this, a ~1170-1182px window is just narrow enough for `flex:
     initial`'s re-enabled shrink to wrap "Blogs" onto its own line,
     which then overflows .aac-topbar__inner's fixed 64px height and
     overlaps the tiles row underneath. */
  .aac-topnav { gap: 6px 25px; margin-top: 41px; margin-left: 172px; flex-shrink: 0; }
}
/* Smallest state: padding gives each link a >=44px-tall tap target
   with real breathing room from its neighbors (the container's own
   gap), not just the 2px of text padding these had before — thumbs
   miss 1px gaps. font-size bumped from the original 10px too, since a
   375px-wide phone screen was leaving this smaller than the compressed
   tablet tier ever needed to be. */
/* Overrides newsite.css's sitewide .menu_links color (#738791 on white
   elsewhere, only 2.5:1 against this bar's #d0d4d9) — scoped to the top
   bar only since the footer's own .menu_links sits on a different
   background and is out of scope here. */
.aac-topnav .menu_links { padding: 12px 8px; white-space: normal; font-size: 13px; display: inline-block; color: var(--color-link-muted-aa); }
/* Same hover/focus treatment as the pencil (edit) and gear (admin)
   glyphs next to these links (.aac-admin-glyph, above) -- brand red on
   hover/keyboard-focus instead of just the underline the browser
   default gives an unvisited link. */
.aac-topnav .menu_links:hover,
.aac-topnav .menu_links:focus-visible { color: var(--color-brand); }
@media (min-width: 700px) {
  .aac-topnav .menu_links { padding: 8px 0 10px 0; font-size: 1.077em; }
}
@media (min-width: 1041px) {
  .aac-topnav .menu_links { white-space: nowrap; }
}
@media (min-width: 1170px) {
  /* Padding zeroed here -- the tap-target padding from the 700px tier
     is what was pushing this link's rendered box (and thus the whole
     .aac-topnav item's height) well past the original's tight 16px. */
  .aac-topnav .menu_links { padding: 0; line-height: 16px; }
}
.aac-menu-toggle { margin: 0; }
/* Below 1041px .aac-search is no longer a persistent text box in the
   flow (there's no room for one once it's sharing the logo's row) --
   it's a hidden dropdown panel, opened by .aac-search-toggle, that
   floats under the top bar the same way .aac-sidemenu's dropdown does
   (JS sets the exact top offset and mirrors the same open/close
   mechanics, including closing each other so the two panels can never
   be open at once). At 1041px+ it reverts to the original always-
   visible inline search box and the toggle button is hidden. */
.aac-search { align-items: center; position: relative; }
@media (max-width: 1040px) {
  .aac-search { display: none; }
  .aac-search.is-open {
    display: flex;
    position: fixed;
    top: 64px; /* fallback; JS sets the exact offset below the top bar */
    left: 10%;
    right: 10%;
    z-index: 60;
    background: #ffffff;
    border: 1px solid var(--color-border-light);
    border-radius: 3px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, .2), 0 2px 6px rgba(0, 0, 0, .12);
    padding: 12px;
    box-sizing: border-box;
  }
}
@media (min-width: 1041px) {
  .aac-search { display: inline-flex; flex: initial; }
}
@media (min-width: 1170px) {
  /* margin-left replaces the container's own gap (now 0); margin-top
     matches the original search box's position (close to the bar's
     bottom edge, not centered -- same pattern as .aac-topnav above). */
  .aac-search { margin-left: 81px; margin-top: 30px; }
}
/* Typed text stays at the body's normal dark color (readable input, not
   dimmed); only the placeholder itself uses a lighter gray, and only at
   a shade (#767676 on white = 4.54:1) that still clears AA. Previously
   the field was permanently #888888 (3.5:1) with JS swapping it back to
   the default on focus/blur -- a real <input placeholder> needs none of
   that. */
.aac-search #search { width: 111px; max-width: 45vw; height: 26px; font-size: 13px; margin-right: 0; vertical-align: middle; box-sizing: border-box; border-radius: 3px; padding-right: 24px; }
.aac-search #search::placeholder { color: var(--color-placeholder-gray); opacity: 1; }
/* Inside the open dropdown panel the field owns the panel's full
   width instead of the narrow inline-box sizing above. */
.aac-search.is-open #search { width: 100%; max-width: none; height: 38px; font-size: 16px; padding-right: 44px; }
@media (min-width: 1041px) {
  .aac-search #search { width: 170px; max-width: none; }
}
@media (min-width: 1170px) {
  /* box-sizing:border-box so the declared 200x26 is the actual
     rendered footprint (matching the original input's box exactly)
     regardless of this input's own border/padding, rather than having
     those add on top of it as they would under content-box. */
  .aac-search #search { width: 205px; height: 26px; box-sizing: border-box; }
}
/* Embedded inside the input's own box (like a magnifying-glass icon,
   but on the right and a distinct filled pill rather than a bare glyph)
   instead of sitting beside it as a separate piece -- absolutely
   positioned over the input's right end, with the input's own
   padding-right reserving room so typed text never runs under it. A
   single arrow glyph, not a label (too wide for this compact box) and
   not a second magnifying glass (the mobile search toggle already has
   one). The arrow is drawn (border-only chevron), not a Unicode
   character -- a real glyph's own font metrics fight flex centering and
   render off-center; a drawn shape centers exactly regardless of font. */
.aac-search-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  right: 3px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  box-sizing: border-box;
  padding: 0;
  margin: 0 1px 0 0;
  background-color: transparent;
  /* No box: the input this sits inside already draws one, and a second
     border around the arrow read as a control nested in a control. The
     chevron alone is the affordance, so hover/active recolor the
     chevron (below) rather than filling a pill behind it.
     border-radius is kept even with no border or background of its own:
     the browser's focus ring follows it, so a keyboard user gets a
     rounded ring instead of a hard square. */
  border: 0;
  border-radius: 3px;
  cursor: pointer;
}
.aac-search-submit:hover .aac-search-submit__arrow { border-color: var(--color-brand); }
.aac-search-submit:active .aac-search-submit__arrow { border-color: var(--color-brand-active); }
.aac-search.is-open .aac-search-submit { right: 18px; width: 30px; height: 30px; }
.aac-search-submit__arrow {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-top: 2px solid var(--color-tile-bg);
  border-right: 2px solid var(--color-tile-bg);
  /* Centering correction, part of the transform rather than a margin so
     the amount is exactly what it says (a negative margin on a centered
     flex item moves the box by only HALF its value, which is why the
     -1px this replaced corrected 0.5px of a needed 1.7px).

     Why any correction: flex centers this element's BOX, but the ink
     inside it is only the top and right borders of a square, rotated --
     so the drawn chevron sits in the right half of that box and lands
     right of the button's center. Measured on the rendered button at
     16x: ink 8.19px from the left edge and 4.81px from the right, so
     half the 3.38px difference brings the gaps level. Vertically it was
     already exact (4.38px top and bottom) -- rotating the L-shape
     cancels the vertical offset but doubles the horizontal one. */
  transform: translateX(-1.7px) rotate(45deg);
}
/* Same shape 1.5x larger. The nudge is measured the same way rather
   than scaled from the one above -- 1.5x of it still left a 0.7px lean,
   since the correction lands on a different subpixel boundary in a 30px
   button than in a 20px one. Measured: 9.75px and 9.69px of gap --
   level to well under a device pixel. */
.aac-search.is-open .aac-search-submit__arrow {
  width: 9px;
  height: 9px;
  border-width: 3px;
  transform: translateX(-3.15px) rotate(45deg);
}
/* Search toggle: same icon-button footprint and tap target as
   .aac-menu-toggle, only shown in the compressed tiers where the
   search box collapses into this button + the dropdown above. */
.aac-search-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  padding: 11px;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
@media (min-width: 1041px) {
  .aac-search-toggle { display: none; }
}
.aac-search-toggle:hover .aac-search-toggle__icon,
.aac-search-toggle:hover .aac-search-toggle__icon::after { border-color: #222222; background-color: #222222; }
/* Drawn to match the hamburger icon's stroke weight (2px, var(--color-icon))
   rather than reusing the search input's own glass, which is sized for
   sitting inside a 26px-tall text input, not as a standalone tap
   target. Sized 1.33x the original 14px circle (part of
   the compressed header's overall +33% height/icon scale-up); the
   2px stroke and border-radius stay constant so the ring doesn't blur
   at a fractional weight. */
.aac-search-toggle__icon {
  position: relative;
  display: inline-block;
  width: 19px;
  height: 19px;
  border: 2px solid var(--color-icon);
  border-radius: 50%;
  box-sizing: border-box;
}
.aac-search-toggle__icon::after {
  content: "";
  position: absolute;
  right: -8px;
  bottom: -7px;
  width: 9px;
  height: 2px;
  background-color: var(--color-icon);
  border-radius: 1px;
  transform: rotate(45deg);
  transform-origin: right center;
}
/* The same glass, drawn at text-field scale, for the always-visible
   desktop input. It replaces images/header/search.gif -- a 20x19 raster
   that was soft on any 2x display and cost a request for ~200 bytes.

   Drawn on the form rather than the input because an <input> cannot
   carry pseudo-elements; .aac-search is already position:relative for
   the submit button, and both halves are absolutely positioned so they
   never become flex items. #search keeps its padding-left, which is
   what stops typed text running under the glyph.

   Colour is --color-placeholder-gray rather than the GIF's own #9a9b9b:
   the glyph sits directly beside placeholder text in the same box, and
   matching it makes the two read as one thing instead of two greys. */
.aac-search::before,
.aac-search::after {
  content: "";
  position: absolute;
  pointer-events: none;
}
.aac-search::before {
  left: 6px;
  top: 50%;
  width: 11px;
  height: 11px;
  margin-top: -6px;
  border: 2px solid var(--color-placeholder-gray);
  border-radius: 50%;
  box-sizing: border-box;
}
.aac-search::after {
  left: 14px;
  top: 50%;
  margin-top: 2px;
  width: 5px;
  height: 2px;
  background-color: var(--color-placeholder-gray);
  border-radius: 1px;
  transform: rotate(45deg);
  transform-origin: left center;
}
/* Open state (compressed tier) puts 12px of panel padding around the
   input, so the glyph shifts with it rather than sitting in the panel
   margin. */
@media (max-width: 1040px) {
  .aac-search.is-open::before { left: 18px; }
  .aac-search.is-open::after { left: 26px; }
}

/* Persistent floating scroll-to-top button (javascript/scrolltop.js
   toggles the `hidden` attribute once the page has scrolled past a
   threshold). Sits below the sidemenu/search dropdowns' z-index (60)
   so an open dropdown always wins if they'd ever overlap. */
.aac-totop {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: fixed;
  right: 16px;
  bottom: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 0;
  background-color: var(--color-brand);
  /* The 1px white spread is the gap between the button and the progress
     ring (::before sits 1px further out to leave room for it). Painted
     here rather than left as a hole so the gap stays white over the grey
     footer too, and the drop shadow follows on the second layer. */
  box-shadow: 0 0 0 1px #ffffff, 0 2px 8px rgba(0, 0, 0, .3);
  cursor: pointer;
  z-index: 40;
  -webkit-tap-highlight-color: transparent;
}
.aac-totop:hover { background-color: var(--color-brand-hover); }
.aac-totop[hidden] { display: none; }
/* Scroll-progress ring hugging the button, with a white dot riding it.
   `--aac-progress` is written by scrolltop.js as a turn value (0 at the
   top of the document, 1 at the bottom). The arc *behind* the dot --
   12 o'clock clockwise round to it, the part of the page already read --
   is dark grey; ahead of the dot the ring is brand red. So an untouched
   page shows a plain red ring and the grey eats it as you scroll.
   The negative inset is the track width plus the 1px white gap that
   .aac-totop's own box-shadow paints, so the ring's inner edge clears
   the button by exactly that hairline.
   Geometry note: the ring is `padding: 4px` masked with content-box XOR
   border-box, NOT a radial-gradient mask. A radial-gradient mask fades
   across its stop, and on a track this thin the fade is most of the
   track -- at fractional device pixel ratios that rendered as a dashed,
   gappy circle rather than a hairline. Box-geometry masks have hard
   edges, so the ring stays solid at any DPR. */
.aac-totop::before {
  content: '';
  position: absolute;
  inset: -5px;
  padding: 4px;
  border-radius: 50%;
  background:
    conic-gradient(var(--color-tile-bg) var(--aac-progress, 0turn),
                   var(--color-brand) 0);
  /* Both spellings are required: Safari only matched -webkit-mask until
     15.4, and without a mask this paints a filled circle *over* the
     button face. */
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  pointer-events: none;
}
/* Hovering shifts the button to --color-brand-hover; the untravelled
   arc follows so the two reds never disagree. */
.aac-totop:hover::before {
  background:
    conic-gradient(var(--color-tile-bg) var(--aac-progress, 0turn),
                   var(--color-brand-hover) 0);
}
/* The position marker. Its orbit radius is the button's 22px radius
   plus the 1px gap plus half the 4px track, so the dot's centre sits on the track's
   centre line -- that is the alignment: change the track width and this
   translateY has to move with it. The dot is 4.6px with a 1px outline, i.e. 6.6px overall on a 4px
   track: deliberately larger than the ring now, so it reads as a bead
   riding the track rather than a gap in it. Its centre still has to sit
   on the track's centre line -- that is what keeps it looking seated
   while it overhangs both edges evenly.
   transform-origin stays at the centre of the button, which is what
   makes a plain rotate() trace the ring. The hairline outline is what
   keeps a white dot legible against the light end of the ring. */
.aac-totop::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 4.6px;
  height: 4.6px;
  margin: -2.3px 0 0 -2.3px;
  border-radius: 50%;
  background-color: #ffffff;
  box-shadow: 0 0 0 1px var(--color-tile-bg);
  transform: rotate(var(--aac-progress, 0turn)) translateY(-25px);
  pointer-events: none;
}
.aac-totop__icon {
  display: block;
  width: 12px;
  height: 12px;
  margin-top: 3px;
  border-top: 3px solid #ffffff;
  border-right: 3px solid #ffffff;
  transform: rotate(-45deg);
}
/* flex-shrink:0 alongside width:100% is required, not decorative: with
   the default shrink:1, a flex-wrap container is free to squeeze a
   width:100% item down to share the current line instead of wrapping
   it onto its own -- which is exactly what was happening here. Since
   .aac-topnav is flex:1 1 auto (grows to fill leftover space),
   whatever room this item stole from the shared line came straight
   out of topnav's own width, and it was *topnav's own* internal
   flex-wrap that then broke "About Us / Support / Contact Us / Blogs"
   across multiple lines -- not this element visibly moving anywhere
   itself, which is why it was easy to misdiagnose as a
   .aac-topbar__controls width problem instead. */
.aac-navpath { width: 100%; flex-shrink: 0; text-align: center; }
@media (min-width: 1041px) {
  .aac-navpath { text-align: right; }
}
/* The Edit/Admin glyphs no longer render into this div at any width
   (see .aac-admin-controls above) -- whatever's left in $navpath here
   is occasional page metadata text only (e.g. a 404 error message on
   an authorized viewer's product-not-found page), not the glyphs, so
   it no longer needs special handling at the 1170px+ nowrap tier the
   way the glyphs did: flex-shrink:0 still gets it its own wrapped
   line under flex-wrap:wrap below 1170px, and above that it's short
   enough in practice not to meaningfully compete with .aac-topnav for
   the nowrap row's budget. */
.aac-bandlight { background-color: var(--color-bandlight); height: 1px; }
.aac-bandred { background-color: var(--color-brand); height: 4px; }
.aac-webnotice {
  background-color: var(--color-brand);
  color: #ffffff;
  text-align: center;
  padding: 5px 12px;
  font-size: 14px;
  line-height: 1.4;
  font-weight: bold;
}
@media (min-width: 768px) {
  .aac-webnotice { padding: 8px 16px; }
}

/* ===== Logo ===== */
/* newsite.css sets the full 249x64 logo sprite as its default; on
   phones we scale it down to a crop of the same sprite -- sized up
   from the original 90x23 crop since that was well under the row's
   available height (the row is set by the nav links' own tap-target
   size, not by the logo), so there was free vertical room to spend
   on legibility here rather than at the compressed tablet tier. */
#logo { flex: 0 0 auto; width: 156px; height: 40px; transition: filter .15s ease; }
/* The JPEG sprite's hover frame was the logo over a soft white outer
   glow -- that was the whole point of the second frame, and dropping it
   with the sprite left hover with no feedback at all. (The generic
   opacity dip the other image links use is wrong here: it lowers
   contrast, and this is the one mark on the page that should gain
   presence when you point at it.)

   Rebuilt as stacked drop-shadows, which follow the SVG's alpha and so
   hug the letterforms the way the baked-in glow did. Measured off the
   old hover frame: brightest 1-2px out from the ink, still visible at
   8px, gone by 15 -- which is a tight shadow for the core plus two
   wider ones for the falloff, not one big blur. */
#logo:hover,
#logo:focus-visible {
  filter: drop-shadow(0 0 2px #ffffff) drop-shadow(0 0 5px #ffffff) drop-shadow(0 0 9px rgba(255, 255, 255, .85));
}
/* Compressed (700-1040px, hamburger) tier gets a mid-size logo rather
   than jumping straight to the full 249x64 -- the full size made this
   still-two-row layout tall enough that the short toggle/search row
   read as floating in a lot of empty vertical space. Full size is
   reserved for the single-row desktop tier where there's room for it. */
@media (min-width: 700px) {
  #logo { width: 213px; height: 55px; }
}
@media (min-width: 1041px) {
  #logo { width: 249px; height: 64px; }
}

/* ===== Category tiles ===== */
/* Three equal tiles share one full-width #7b858a row: each is always one
   third of the row (flex: 1 1 0) so all three stay on one line at every
   viewport width. */
/* Original #7b858a only put the #ededed tile label at 3.2:1. Darkened
   the rest state to #5d6771 (4.9:1) and the hover to #454f54 (a clearly
   distinct, still-darker step) so both remain AA-legible and hover keeps
   real contrast against rest instead of nearly matching it. */
.aac-tiles { display: flex; flex-wrap: wrap; justify-content: center; background-color: var(--color-tile-bg); }
/* Hidden whenever the hamburger icon itself is on screen (same
   max-width:1040px breakpoint as .aac-menu-toggle's own visibility
   below) -- not just while its drawer happens to be open. The drawer's
   global menu already repeats these same three section links. */
@media (max-width: 1040px) {
  .aac-tiles { display: none; }
}
.aac-cat_tile {
  flex: 1 1 0;
  min-width: 0;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3px 10px;
  background-color: var(--color-tile-bg);
  text-decoration: none;
  cursor: pointer;
}
.aac-cat_tile .span_menu { font-size: 11px; line-height: 1.25; }
@media (min-width: 768px) {
  .aac-cat_tile { min-height: 44px; padding: 6px 10px; }
  .aac-cat_tile .span_menu { font-size: 1.077em; line-height: normal; }
}
@media (min-width: 1041px) {
  /* The 44px min-height is a touch-target accommodation for tap-driven
     widths; at full desktop (mouse-driven) it's just adding unused
     padding, and was the main reason this row rendered taller than the
     original fixed-table header's 42px tile row. */
  .aac-cat_tile { min-height: 0; padding: 5px 10px; }
  /* The original's .cat_menu class (newsite.css) fixes each tile at
     300px wide -- 900px of clickable tiles centered in the full-width
     gray band (justify-content:center on .aac-tiles, below), not
     stretched to split the whole row into equal thirds. */
  .aac-cat_tile { flex: 0 0 300px; width: 300px; box-sizing: border-box; }
}
.aac-cat_tile--active { background-color: var(--color-brand); }
.aac-cat_tile:hover { background-color: var(--color-tile-bg-hover); }

/* ===== Body and sidebar ===== */
.aac-body {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  align-items: flex-start;
  overflow-wrap: break-word;
}
@media (min-width: 1041px) {
  /* flex-wrap:wrap above is for the mobile column stack (harmless
     there since flex-direction:column ignores wrap anyway). In row
     mode it's actively harmful: .aac-content has width:auto/flex-basis
     auto, so the browser sizes its flex-wrap "does this fit on one
     line" check against the content's max-content (natural, unwrapped)
     width rather than its shrunk width — and rich DB-authored content
     easily has a max-content width wider than the space left beside
     the 210px sidebar, wrapping .aac-content onto its own full-width
     line below the sidebar instead of shrinking to sit beside it.
     There are only ever the two items (sidebar, content) in this row
     and they must never wrap. */
  .aac-body { flex-direction: row; flex-wrap: nowrap; }
}
/* Compressed/phone/tablet baseline: the menu is an Ascentic-style
   DROPDOWN OVERLAY — it opens from the top of the page area and lays
   OVER the content, never a side column. Trigger: the hamburger in the
   top bar, left of the search input. Closed = gone entirely. At
   desktop/full-screen width (1041px+) it instead sits as a static LEFT
   COLUMN in normal flow, always visible — matching
   audioauthority.com's production layout — and the hamburger is
   hidden. */
.aac-sidemenu { flex: 0 0 auto; width: auto; margin: 0; text-align: left; }
.aac-sidemenu:not([open]) { display: none !important; }
/* Enforce the collapsed state explicitly: some engines do not hide a
   closed <details>' content for us, and when they do, the menu still
   laid out under its "Menu" row. */
.aac-sidemenu:not([open]) .aac-sidemenu__body { display: none !important; }
/* Open state: an inset CARD pinned just under the top bar (JS sets the
   exact offset) and flowing DOWN THE PAGE over the tiles, banners and
   content — Ascentic's dropdown, never a side column. It is NOT full
   viewport width: like ascenticretail.com's mobile menu, it sits inset
   from both edges by a proportional gutter (roughly matches Ascentic's
   ~10% side margins at any compressed width) so the page behind it
   stays visible at the edges. Positioned FIXED (viewport-relative) now
   that the top bar itself is `position: sticky` -- absolute positioning
   would anchor to the *document*, so if the page were scrolled down
   before opening the menu it would appear back up near the top of the
   document instead of under the now-visibly-stuck top bar. Since it no
   longer scrolls away with the page, JS also caps its height to the
   remaining viewport and this gets its own internal scrollbar for
   content taller than that. */
/* Scoped to the compressed tier: z-index (unlike other properties)
   applies to flex items even when position:static -- .aac-sidemenu is
   a flex item of .aac-body, so leaving this unscoped left its z-index:
   60 in effect at desktop widths too even though the desktop override
   below resets position back to static, letting the static-column
   sidebar visually paint over the sticky top bar (z-index:50) instead
   of scrolling behind it. */
/* Set on <html> by sidemenu.js while the compressed-tier dropdown is
   open, so the page behind the (inset, non-full-viewport) menu card
   can't be scrolled by wheel/touch/keys while it's showing. */
html.aac-menu-open {
  overflow: hidden;
}
@media (max-width: 1040px) {
  .aac-sidemenu[open] {
    display: block !important;
    position: fixed;
    top: 120px; /* fallback; JS sets the exact offset below the top bar */
    left: 10%;
    right: 10%;
    width: auto;
    margin: 0;
    z-index: 60;
    background: #ffffff;
    border: 1px solid var(--color-border-light);
    /* Thin red top bar, matching sister site ascenticretail.com's mobile
       menu -- reuses the site's own accent red (.aac-bandred, the band
       under the top bar) rather than a new color. Set after the shorthand
       border above so it only overrides the top edge's width/color. */
    border-top: 3px solid var(--color-brand);
    box-shadow: 0 10px 24px rgba(0, 0, 0, .2), 0 2px 6px rgba(0, 0, 0, .12);
    overflow-y: auto;
  }
}
.aac-sidemenu[open] > .aac-sidemenu__body {
  display: block !important;
  padding: 10px 12px 16px 14px;
  margin-bottom: 0;
  border-bottom: 0;
}
/* Tighter vertical rhythm for the compressed dropdown specifically --
   #lmenu's own padding-top (18px/li) and the toplinks divider spacing
   are shared with the desktop static-column layout (min-width:1041px
   block below), which stays untouched. */
@media (max-width: 1040px) {
  .aac-sidemenu[open] > .aac-sidemenu__body { padding: 8px 12px 10px 14px; }
  /* Banded section list matching ascenticretail.com's mobile menu:
     full-width light-gray band behind each top-level heading ("> " +
     category name -- Ascentic's "About Us"/"Our Products" equivalent)
     with bold dark text, and bold dark item rows below it separated by
     a thin divider. Scoped to direct children only -- an earlier
     version used the descendant selector "#lmenu li", which also
     matched submenu <li>s nested inside "#lmenu ul li" and overrode
     their own tighter 5px base padding with a larger top-level value,
     undoing the fix for categories with expandable submenus (e.g.
     intercom's "> PRODUCTS" list: Counter Stations, Hubs, etc). Colors
     set here are the base/non-active state only; menu.css's existing
     active/current-page red accent is reinstated after at higher
     specificity so it still wins. */
  .aac-sidemenu[open] #lmenu { padding-left: 0; }
  .aac-sidemenu[open] #lmenu > li { padding-top: 0; }
  .aac-sidemenu[open] #lmenu > li:not(:first-child) > a { margin-top: 3px; }
  .aac-sidemenu[open] #lmenu > li > a {
    display: block;
    margin: 0 -12px 0 -14px;
    padding: 14px 20px;
    background: var(--color-hover-bg);
    color: #222222;
    font-weight: 700;
    font-size: 1.15em;
  }
  /* All sections expanded at once in the compressed drawer -- menu.css's
     collapsed-by-default behavior (#lmenu ul {display:none}, only the
     DB-flagged current-page/js-toggled ".active" section opens) makes
     sense as a compact accordion for the desktop static column, but
     here the whole point is a single scrollable list a visitor reads
     top to bottom, matching ascenticretail.com's mobile menu (every
     group's items are already visible, nothing to tap open). The
     "> PRODUCTS" style headers keep their onclick handler (harmless --
     toggling .active no longer changes visibility here) since that
     markup is shared, DB-authored content also used by the desktop
     column. */
  .aac-sidemenu[open] #lmenu ul { display: block !important; padding-left: 16px; }
  .aac-sidemenu[open] #lmenu ul li { padding-top: 0; }
  .aac-sidemenu[open] #lmenu ul li a {
    padding: 14px 4px;
    border-bottom: 1px solid var(--color-divider);
    color: var(--color-text-secondary);
    font-weight: 600;
    font-size: 1.05em;
    line-height: 1.3;
  }
  .aac-sidemenu[open] #lmenu ul li:last-child a { border-bottom: 0; }
  .aac-sidemenu[open] #lmenu li.active > a,
  .aac-sidemenu[open] #lmenu a.curr-page { color: var(--color-brand); }
  .aac-sidemenu[open] .aac-sidemenu__body > .aac-sidemenu__toplinks:not(:last-child) {
    margin-bottom: 10px;
    padding-bottom: 10px;
  }
  /* The category heading (e.g. "Support", "> PRODUCTS" intro) is
     DB-authored content: a literal <br> then an <h2> with the
     browser's default ~16px top margin, stacking on top of the
     divider above for ~40px of dead space before the red heading.
     Collapsed here rather than edited in the DB content itself, since
     that same markup also renders in the desktop static column, where
     the spacing is correct static-column layout, not a bug. */
  .aac-sidemenu[open] .aac-sidemenu__toplinks + br { display: none; }
  /* Bleeds edge-to-edge like the section bands below it (same
     cancel-the-body-padding-then-repad technique) -- it was sitting
     inset within .aac-sidemenu__body's own padding while the bands
     already spanned the full drawer width, an inconsistent measure. */
  /* The heading text itself carries hard-coded <br> tags plus leading
     &nbsp;&nbsp;&nbsp; indentation on each broken line (DB content,
     e.g. "Safe, Affordable <br>&nbsp;&nbsp;&nbsp;Airframe Power for
     <br>&nbsp;&nbsp;&nbsp;Ground Operations"), tuned to break at the
     desktop static column's narrow 210px width. Hiding just the <br>
     via CSS left the orphaned nbsp runs behind as stray multi-space
     gaps mid-sentence -- CSS can't collapse literal &nbsp; characters
     or strip them from a text node, so sidemenu.js rewrites this
     heading's markup instead (swapping <br> for a real space and
     collapsing the nbsp runs) when compressed, and restores the
     original DB markup when switching back to the desktop column. */
  .aac-sidemenu[open] .aac-sidemenu__body > h2 {
    margin: 0 -12px 16px -14px;
    padding: 14px 20px;
    background-color: var(--color-hover-bg);
  }
  /* More generous, dividing rows -- Ascentic's mobile nav overlay
     style. Scoped to the dropdown only via .aac-sidemenu[open] rather
     than touching menu.css's shared #lmenu li a rule, which the
     desktop static column also uses. Only targets nested (submenu)
     items -- the broader "#lmenu li a" descendant selector used to sit
     here too, but it also matched the top-level "> PRODUCTS"/"> SUPPORT"
     bar links (#lmenu > li > a, styled separately above) and, being
     later in the cascade at equal specificity, clobbered their
     padding-left back to 0 -- clipping that bar's text against the
     drawer's left edge. */
  .aac-sidemenu[open] #lmenu ul li a {
    padding: 10px 0;
    border-bottom: 1px solid var(--color-divider);
  }
  .aac-sidemenu[open] #lmenu ul li:last-child a { border-bottom: 0; }
}
@media (min-width: 1041px) {
  .aac-sidemenu:not(.aac-sidemenu--nav-fallback) {
    flex: 0 0 210px;
    width: 210px;
    margin: 0 24px 0 0;
  }
  /* Force the panel (and its <details> body) open regardless of the
     open/closed attribute the dropdown JS toggles, overriding the
     :not([open])/[open] rules above despite their higher selector
     specificity — this is what turns the dropdown into an
     always-visible static column at desktop width. Excludes the
     nav-fallback variant (pages with no category menu, e.g. the
     homepage): that one only exists to give About Us/Support/Contact
     Us/Blogs a home in the compressed-width drawer, and must stay
     invisible at desktop width exactly like these pages looked before
     they had a drawer at all -- the links are already in .aac-topnav
     there. */
  .aac-sidemenu:not(.aac-sidemenu--nav-fallback),
  .aac-sidemenu:not(.aac-sidemenu--nav-fallback):not([open]),
  .aac-sidemenu:not(.aac-sidemenu--nav-fallback)[open],
  .aac-sidemenu:not(.aac-sidemenu--nav-fallback) .aac-sidemenu__body,
  .aac-sidemenu:not(.aac-sidemenu--nav-fallback)[open] > .aac-sidemenu__body {
    display: block !important;
    position: static;
    top: auto;
    left: auto;
    right: auto;
    width: 210px;
    margin: 0;
    /* z-index applies to flex items (this is one, in .aac-body) even
       at position:static -- reset defensively so a stray z-index from
       the compressed dropdown rules can never again paint this static
       column over the sticky top bar (z-index:50) as content scrolls
       behind it. */
    z-index: auto;
    background: transparent;
    border: 0;
    box-shadow: none;
    overflow: visible;
  }
  .aac-sidemenu:not(.aac-sidemenu--nav-fallback)[open] > .aac-sidemenu__body { padding: 0; }
  /* Aligns the category heading (e.g. "Drive-up Intercom Systems for
     Banks and Pharmacies") with the page content's own title so the
     two headers share a top edge in the static desktop column. Both
     sides open with the same leading DB-authored <br> (menus.menu and
     the rounded_content wrapper in page_top() each start with one),
     so those cancel out -- the only remaining gap is this h2's own
     UA-stylesheet top margin, which the page titles don't carry
     (they're all margin:0). Keep this the sole knob for that
     alignment: don't compensate on the content side, since this h2's
     structure (leading <br>, default margin) is identical across
     every menus.menu row while content templates vary. */
  .aac-sidemenu__body h2 { margin-top: 0; }
  /* Both forms needed: the un-scoped .aac-sidemenu[open] rule above
     (applies at every width) has higher specificity than a single
     class selector, so a plain .aac-sidemenu--nav-fallback rule loses
     to it despite !important. Matching its [open] attribute selector
     here ties the specificity, and this block's later position in the
     cascade wins that tie. */
  .aac-sidemenu--nav-fallback,
  .aac-sidemenu--nav-fallback[open] { display: none !important; }
}
/* The trigger is a hamburger button in the top bar, immediately left
   of the search input; it only appears in the compressed dropdown mode.
   The in-panel <summary> is never the control. */
.aac-sidemenu summary { display: none; }
/* Toplinks: the same four links .aac-topnav carries, always prepended
   to the drawer content (both the real per-page/global menu and the
   fallback pages that have no category menu of their own). Styled as
   a vertical list sharing .aac-globalmenu__list's row/divider/hover
   treatment so it reads as part of one consistent menu instead of a
   separate horizontal strip bolted on top. */
/* Separated with its own rule (not margin-bottom on the last item,
   which would double up with the fallback case's own bottom edge) so
   it reads as a distinct group when it precedes a real category list,
   e.g. Support's Find My Product/Downloads/etc. */
.aac-sidemenu__body > .aac-sidemenu__toplinks:not(:last-child) { margin-bottom: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--color-border-light); }
.aac-sidemenu__toplinks .aac-globalmenu__list { margin-bottom: 0; }
/* .aac-topnav itself is visible again from 760px up, so the drawer's
   copy of the same links would just be duplication there (including
   inside a real category page's always-visible desktop column). */
@media (min-width: 760px) {
  .aac-sidemenu__toplinks { display: none; }
}
.aac-menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  padding: 11px;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
@media (min-width: 1041px) {
  .aac-menu-toggle { display: none; }
}
.aac-menu-toggle:hover .aac-sidemenu__icon span { background: #222222; }
/* Hamburger icon: three bars that morph into an X while the menu is
   open (JS keeps the button's aria-expanded in sync with the panel).
   Sized 1.33x the original 18x14 box (part of the compressed header's
   overall +33% height/icon scale-up); each bar stays a 2px stroke so
   it doesn't blur at a fractional weight. */
.aac-sidemenu__icon {
  position: relative;
  display: inline-block;
  flex: 0 0 auto;
  width: 24px;
  height: 19px;
}
.aac-sidemenu__icon span {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--color-icon);
  border-radius: 1px;
  transition: transform .18s ease, opacity .18s ease, background-color .18s ease;
}
.aac-sidemenu__icon span:nth-child(1) { top: 0; }
.aac-sidemenu__icon span:nth-child(2) { top: 8px; }
.aac-sidemenu__icon span:nth-child(3) { top: 16px; }
.aac-menu-toggle[aria-expanded="true"] .aac-sidemenu__icon span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.aac-menu-toggle[aria-expanded="true"] .aac-sidemenu__icon span:nth-child(2) { opacity: 0; transform: scaleX(.2); }
.aac-menu-toggle[aria-expanded="true"] .aac-sidemenu__icon span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ===== Global menu (all sections, grouped under the 4 top-level
   headings) -- get_global_menu_sections()/render_global_menu_html() in
   include.php. Used both by the standalone /sitemenu page (desktop and
   compressed) and, wrapped in .aac-sidemenu__global by
   templates/desktop_header.php, as the compressed-width hamburger
   drawer's content -- see the .aac-sidemenu__scoped/__global toggle
   below, which is what actually decides which one is visible where. */
.aac-globalmenu__section:not(:first-child) { margin-top: 28px; }
.aac-globalmenu__heading {
  /* Horizontal margin matches .aac-globalmenu__grouplabel's own
     margin:0 -10px (below) so the two bands render the same width --
     both bleed 10px past their shared container's edge on each side,
     rather than the red heading sitting 20px narrower overall the way
     it did with margin:0. */
  margin: 0 -10px 12px;
  padding: 10px 14px;
  background-color: var(--color-brand);
  color: #ffffff;
  font-size: 1.15em;
  text-align: center;
}
.aac-globalmenu__heading a { color: inherit; text-decoration: none; }
/* Modifier for the drawer's own top-of-menu title (toplinks nav in
   templates/desktop_header.php): it labels the whole menu, not one
   section within it, so it needs to visibly outrank the repeated red
   section bands below it rather than reading as just one more of
   them. Slate gray (--color-tile-bg, the same tone as the site's
   three header tiles) instead of brand red keeps that distinction
   immediate at a glance, not just a size difference. */
.aac-globalmenu__heading--menu {
  background-color: var(--color-tile-bg);
  padding: 14px 10px;
  /* Fixed px, not em: measured against the actual rendered text
     ("AUDIO AUTHORITY WEBSITE NAVIGATION" at font-weight 800,
     uppercase) as the largest size that stays on one line in the
     drawer's inset width at a 320px viewport, the narrowest phone
     still in real use -- the true ceiling measured out to ~11.3px, so
     11px keeps a hair of margin for font-rendering differences
     between browsers/platforms without giving up any size on screen. */
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: normal;
  white-space: nowrap;
}
.aac-globalmenu__list { list-style: none; margin: 0 0 10px; padding: 0; }
/* One standardized label style for every grouping level -- a source's
   own name when two are merged under one heading (e.g. "About Us" /
   "Support") and the PRODUCTS/SUPPORT/WHERE TO BUY dividers within it,
   so the whole menu reads as a single consistent hierarchy instead of
   mixing in each source's own differently-styled marketing heading. */
.aac-globalmenu__grouplabel {
  padding: 5px 10px;
  margin: 0 -10px;
  background-color: #e4e6e7;
  border-bottom: 1px solid #ccd0d2;
  color: var(--color-text-secondary);
  font-weight: 700;
  font-size: .85em;
  letter-spacing: .5px;
  text-transform: uppercase;
}
div.aac-globalmenu__grouplabel { margin-top: 16px; margin-bottom: 2px; }
div.aac-globalmenu__grouplabel:first-child { margin-top: 0; }
.aac-globalmenu__list li:not(.aac-globalmenu__grouplabel) a {
  display: block;
  padding: 6px 10px 6px 10px;
  margin: 0 -10px;
  border-bottom: 1px solid var(--color-divider);
  color: var(--color-text-secondary);
  text-decoration: none;
}
.aac-globalmenu__list li:not(.aac-globalmenu__grouplabel) a:hover {
  background-color: var(--color-hover-bg);
  color: var(--color-brand);
}
.aac-globalmenu__list li:last-child a { border-bottom: 0; }
/* Inside the hamburger drawer specifically (not the standalone
   /sitemenu page), match the compressed drawer's larger tap targets. */
@media (max-width: 1040px) {
  .aac-sidemenu[open] .aac-globalmenu__list li:not(.aac-globalmenu__grouplabel) a { padding: 12px 10px; font-size: 1.05em; }
}
/* Standalone /sitemenu page (scoped to the .aac-globalmenu page
   wrapper). A single column of short link rows wastes most of the
   page's ~900px width at tablet/desktop and turns a short site
   directory into a long scroll; laid out as a grid instead, matching
   the multi-column card grid already used for the product listing
   (.aac-prodlist__main .rounded_content above) rather than inventing
   a new pattern. */
@media (min-width: 700px) {
  .aac-globalmenu .aac-globalmenu__list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 32px;
    row-gap: 2px;
  }
  .aac-globalmenu .aac-globalmenu__list li.aac-globalmenu__grouplabel { grid-column: 1 / -1; }
  .aac-globalmenu .aac-globalmenu__list li:not(.aac-globalmenu__grouplabel) a { border-bottom: 0; }
}
/* The hamburger drawer's own copy of the same global menu
   (.aac-sidemenu__global, distinct from the standalone page's
   .aac-globalmenu wrapper above). The drawer is fixed at 80% of the
   viewport width (left:10%/right:10%, see .aac-sidemenu[open] below),
   so on a narrow phone that's only ~260-300px -- too tight for two
   columns of link text. Only switch to 2 columns once the drawer
   itself is wide enough to fit them: min-width:700px puts the drawer
   at ~560px+, comfortably matching the standalone page's own
   breakpoint. Below 700px the drawer stays single-column intentionally. */
@media (min-width: 700px) and (max-width: 1040px) {
  .aac-sidemenu__global .aac-globalmenu__list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 24px;
    row-gap: 2px;
  }
  .aac-sidemenu__global .aac-globalmenu__list li.aac-globalmenu__grouplabel { grid-column: 1 / -1; }
  .aac-sidemenu__global .aac-globalmenu__list li:not(.aac-globalmenu__grouplabel) a { border-bottom: 0; }
}
/* The drawer/static-column toggle itself: the existing per-page category
   menu ($aac_sidebar's scoped smenu) stays the desktop static column;
   the new all-sections global menu only replaces it in the compressed
   hamburger drawer, per instructions -- desktop behavior for category
   pages is unchanged. */
@media (min-width: 1041px) {
  .aac-sidemenu__global { display: none; }
}
@media (max-width: 1040px) {
  .aac-sidemenu__scoped { display: none; }
}
.aac-content { flex: 1 1 auto; width: 100%; min-width: 0; padding: 0 8px; box-sizing: border-box; }
@media (min-width: 1041px) {
  .aac-content { width: auto; }
}
/* ===== "Find similar products" grid (page/support) -- a single grid
   of clickable image+label cards, replacing three separate 5-column
   tables (which also meant three separate horizontal-scroll strips at
   phone widths, one entry per screen). Plain link cards instead: the
   whole tile (image and label both) is the click target, with no
   underline/link-blue -- the tile itself is the affordance, not text
   decoration. ===== */
.aac-findproducts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px 16px;
  margin: 20px 0;
}
@media (min-width: 600px) {
  .aac-findproducts { grid-template-columns: repeat(4, 1fr); gap: 32px 20px; }
}
.aac-findproducts__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  color: var(--color-text-secondary);
  text-decoration: none;
}
.aac-findproducts__item img { max-width: 100%; height: auto; margin-bottom: 10px; }
.aac-findproducts__item span { font-size: .95em; line-height: 1.3; }
.aac-findproducts__item:hover { color: var(--color-brand); }
.aac-findproducts__item:hover img { opacity: .85; }
/* ===== Content boxes (menu.css pins these to fixed pixel widths) ===== */
/* .rounded_box carries a max-width (976px from menu.css, or a page's own
   inline override) but had no horizontal margins, so on pages WITHOUT the
   210px side menu -- credit_authorization.php, which also widens itself to
   1100px -- main is the full 1200px and every pixel of the leftover width
   piled up on the right, sitting the panel ~99px left of centre. The
   parent is .aac-text-center, whose text-align only centres inline
   content, never a max-width block. Pages that DO have the side menu are
   unaffected: there the box already fills its column, so auto resolves
   to 0. */
.rounded_box { box-sizing: border-box; margin-left: auto; margin-right: auto; }
.aac-body img { max-width: 100%; height: auto; border-radius: 8px; }
/* product_list.php pads a sparse (<=2 item) listing with an inline
   height:350px so the page doesn't look too empty on desktop. That's a
   hard cap, not a minimum, so once items stack to full width on a
   phone and need more than 350px, content clips and everything after
   it (through the footer) overlaps instead of flowing below. Turn it
   into a min-height so it still pads short listings but never clips
   taller stacked content. */
.rounded_content[style*="height"] { height: auto !important; min-height: 350px; }
/* Aligns each page's own title with the sidebar category heading (see
   .aac-sidemenu__body h2 margin-top:0 above): page.php/page_wide.php
   only emit the wrapper's leading <br /> when pages.nobreak is empty,
   so a page whose content starts with a raw <h1>/<h2> (no wrapping
   aac- component div of its own) gets that heading's browser-default
   top margin cancelled the same way. Pages whose content starts with
   a component wrapper (.aac-faq, .aac-access-tips, etc.) instead zero
   their title's margin directly in that component's own CSS. */
.rounded_content > br:first-child + h1,
.rounded_content > br:first-child + h2 { margin-top: 0; }

/* DB-authored pages pin fixed pixel widths on tables, cells, iframes and
   floated blocks (e.g. width="845", style="width: 845px", 401px float cols).
   Clamp every layout element to the container so nothing overflows.
   table-layout: fixed is required: in auto layout a table's min-content
   width (wide images, nested fixed tables, 350px inputs) overrides
   max-width and Chrome will not shrink the table. */
/* width:100% (not just max-width) is required here: with table-layout:
   fixed, a cell that carries its own inline width (DB-authored content
   does this a lot, e.g. style="width: 845px") establishes that column's
   track width directly, which max-width alone does not reliably cap in
   every engine. Pinning the table's own width forces fixed layout to
   divide that width proportionally among columns instead. */
.aac-body table { table-layout: fixed; width: 100%; }
/* DB-authored content routinely puts an inline pixel width directly on
   the <table> itself (e.g. style="width: 845px") and/or on individual
   <td>s. An inline style always outranks the class rule above
   regardless of specificity tricks, so both need !important to
   actually be neutralized — this is also what keeps the table from
   collapsing to less than the full available column width when the
   sidebar leaves more room than 845px (etc.) to give. */
.aac-body table[style*="width"] { width: 100% !important; }
.aac-body td[style*="width"] { width: auto !important; }
/* Same problem, different mechanism: some DB-authored tables set column
   widths via <colgroup><col width="…">, which table-layout:fixed also
   honors as a hard column-track width, bypassing width:100% above. */
.aac-body col { width: auto !important; }
/* DB-authored content frequently centers a diagram/image with a fixed
   pixel margin on each side (a common WYSIWYG-editor pattern, e.g.
   style="margin-left: 150px; margin-right: 150px"). Combined with the
   image's own max-width:100% scaling, that fixed margin doesn't shrink
   with the viewport and pushes the image past the edge on narrow
   screens. Auto-centering achieves the same visual intent responsively. */
/* :not(.aac-sidemenu *) -- .aac-sidemenu sits inside .aac-body (the
   whole page, sidebar included, is one .aac-body), so without this
   exclusion the auto-center rule below -- meant for wide article
   diagrams -- also caught the sidebar's own fixed-margin logo/button
   images and re-centered them, throwing them out of alignment with the
   sidebar heading's own (nbsp-indented) left edge. */
.aac-body img[style*="margin"]:not(.aac-sidemenu *) {
  display: block;
  margin-left: auto !important;
  margin-right: auto !important;
}
/* ===== Legacy multi-column tables: stack on phones/tablets =====
   DB-authored content routinely lays a wide text column beside a
   narrow spacer/image column at desktop proportions (e.g. a 150px
   image column next to a 550px text column, or a bare 20-30px spacer
   column). table-layout:fixed preserves those proportions even when
   the whole table is squeezed into a phone-width viewport, so the
   "wide" column ends up just as narrow as the spacer was — unreadable,
   one-word-per-line text. Stack every table below the tablet
   breakpoint instead (one column per row, full width each) and
   restore normal table rendering once there's enough room for the
   original column layout to make sense again. The [style*="width"]
   duplicates match the specificity of the unconditional td/col rules
   above so this reliably wins on mobile and cleanly hands back to
   them at 768px+. */
/* Cells also frequently carry an inline height (height="75" or
   style="height: 75px", meant to force a desktop row's minimum tallness).
   A stacked block honors that as a hard cap with overflow:visible — the
   content spills out past it instead of growing it, and everything
   after (up to and including the page footer) renders overlapping that
   spilled content instead of below it. Same fix as width: neutralize it
   on the way in. */
.aac-body table { display: block; height: auto !important; }
.aac-body tbody,
.aac-body thead,
.aac-body tfoot { display: block; }
.aac-body tr, .aac-body tr[style*="height"] {
  display: block;
  width: 100%;
  height: auto !important;
}
.aac-body td, .aac-body td[style*="width"], .aac-body td[style*="height"],
.aac-body th, .aac-body th[style*="width"], .aac-body th[style*="height"] {
  display: block !important;
  width: 100% !important;
  height: auto !important;
  box-sizing: border-box;
  margin-bottom: 14px;
}
/* cellspacing/cellpadding only render in real table layout -- once
   stacked to blocks above, adjacent cells (e.g. a photo next to a bio
   paragraph) touch with zero gap between them. The trailing margin on
   the very last cell just adds a bit of extra space before whatever
   follows the table, which is harmless. */
.aac-body tr:last-child > td:last-child,
.aac-body tr:last-child > th:last-child { margin-bottom: 0; }
/* A stacked cell holding nothing but a photo (a common DB-authored
   "photo beside bio text" pattern -- e.g. page/faith1) is still a
   full-width block once stacked, but the image itself stays its
   narrow intrinsic width and sits flush left inside it -- reading as
   a big blank gap beside the photo rather than the tight single-column
   flow the rest of the stacked table has. Center any cell whose only
   real content is an image instead. */
@media (max-width: 767px) {
  .aac-body td:has(img):not(:has(p, li, table)) { text-align: center; }
}
/* Opt-out for a genuine multi-column comparison grid (a row-label
   column plus one data column per product, e.g. page/Audio_Demo_Comparison)
   -- the stacking rules above assume a 2-column "photo beside text"
   layout where reading order survives being flattened to one block per
   row. A comparison grid doesn't survive that: every cell becomes its
   own full-width row with nothing to show which product or which
   feature it belongs to. Scroll it horizontally instead, keeping the
   authored grid (and the row-to-column relationship) intact -- marked
   with this class directly in the DB content rather than detected
   automatically, since column count alone can't tell a comparison grid
   apart from an equally wide row of self-contained cards (page/support),
   which stacks fine as-is. */
/* Cell padding for the comparison grids. These were authored with
   cellpadding/cellspacing attributes and fixed pixel width/height, which
   the modernization pass strips: attribute padding is presentational,
   does not survive the mobile stacking rules, and the pixel sizing fought
   the responsive width rules above. This restores the breathing room in
   CSS so the markup can stay clean. */
.aac-body table.aac-comparetable { border-collapse: collapse; }
.aac-body table.aac-comparetable td,
.aac-body table.aac-comparetable th { padding: 8px 10px; vertical-align: top; }
@media (max-width: 767px) {
  .aac-body table.aac-comparetable {
    display: block;
    width: auto !important;
    max-width: 100%;
    height: auto !important;
    table-layout: auto !important;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .aac-body table.aac-comparetable tbody { display: table-row-group; }
  .aac-body table.aac-comparetable tr,
  .aac-body table.aac-comparetable tr[style*="height"] {
    display: table-row;
    width: auto;
    height: auto !important;
  }
  .aac-body table.aac-comparetable td,
  .aac-body table.aac-comparetable td[style*="width"],
  .aac-body table.aac-comparetable td[style*="height"] {
    display: table-cell !important;
    width: auto !important;
    height: auto !important;
    white-space: normal;
    margin-bottom: 0 !important;
  }
}
@media (min-width: 768px) {
  /* table-layout:fixed establishes column tracks from the FIRST row's
     cells/colspans. DB-authored tables routinely have a header row
     with a colspan that doesn't match the real column count of the
     data rows below it (e.g. a colspan="9" title bar over what's
     actually just a 2-column label/description table) — fixed layout
     reserves all those phantom columns from the mismatched first row,
     squeezing the real content into a fraction of the table and
     leaving the rest blank. table-layout:auto sizes columns from
     actual per-column content instead, which tolerates a mismatched
     header row correctly. Only safe to switch back here: at this
     breakpoint the table is real (not stacked to blocks), and desktop
     width is generally enough for auto layout's natural min-content
     sizing to fit without needing fixed layout's forced shrink. */
  .aac-body table { display: table; table-layout: auto; }
  .aac-body tbody { display: table-row-group; }
  .aac-body thead { display: table-header-group; }
  .aac-body tfoot { display: table-footer-group; }
  .aac-body tr { display: table-row; width: auto; }
  .aac-body td, .aac-body td[style*="width"],
  .aac-body th, .aac-body th[style*="width"] {
    display: table-cell !important;
    width: auto !important;
  }
}
.aac-body table,
.aac-body td,
.aac-body th,
.aac-body div,
.aac-body span,
.aac-body p,
.aac-body h1,
.aac-body h2,
.aac-body h3,
.aac-body h4,
.aac-body h5,
.aac-body h6,
.aac-body blockquote,
.aac-body pre,
.aac-body figure,
.aac-body form,
.aac-body input,
.aac-body select,
.aac-body textarea,
.aac-body button,
.aac-body iframe,
.aac-body object,
.aac-body embed,
.aac-body video,
.aac-body audio { max-width: 100%; }
/* DB-authored video embeds (e.g. page/intercom's YouTube iframe) carry
   fixed width/height attributes (845x475). max-width:100% above caps
   the width on narrow screens, but the height attribute stays fixed --
   the player ends up squeezed into a tall, narrow box instead of
   scaling proportionally. aspect-ratio (matching the standard 16:9
   YouTube embed ratio) keeps height in step with the shrunk width.
   Not scoped to .aac-body: index.php's category pages (e.g.
   index/intercom, pages_raw-backed) render their content straight
   into <main class="aac-content"> with no .aac-body wrapper, so a
   plain iframe[src*="youtube"] selector is what actually reaches
   every YouTube embed on the site, not just the page.php ones.
   border-radius and box-shadow match .aac-body img / .aac-training__video
   so video embeds read as the same kind of media as everything else
   on the page instead of a plain rectangle. */
iframe[src*="youtube"] { aspect-ratio: 16 / 9; width: 100%; max-width: 845px; height: auto; border-radius: 8px; overflow: hidden; box-shadow: 0 2px 10px rgba(0, 0, 0, .18); }
/* iOS Safari auto-zooms the whole page on focus when a form control's
   computed font-size is under 16px. Sitewide safety net for any input
   not already covered by a more specific rule (e.g. search.php's plain
   <input type="text">, which otherwise inherits the 13px body font). */
@media (max-width: 1040px) {
  input[type="text"],
  input[type="email"],
  input[type="tel"],
  input[type="search"],
  input[type="number"],
  input[type="password"],
  select,
  textarea {
    font-size: 16px;
  }
}

/* ===== Footer ===== */
.aac-footer { background-color: var(--color-footer-bg); margin-top: 20px; }
/* Matches audioauthority.com's own footer grouping: the nav links get
   their own full-width row, then the address/hours/copyright block and
   the phone+social badges share a second row -- meta on the left,
   badges on the right (space-between), not three siblings that wrap
   into whichever row happens to have space. */
.aac-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 10px;
  text-align: left;
}
@media (min-width: 1041px) {
  .aac-footer__inner { gap: 12px; }
}
/* Compressed tier (<=1040px, same cutoff as the hamburger header): the
   sitewide .menu_links/#span_footer sizes were tuned for the full-width
   desktop footer and wrap awkwardly once the footer's own width shrinks
   with the rest of the compressed layout. */
@media (max-width: 1040px) {
  .aac-footer__meta #span_footer { font-size: 0.85em; }
}
/* "Phone: ... | Hours: ..." reads fine as one line at full desktop
   width, but at narrower widths it wraps mid-phrase leaving a
   dangling "|" at the end of a line. Force a real break there instead
   (and drop the now-redundant "|" separator) once there's not enough
   room for it to read as a single line to begin with. */
.aac-footer__br { display: none; }
.aac-footer__hours-sep { display: inline; }
@media (max-width: 1040px) {
  .aac-footer__br { display: block; }
  .aac-footer__hours-sep { display: none; }
}
.aac-footer__links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 6px 14px;
}
/* These six links used to be forced onto one line at 0.72em, which cost
   more than it bought: the row measured a fixed 317px, so every page
   scrolled sideways below ~337px (iPhone SE and similar), and the text
   landed at 9.36px in a 10px-tall tap target. Wrapping to two centred
   lines at the inherited size keeps the links legible and tappable and
   removes the site's only horizontal overflow. Each label still carries
   white-space: nowrap below, so wrapping happens between links, never
   mid-label. */
@media (max-width: 1040px) {
  .aac-footer__links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0 16px;
  }
  .aac-footer__links .menu_links { padding: 7px 0; }
}
@media (min-width: 768px) {
  .aac-footer__links { gap: 6px 16px; }
}
@media (min-width: 1041px) {
  .aac-footer__links { gap: 8px 26px; }
}
/* Same fix as the top bar's .aac-topnav .menu_links: the sitewide
   .menu_links color (#738791) only clears 2.5:1 against this footer's
   #d0d4d9 background. */
.aac-footer__links .menu_links { white-space: nowrap; color: var(--color-footer-link); }
/* Same hover/focus treatment as .aac-topnav .menu_links and the
   pencil/gear admin glyphs -- brand red on hover/keyboard-focus. */
.aac-footer__links .menu_links:hover,
.aac-footer__links .menu_links:focus-visible { color: var(--color-brand); }
.aac-footer__row2 {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  gap: 12px;
}
@media (min-width: 768px) {
  .aac-footer__row2 { flex-direction: row; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; }
}
.aac-footer__meta { max-width: 640px; text-align: left; }
/* #span_footer's own color (newsite.css, #738791) has the same 2.5:1
   problem against this background; only used here, so overridden here. */
.aac-footer__meta #span_footer { color: var(--color-footer-link); }
.aac-footer__badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  text-align: left;
}
@media (min-width: 1041px) {
  /* column-gap, not gap: this sets only the space BETWEEN the phone
     block and the icons, leaving the row-gap alone for when badges
     wraps.

     The value is the same --footer-icon-gap the icons space themselves
     by (newsite.css), so the phone sits in the icons' rhythm instead of
     at some separate distance -- one gap repeated the whole way across
     the cluster to the right edge. Sharing the token is what keeps it
     that way; the two cannot drift apart later.

     It is also what positions the phone. .aac-footer__row2 is
     space-between, so this cluster is pinned to the footer's right
     edge: the gap is the only thing between the phone and the icons,
     so widening it moves the phone left while the icons stay put.

     Only at this tier -- below 1041px .aac-footer__social is forced to
     flex:0 0 100%, so the phone stacks above the icons and a column-gap
     between them means nothing. */
  .aac-footer__badges { row-gap: 14px; column-gap: var(--footer-icon-gap); }
}
/* Below the row2 breakpoint, badges is a lone row inside a narrow
   column (not paired with .aac-footer__meta beside it), so there's
   room for the phone number and the four social icons to both fit on
   one line -- but jammed together with no separation it reads as a
   single cramped cluster. Force the phone block onto its own line so
   the icons get a clean row of their own underneath, with a bit more
   breathing room than the plain flex gap gives. */
@media (max-width: 767px) {
  .aac-footer__phone { flex: 0 0 100%; margin-bottom: 4px; }
  .aac-footer__badges { gap: 14px; }
}
.aac-footer__badges img { max-width: 100%; height: auto; }
/* Social icons: sprite-cropped photographic logos, so they take the
   shared image-link opacity dip -- see the "Image-link hover" block
   near the top of this file, which carries the rule for these. */
/* Compressed tier (<=1040px, same cutoff as the hamburger header): the
   four social icons were left-aligned with only a fixed gap between them,
   clumping to one side instead of spanning the row. Give them their own
   full-width row, evenly spaced edge to edge. */
@media (max-width: 1040px) {
  .aac-footer__social {
    display: flex;
    flex: 0 0 100%;
    justify-content: space-between;
  }
  /* space-between owns the spacing here, so the shared desktop margin
     would just push the last icon off the right edge. */
  .footer_links {margin-right: 0;}
  /* The icon is 26px, well under the ~44px touch target minimum, so
     the tap target grows on the <a> around it -- centred by the flex
     rule in newsite.css, it just adds invisible padding above and
     below the glyph. */
  .footer_links__btn a { min-height: 44px; }
}

/* ===== Pagination touch targets =====
   div.product_nav a/span.red (page numbers, prev/next -- product_list.php,
   blog.php) come from menu.css with only 0.3em/0.5em padding: on 13px
   body text that's roughly 21px tall, well under the ~44px touch
   target minimum. Widen the tap area at the compressed tier without
   changing the visual text size. */
@media (max-width: 1040px) {
  div.product_nav a,
  div.product_nav span.red {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    min-width: 44px;
    box-sizing: border-box;
  }
}
.aac-footer__phone {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.aac-footer__phone-label {
  font-size: 11px;
  font-weight: bold;
  color: var(--color-footer-link);
  letter-spacing: 0.02em;
}
.aac-footer__phone-number {
  font-size: 15px;
  font-weight: bold;
  color: var(--color-footer-strong);
  white-space: nowrap;
}

/* ===== Product details page ===== */
.aac-product { width: 100%; max-width: 976px; margin: 0 auto; }
/* Overview/Features/Specifications/Downloads/FAQ tab bar (tabs.css,
   loaded when usetabs is set) is float-based with no wrapping rules of
   its own -- once the labels' combined width exceeds a narrow screen,
   the floats wrap mid-row instead of cleanly stacking, leaving later
   tabs' left edges landing wherever the previous row's floats happened
   to end rather than back at the container's edge. Fixed by splitting
   the row into 5 equal-width columns instead: every tab stays visible
   with no scrolling required, and a long label (e.g. "Specifications")
   wraps to a second line within its own column rather than overflowing
   into its neighbor.

   !important throughout this block: tabs.css itself is injected via
   the page's $css variable, which templates/header.php echoes AFTER
   this stylesheet's <link> tag -- so at equal selector specificity,
   tabs.css's unconditional float/padding rules load later and win
   regardless of this media query, silently keeping the tab still
   floated (and thus shrink-wrapped to its full unwrapped content
   width, not the column width below) unless forced. */
@media (max-width: 1040px) {
  ul.tabs {
    display: flex !important;
    flex-wrap: nowrap;
    gap: 1px;
  }
  ul.tabs li { float: none !important; flex: 1 1 0; min-width: 0; margin: 4px 0 0 0 !important; }
  ul.tabs a {
    float: none !important;
    display: block !important;
    /* nowrap, not normal -- "Specifications" (the longest label) needs
       to stay on one line; the near-zero side padding and small
       font-size below exist specifically to make that fit within a
       fifth of even a narrow phone's width without wrapping or
       shrinking any tab unevenly. */
    white-space: nowrap !important;
    text-align: center;
    padding: 4px 0 !important;
    font-size: 9px !important;
    letter-spacing: -0.3px;
    line-height: 1.2;
  }
}
.pd-grid {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 20px 24px;
}
@media (min-width: 768px) {
  .pd-grid { flex-direction: row; }
}
.pd-image { flex: 0 1 auto; max-width: 100%; min-width: 200px; text-align: center; }
@media (min-width: 768px) {
  .pd-image { flex-basis: 340px; max-width: 360px; }
}
/* flex-basis is a HEIGHT basis while .pd-grid is column-direction
   (below 768px) -- 320px there just forces .pd-info to reserve that
   much vertical space regardless of how short its actual text is,
   leaving a dead blank gap above .pd-buy on any product with a brief
   description. The 320px width basis only makes sense once .pd-grid
   switches to a row (768px+, alongside the 340px image column). */
.pd-info { flex: 1 1 auto; min-width: 0; text-align: left; }
.pd-buy { flex: 0 0 auto; min-width: 113px; text-align: left; }
@media (min-width: 768px) {
  .pd-info { flex: 1 1 320px; }
  .pd-buy { text-align: right; }
}
/* display:inline-flex (not flex) so this still sits at .pd-buy's own
   left/right text-align position above -- only the button and the
   "Available: N" line underneath it (check_ip()-only) are centered
   relative to EACH OTHER inside it, since "Available: N" is often
   wider than the 113px button and would otherwise just inherit
   .pd-buy's left/right alignment independently of where the button
   actually sits. */
.pd-buy-cta { display: inline-flex; flex-direction: column; align-items: center; gap: 4px; }
.pd-buy img { max-width: 100%; height: auto; }
.pd-image img,
.pd-gallery img,
.pd-related img,
.long_desc img { max-width: 100%; height: auto; border-radius: 8px; }
/* Detail page's CTA used to be a fixed 113x33 image button
   (/images/buttons/{state}.jpg); now shares .aac-buybtn (below) with the
   product grid's card CTA, sized here to roughly match that old footprint. */
.pd-buybtn { min-width: 113px; }

/* ===== Text utility classes =====
   Replace legacy <font size="..." color="..."> tags with real CSS -- the
   size/color pairs below match the specific <font> combinations actually
   used across product_details.php/product_list.php (size="+1" ~ 1.15em,
   size="-1" ~ 0.9em relative to the surrounding text, matching how those
   attribute values rendered in practice). */
.aac-text-brand { color: var(--color-brand); }
.aac-text-lg { font-size: 1.15em; }
.aac-text-sm { font-size: 0.9em; }
.aac-text-muted { color: #666666; }
.aac-text-error { color: #d00000; }  /* was #ff0000: 4.0:1 on white */

/* ===== Buy/CTA button (shared: product grid card + product detail page) =====
   One state -> one class -> one look, replacing the old per-state
   /images/buttons/{state}.jpg graphics (get_buy_cta() in include.php picks
   the class). Kept as a handful of semantic states rather than one style
   per literal DB value, since several legacy values share the same
   real-world meaning (buyintercom/buyswitching/dealer all just mean "call
   or visit a dealer page, not a direct add-to-cart"). */
.aac-buybtn {
  display: inline-block;
  box-sizing: border-box;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: bold;
  text-align: center;
  text-decoration: none;
  border-radius: 3px;
  border: 1px solid transparent;
  transition: background-color .15s ease, box-shadow .15s ease;
}
/* ===== Button hover elevation =====
   Every button-like control on the site lifts the same way on hover:
   a background darken (declared per variant below, since each family
   has its own base color) plus this one shared shadow. The shadow used
   to be copied as a literal into four component blocks and was simply
   missing from four others -- the three pagination pill sets, and the
   unavailable (Discontinued / Out of Stock) CTA, which had been read as
   inert and excluded on purpose. It isn't inert: get_buy_cta() points it
   at /page/discontinued and /page/outofstock, both real pages, so it
   gets the same feedback as every other button.
   One list and one token (--shadow-btn-hover, css/newsite.css) so these
   families can't drift apart again; a new button family joins by adding
   its selector here rather than re-typing the shadow.
   .aac-search-submit is deliberately not in the list: that one sits
   *inside* the search input's own box, where a drop shadow reads as a
   rendering artifact rather than a lift. It keeps its existing
   background + border-color hover. */
.aac-buybtn:hover,
.aac-btn--brand:hover,
.aac-pill-btn:hover,
.aac-blog-topic:hover,
.aac-search-form__submit:hover,
.aac-prodlist-pagination div.product_nav a:hover,
.aac-blog-pagination__nav a:hover,
.aac-search-nav a:hover { box-shadow: var(--shadow-btn-hover); }
.aac-buybtn--specialorder,
.aac-buybtn--newmodel {
  background-color: var(--color-gold);
  color: #3a2a00;
}
.aac-buybtn--specialorder:hover,
.aac-buybtn--newmodel:hover { background-color: var(--color-gold-hover); }
.aac-buybtn--info {
  background-color: #ffffff;
  color: var(--color-text-secondary);
  border-color: var(--color-border-input);
}
.aac-buybtn--info:hover { background-color: var(--color-hover-bg); }
/* Secondary action on the product grid card: same button geometry as the
   buy CTA directly above it, in the slate already used by the category
   tiles (--color-tile-bg) rather than a fourth hue -- distinct from both
   the brand red and the gold order states, so the primary action still
   reads as the primary one. */
.aac-buybtn--details {
  background-color: var(--color-tile-bg);
  color: #ffffff;
}
.aac-buybtn--details:hover { background-color: var(--color-tile-bg-hover); }
/* Discontinued / Out of Stock: a muted gray, since it isn't an action
   to encourage -- but still a link (to /page/discontinued or
   /page/outofstock, which explain the status and point at replacements),
   so it darkens and lifts on hover like the rest and keeps the link
   cursor. It carried cursor:default before, which told the visitor the
   opposite of the truth. */
.aac-buybtn--unavailable {
  background-color: #e6e6e6;
  color: #595959;  /* was #6b6b6b: 4.27:1 on this background, fails AA */
  border-color: #cccccc;
}
.aac-buybtn--unavailable:hover {
  background-color: #d8d8d8;
  border-color: #bdbdbd;
  color: #4f4f4f;
}
/* Product descriptions (products.long_desc) are old WYSIWYG-authored
   HTML -- a meaningful fraction of rows carry leftover editor cruft:
   tables/divs with a stale inline height (often 200-900px, far taller
   than the actual text) and runs of 3+ stacked <br /> "spacer" tags,
   both of which render as large dead blank space below the actual
   description on the product page. Neutralizing this in CSS (rather
   than hand-editing ~190 DB rows) fixes it wherever it appears. */
.long_desc table,
.long_desc tr,
.long_desc td,
.long_desc div,
.long_desc p { height: auto !important; min-height: 0 !important; }
.long_desc br + br { display: none; }
.pd-gallery,
.pd-related {
  list-style: none;
  margin: 10px 0 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: flex-start;
}
.pd-gallery li,
.pd-related li { text-align: center; }
/* Nothing follows this list but the page footer -- without its own
   bottom spacing the last row of thumbnails sits flush against it. */
.pd-related { margin-bottom: 24px; }
.pd-related li { width: 130px; }
@media (min-width: 768px) {
  .pd-related li { width: 150px; }
}

/* ===== Checkout / credit-authorization forms =====
   Reuses .form_desc/.form_desc_data (from cart.css) as flex children
   instead of table cells. Mobile-first: label stacks above its field;
   from 600px up they sit side by side with a fixed-width label column
   matching the original tables' width='150' columns.
   These base classes (.form_desc/.form_desc_data/.input/.aac-co-row/
   .aac-co-shell) are shared verbatim by credit_authorization.php and
   credit_authorization_intl.php -- restyling them here intentionally
   updates both, since they're the same form pattern by design (the
   intl page is a variant of this one, not a different one); only this
   page's own PHP markup was touched. */
.aac-co-row { display: flex; flex-direction: column; }
.aac-co-row--full { display: block; }
.aac-co-cell--full { flex: 1 1 100%; }
@media (min-width: 600px) {
  .aac-co-row:not(.aac-co-row--full) { flex-direction: row; align-items: center; }
  .aac-co-row:not(.aac-co-row--full) > .form_desc { flex: 0 0 170px; }
  .aac-co-row:not(.aac-co-row--full) > .form_desc_data,
  .aac-co-row:not(.aac-co-row--full) > div:last-child:not(.form_desc) { flex: 1 1 auto; min-width: 0; }
}
/* Outer page shell: trust-badge sidebar + the form itself. */
.aac-co-shell { display: flex; flex-direction: column; }
@media (min-width: 768px) {
  .aac-co-shell { flex-direction: row; align-items: flex-start; gap: 24px; }
  .aac-co-shell__side { flex: 0 0 190px; }
  .aac-co-shell__main { flex: 1 1 auto; min-width: 0; }
}
/* Modern field styling for the shared .input/.form_desc classes,
   scoped under .aac-credit (credit_authorization.php's own wrapper
   class, added around its outer .rounded_box) rather than redefining
   these classes bare. Two reasons: (1) cart.css -- where .input/
   .form_desc/.form_desc_data's *original* dated recipe lives (8pt
   Arial, 1px solid black border, flat gray backgrounds, no focus
   state) -- loads AFTER responsive.css in <head> (it's the page's own
   $css, appended last), so an unscoped same-specificity rule here
   would lose the cascade to it; .aac-credit's extra class outranks
   that regardless of load order. (2) credit_authorization_intl.php
   uses these exact same class names for the exact same form pattern
   but wasn't part of this request -- scoping here means only this
   page's fields actually change, without redefining what those class
   names mean everywhere they're used. */
/* .form_desc captions are <label for=...> now (so tapping the caption
   focuses its field and screen readers announce it). A <label> is
   inline by default where the old <div> was block, and at the stacked
   mobile tier these are not flex children, so blockify explicitly. */
.aac-credit .form_desc { display: block; }
.aac-credit .form_desc {
  padding: 4px 0;
  color: #646d74;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .2px;
  text-align: left;
  background: none;
}
.aac-credit input.input, .aac-credit select.input, .aac-credit textarea.input {
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background-color: #ffffff;
  font-family: var(--font-sans);
  font-size: 16px;
  color: #222222;
  box-sizing: border-box;
}
.aac-credit input.input {
  height: 42px;
  padding: 0 12px;
  width: 100%;
  max-width: 320px;
}
.aac-credit select.input { height: 42px; padding: 0 12px; width: 100%; max-width: 320px; }
.aac-credit textarea.input { width: 100%; max-width: 100%; padding: 10px 12px; resize: vertical; }
.aac-credit input.input:focus, .aac-credit select.input:focus, .aac-credit textarea.input:focus {
  outline: none;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(185, 0, 0, .12);
}
.aac-credit .form_desc_data { text-align: left; background: none; }

/* ===== credit_authorization.php-specific chrome ===== */
.aac-credit__title { margin: 20px 0 8px; color: var(--color-brand); font-size: 1.8em; }
.aac-credit__lede { margin: 0 0 16px; max-width: 640px; color: var(--color-text-tertiary); }
.aac-credit__notice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 20px;
  padding: 14px 16px;
  background-color: var(--color-error-bg);
  border: 1px solid var(--color-error-border);
  border-radius: 8px;
  color: var(--color-error-text);
  max-width: 900px;
}
.aac-credit__notice-icon { flex: 0 0 auto; margin-top: 2px; color: var(--color-brand); }
.aac-credit__main { background: none; }
.aac-credit__panel {
  padding: 20px;
  background-color: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  box-sizing: border-box;
}
@media (min-width: 700px) {
  .aac-credit__panel { padding: 24px 28px; }
}
.aac-credit__section-title {
  margin: 24px 0 12px;
  color: var(--color-brand);
  font-weight: 700;
  font-size: 1.05em;
  text-transform: uppercase;
  letter-spacing: .4px;
}
.aac-credit__panel > .aac-co-row:first-child .aac-credit__section-title,
.aac-co-row:first-child > .aac-credit__section-title { margin-top: 0; }
.aac-required { margin-left: 2px; color: var(--color-brand); }
.aac-credit__required-note { margin: 0 0 18px; color: #646d74; font-size: .88em; }
.aac-credit__required-note .aac-required { margin-left: 0; margin-right: 2px; }
.aac-credit__hint { margin-left: 8px; color: var(--color-text-meta, #707070); font-size: .85em; }
.aac-credit__comments { margin-top: 8px; }
.aac-credit__comments textarea.input { min-height: 110px; }
@media (min-width: 600px) {
  /* The shared .aac-co-row rule center-aligns label against field,
     which reads fine for a single-line input but leaves "Additional
     Comments" floating mid-height against a 110px-tall textarea --
     top-align just this row instead. */
  .aac-credit__comments.aac-co-row { align-items: flex-start; }
  .aac-credit__comments .form_desc { padding-top: 10px; }
}
/* A few pixels of breathing room between each field row -- the shared
   .aac-co-row rule has no vertical gap of its own, so rows sat flush
   against each other with only each input's own height for spacing. */
.aac-credit .aac-co-row { margin-bottom: 10px; }
/* reCAPTCHA sits directly above the submit button so the check reads as
   the last step before submitting. The widget is a fixed-width 304px
   iframe that cannot be resized; javascript/captcha-fit.js scales it
   down on narrow screens rather than letting it overflow the card. */
.aac-credit__captcha-row { margin-top: 20px; text-align: center; }
.aac-credit__captcha-row .aac-captcha { display: inline-block; }
@media (min-width: 600px) {
  .aac-credit__captcha-row { text-align: left; }
}

.aac-credit__submit-row { margin-top: 20px; text-align: center; }
@media (min-width: 600px) {
  .aac-credit__submit-row { text-align: left; }
}
.aac-credit__side {
  padding: 20px;
  background-color: var(--color-panel-bg);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  text-align: left;
  box-sizing: border-box;
}
.aac-credit__side-title { margin: 16px 0 8px; color: var(--color-brand); font-size: 1.15em; }
.aac-credit__side p { margin: 0 0 12px; color: var(--color-text-tertiary); font-size: .95em; line-height: 1.5; }
.aac-credit__cards-logo { display: block; padding-bottom: 15px; max-width: 100%; height: auto; }
.aac-credit__paytrace-logo { display: block; margin: 0 0 20px; padding: 15px 0; }
.aac-credit__paytrace-logo img { max-width: 100%; height: auto; }
.aac-credit__side-row { display: flex; gap: 10px; align-items: flex-start; margin-top: 16px; }
/* Extra 10px of air above the second sidebar block ("Smooth
   Transactions" and its icon) on both credit_authorization.php and
   credit_authorization_intl.php, which share this markup. */
.aac-credit__side-row + .aac-credit__side-row { margin-top: 26px; }
.aac-credit__side-icon { flex: 0 0 auto; margin-top: 3px; color: var(--color-brand); }
.aac-credit__side-row p { margin: 4px 0 0; }
/* Error/success states (badpage() / the post-submit "Thank you" page)
   -- same alert/success recipe already established on contact.php,
   reproduced here under this page's own class names rather than
   sharing contact.php's, since coupling two unrelated pages' CSS to
   one class name would make either page's future changes surprise
   the other. */
.aac-credit__alert {
  max-width: 560px;
  margin: 24px auto;
  padding: 24px;
  background-color: var(--color-error-bg);
  border: 1px solid var(--color-error-border);
  border-radius: 10px;
  color: var(--color-error-text);
  text-align: center;
}
.aac-credit__alert h2 { margin: 0 0 10px; color: var(--color-error-heading); }
.aac-credit__alert a { color: inherit; font-weight: 600; }
.aac-credit__success {
  max-width: 560px;
  margin: 24px auto;
  padding: 32px 24px;
  background-color: var(--color-success-bg);
  border: 1px solid var(--color-success-border);
  border-radius: 10px;
  color: var(--color-success-text);
  text-align: center;
}
.aac-credit__success h2 { margin: 0 0 8px; color: inherit; }
.aac-credit__success-icon { color: var(--color-success-icon); margin-bottom: 12px; }
/* CVV help, shown inline via the native <dialog> element (templates/cvv_help.php)
   instead of a separate window/tab -- opened with .showModal(), which also
   gives us focus trapping, Escape-to-close, and the ::backdrop dimming for
   free. */
.aac-cvv-dialog {
  width: min(620px, calc(100vw - 40px));
  max-height: min(720px, calc(100vh - 40px));
  padding: 24px 28px 28px;
  border: 0;
  border-radius: 10px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .3);
  /* templates/header.php wraps the whole page body in
     .aac-text-center (many DB pages.content rows depend on it for
     centering) -- showModal() keeps this dialog in that same DOM
     subtree for CSS inheritance purposes even though it paints in the
     top layer, so without this override every paragraph here would
     inherit center alignment instead of reading normally. */
  text-align: left;
}
.aac-cvv-dialog::backdrop { background: rgba(20, 22, 24, .55); }
.aac-cvv-dialog img { display: block; max-width: 100%; height: auto; margin: 16px 0 24px; border: 1px solid var(--color-border); border-radius: 6px; }
.aac-cvv-dialog__header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 12px; }
.aac-cvv-dialog__header h2 { margin: 4px 0 0; color: var(--color-brand); font-size: 1.25em; }
.aac-cvv-dialog__header form { margin: 0; flex: 0 0 auto; }
.aac-cvv-dialog__close {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 6px;
  background: var(--color-hover-bg);
  color: var(--color-text-secondary);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.aac-cvv-dialog__close:hover { background: var(--color-border-light); }

/* ===== Category-page "Our Work" slideshow =====
   javascript/slideshow/slideshow.js (a legacy MooTools crossfade
   widget, DB-authored content on /index/rollouts etc.) sets inline
   width/height/position styles on every image it cross-fades between,
   all hardcoded to a fixed 845x475 -- with no viewport awareness at
   all, AND reads #show's own rendered width at runtime to center that
   845-wide image within it (fine when #show is wider than 845, but if
   #show's own CSS width is constrained to fit a narrow viewport, the
   script instead computes a large *positive* left offset, shoving
   most of the image out of view -- so #show's own layout width can't
   be the thing that shrinks. javascript/slideshowscale.js wraps #show
   in a plain div (.aac-slideshow-wrap, sized/clipped here) and scales
   #show itself down via a plain (not calc() -- calc() can't divide
   two lengths into a unitless number in the engine this site targets)
   transform:scale(). transform doesn't change offsetWidth/clientWidth,
   so the script still reads #show as a full 845px box and never sees
   a reason to re-center anything; the wrapper is what actually varies
   with viewport width, and clips the transform-scaled box's own
   now-oversized (unscaled) layout footprint down to size. */
.aac-slideshow-wrap {
  width: 100%;
  /* !important: otherwise the sitewide `.aac-body div{max-width:100%}`
     rule -- more specific (class+type beats this rule's class alone)
     -- wins and this never actually caps at 845, same issue as #show
     below needing its own max-width override. */
  max-width: 845px !important;
  aspect-ratio: 845 / 475;
  overflow: hidden;
  position: relative;
  /* Once the 845px cap kicks in inside a wider column, a block
     element with no auto margins sits flush-left instead of centered
     in the leftover space -- margin:auto centers it like the "Our
     Work" heading above it. */
  margin-left: auto;
  margin-right: auto;
}
/* Fixed at the widget's native width regardless of the (possibly much
   narrower) wrapper around it -- see javascript/slideshowscale.js --
   so the script's own reads of this element's size never change. */
/* max-width:none overrides the sitewide `.aac-body span{max-width:100%}`
   rule -- max-width always caps a conflicting width regardless of
   cascade/!important (they're separate properties, not competing
   values of the same one), so without this #show would still be
   capped to the wrapper's own (narrow) width no matter what width is
   set to above. */
#show.slideshow { display: block; width: 845px; max-width: none; }

/* ===== Homepage hero + brand cards ===== */
.aac-hero { width: 100%; max-width: 1130px; margin: 0 auto 25px; text-align: center; position: relative; }
.aac-hero img { max-width: 100%; height: auto; }
/* Copy under a hero image. The hero box is up to 1130px but the picture in it
   is 900px (width attr) and centered, so a 900px centered block puts the
   text's left edge exactly under the picture's. Narrower than 900px, both
   simply fill the width. */
.aac-hero-copy { width: 100%; max-width: 900px; margin: 0 auto; text-align: left; }
.aac-brand-cards {
  display: flex;
  flex-direction: column;
  gap: 30px;
  width: 100%;
  max-width: 1130px;
  margin: 0 auto;
}
@media (min-width: 768px) {
  .aac-brand-cards { flex-direction: row; align-items: stretch; gap: 20px; }
}
.aac-brand-card {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.aac-brand-card__logo,
.aac-brand-card__cta { display: inline-block; }
/* The three cards' body copy runs to different lengths, so with the
   row stretched to a shared height (align-items: stretch above) each
   card has different leftover space below its text -- pushing the CTA
   down to that shared bottom edge, rather than letting it sit right
   after wherever its own text happened to end, is what actually lines
   the three buttons up in one row instead of just the row being tall
   enough to allow it. */
.aac-brand-card__cta { margin-top: auto; }
.aac-brand-card__logo img { max-width: 100%; height: auto; }

/* ===== Pill button component (.aac-pill-btn) =====
   Replaces what used to be a family of pre-made button graphics
   (DB content: pages/pages_raw/menus tables -- rollouts, demo,
   aviation, faith2b, ACW_Intercom, gpu_home, mgpu_home -- plus
   index.php's three homepage CTAs) with real text, so hover can
   darken the background the way .aac-buybtn/.aac-btn--brand/
   .aac-blog-topic do -- a raster image has no separate text/
   background layers, so its own hover had to darken the whole flat
   PNG (via filter), dimming the white text along with it. One base
   class plus a color variant per graphic's original palette; any new
   button just needs one of these on an <a>, no new CSS. */
.aac-pill-btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 6px;
  font-size: 16px;
  font-weight: bold;
  text-align: center;
  text-decoration: none;
  transition: background-color .15s ease, box-shadow .15s ease;
}
/* Hover shadow comes from the shared "Button hover elevation" list above. */
/* Red: ascentic-visit400.png/button-WLaviation.png/28v-shop.png (DB
   content) and index.php's three homepage CTAs -- each graphic used
   its own slightly-off red (#b7232a/#d60000/#ce0000); standardized on
   the site's actual brand token instead of preserving three
   near-but-not-quite reds. */
/* Every variant's color is doubled up as .aac-pill-btn.aac-pill-btn--x
   (both classes always present together on the element anyway) so its
   specificity beats a container's own "a { color }" rule -- e.g.
   .aac-highlight-row__text a { color:#fff }, which the "Contact Us"
   button on page/ACW_Intercom sits inside of and would otherwise lose
   its red text to. */
.aac-pill-btn.aac-pill-btn--red { background-color: var(--color-brand); color: #ffffff; }
.aac-pill-btn--red:hover { background-color: var(--color-brand-hover); }
/* Gold: 14v-shop.png. Reuses .aac-buybtn--specialorder's exact gold
   rather than that graphic's own slightly-different #f9bd00, so
   "gold" means one thing site-wide. */
.aac-pill-btn.aac-pill-btn--gold { background-color: var(--color-gold); color: #3a2a00; }
.aac-pill-btn--gold:hover { background-color: var(--color-gold-hover); }
/* Gray: a-visit.png/a-portfolio.png/a-news.png/24v-button-aviation.png/
   12v-button-aviation.png. Text color reuses #5a666e, already used
   for the sidebar heading link right above these buttons in the same
   DB content. */
.aac-pill-btn.aac-pill-btn--gray { background-color: #d0d4d9; color: #4a555c; }  /* was #5a666e: 3.96:1 */
.aac-pill-btn--gray:hover { background-color: #c3c8ce; }
/* page/rollouts + page/demo sidebar: VISIT ASCENTIC/PORTFOLIO/NEWS & BLOG
   stack as three separate buttons (DB content, not a flex/grid group),
   each otherwise shrink-wrapping to its own text width via display:table
   -- widened to match the widest of the three (VISIT ASCENTIC, ~170px)
   so they line up instead of each being a different width. */
.aac-pill-btn--ascentic-nav { width: 170px; box-sizing: border-box; text-align: center; }
/* Gray-accent: ContactUs.png -- same gray fill as above, brand-red
   text instead of slate. */
.aac-pill-btn.aac-pill-btn--gray-accent { background-color: #d0d4d9; color: var(--color-brand); }
.aac-pill-btn--gray-accent:hover { background-color: #c3c8ce; }
/* Slate: questions-button.jpg. The site's nav-band blue-gray
   (--color-nav-gray, the category tiles), not a one-off tone. It used
   to share this value with the pagination current-page pill; that pill
   is brand red now (see "Current page, every pagination" below), so
   this is the remaining use of the gray as a button fill. */
.aac-pill-btn.aac-pill-btn--slate { background-color: #5f6b72; color: #ffffff; }  /* was #7b858a: 3.77:1 */
.aac-pill-btn--slate:hover { background-color: #525d63; }
.aac-brand-card__body { margin: 10px 0; color: #646d74; font-family: Arial, sans-serif; }
.aac-brand-card__body a { color: var(--color-link-blue); }

/* ===== Search results page (search.php) =====
   search.php builds its results by printing HTML strings from PHP, not
   from a template, so the classes it emits are defined here rather than
   near any markup you can read: a rounded card, brand-red button and
   links, matching the visual language used elsewhere on the site. */
.aac-search-form { max-width: 560px; margin: 20px auto 20px; text-align: left; }
.aac-search-form__label { display: block; font-weight: bold; margin-bottom: 6px; }
.aac-search-form__row { display: flex; gap: 8px; }
.aac-search-form__input {
  flex: 1 1 auto;
  min-width: 0;
  box-sizing: border-box;
  height: 38px;
  padding: 0 10px;
  font-size: 15px;
  border: 1px solid var(--color-border-input);
  border-radius: 3px;
}
.aac-search-form__submit {
  flex: 0 0 auto;
  height: 38px;
  padding: 0 18px;
  background-color: var(--color-brand);
  color: #ffffff;
  font-weight: bold;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  transition: background-color .15s ease, box-shadow .15s ease;
}
.aac-search-form__submit:hover { background-color: var(--color-brand-hover); }
.aac-search-form__submit:active { background-color: var(--color-brand-active); }

/* Search-as-you-type dropdown -- javascript/search-autocomplete.js injects
   this into whichever element positions the input (.aac-search-form__row
   for the results-page box, .aac-search for the header quick-search box),
   which is given position:relative at bind time if it wasn't already. */
.aac-autocomplete {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 60;
  margin-top: 4px;
  background-color: #ffffff;
  border: 1px solid var(--color-border-input);
  border-radius: 3px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  overflow: hidden;
}
.aac-autocomplete__item {
  display: block;
  padding: 0.6em 0.9em;
  font-size: 13px;
  color: var(--color-text);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.aac-autocomplete__item.is-active,
.aac-autocomplete__item:hover {
  background-color: var(--color-hover-bg);
  color: var(--color-brand);
}

.aac-search-results { text-align: left; }
/* Query recap reads as the section's implicit heading -- bold and one
   step up from body size, with the plain-body result-count line under
   it kept muted so the two don't compete for the same weight. */
.aac-search-summary { font-size: 18px; font-weight: bold; margin-bottom: 4px; }
/* The product name, the product-listing caption and the search summary
   were already the visual page title but were marked up as <strong> and
   <div>, leaving those ~270 pages with no <h1>. They are <h1> now, so
   neutralise the UA's default heading size/margin/display and let the
   existing classes keep doing the styling -- nothing moves. */
h1.aac-search-summary { font-size: 18px; margin: 0 0 4px; }
.aac-title-inline {
  display: inline;
  margin: 0;
}
/* content_type facet -- lets a visitor narrow to web pages vs. PDF
   manuals vs. other documents instead of only ever seeing them blended. */
.aac-search-facets { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.aac-search-facets__item {
  display: inline-flex;
  align-items: center;
  padding: 0.35em 0.8em;
  font-size: 12px;
  font-weight: bold;
  color: #000000;
  background-color: #ffffff;
  border: 1px solid var(--color-border-input);
  border-radius: 3px;
  text-decoration: none;
}
a.aac-search-facets__item:hover { background-color: var(--color-hover-bg); }
.aac-search-facets__item.is-active { background-color: var(--color-brand); border-color: var(--color-brand); color: #ffffff; }
.aac-search-count { color: var(--color-text-meta); margin-bottom: 16px; }
.aac-search-noresults { padding: 16px 0; text-align: center; }

.aac-search-result {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 0;
  border-bottom: 1px solid #e0e0e0;
}
.aac-search-result__title { font-size: 16px; margin-bottom: 4px; }
.aac-search-result__num { color: #000000; font-weight: bold; margin-right: 8px; }
.aac-search-result__title a { color: var(--color-brand); font-weight: bold; text-decoration: none; }
.aac-search-result__title a:hover { text-decoration: underline; }
.aac-search-result__desc { font-size: 13px; color: var(--color-text-secondary); margin-bottom: 4px; }
.aac-search-result__meta { font-size: 12px; color: var(--color-text-meta); }
.aac-search-result__url { color: var(--color-text-meta); }
.aac-search-result__size { color: var(--color-text-meta); }

/* Search-term highlight in result snippets -- a warm gold on-theme with
   the site's brand red rather than the old engine's stock bright-yellow
   #ff0/red-#f00 pairing, which fights the red already used for result
   titles and links right next to it. */
.aac-search-hl {
  background-color: #fbe3a1;
  color: var(--color-brand);
  font-weight: bold;
  border-radius: 2px;
  padding: 0 2px;
}

.aac-search-nav-wrap { margin-top: 16px; text-align: center; }
.aac-search-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 12px; }
/* Matches product_list.php/blog.php's pagination buttons
   (.aac-prodlist-pagination / .aac-blog-pagination__nav) exactly --
   bordered, curved, bold pill for each page link, gray-filled pill (not
   a link) for the current page -- rather than a third one-off pagination
   style on the same site. */
.aac-search-nav a,
.aac-search-nav span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  padding: 0.6em 0.9em;
  color: #000000;
  background-color: #ffffff;
  border: 1px solid var(--color-border-input);
  border-radius: 3px;
  font-weight: bold;
  text-decoration: none;
  box-sizing: border-box;
}
.aac-search-nav a { transition: background-color .15s ease, box-shadow .15s ease; }
.aac-search-nav a:hover { background-color: var(--color-hover-bg); }

/* Visually hidden but reachable by assistive tech -- standard clip-based
   pattern, not display:none (which screen readers also skip). */
/* Reduced motion (WCAG 2.3.3, and the vestibular-disorder case behind it).
   The site has 20 transition declarations and no keyframe animations, so
   there is nothing here that flashes or parallaxes -- but "no seizures"
   and "no nausea" are different bars, and a user who has asked their OS
   for less motion has asked for all of it, not the dramatic parts.

   Near-zero rather than `none`: a 0s transition makes transitionend fire
   in some engines and never in others, and anything listening for it
   silently stops working. 0.01ms keeps the event and removes the motion.

   scroll-behavior is included because the skip link added above jumps to
   #main; if smooth scrolling is ever turned on sitewide, this is already
   the right guard. */
@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;
  }
}

/* Skip link (templates/header.php). Off-screen until focused, then it
   lands as a real, visible control at the top-left -- a skip link that
   stays invisible when focused is worse than none, because the keyboard
   user cannot tell where they are.

   It is NOT .aac-visually-hidden: that clips to 1px permanently, and the
   whole point here is to become visible on :focus. Colours come from the
   brand tokens so it reads as part of the site rather than a bolted-on
   accessibility widget. The z-index clears .aac-topbar, which is sticky
   at z-index 50. */
.aac-skip-link {
  position: absolute;
  left: 8px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--color-brand);
  color: #ffffff;
  font-size: 14px;
  text-decoration: none;
  border-radius: 0 0 3px 3px;
  transition: top .15s ease;
}
.aac-skip-link:focus,
.aac-skip-link:focus-visible {
  top: 0;
  outline: 2px solid #ffffff;
  outline-offset: -4px;
}
/* The target takes tabindex="-1" so focus really moves; suppress the
   focus ring on it, since the user asked to go there and a box around
   the entire page is noise, not feedback. */
#main:focus { outline: none; }

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

/* ===== Reusable label/input form-row pattern =====
   Mobile-first: each row stacks (label above its field) below
   min-width:600px, and sits side by side (fixed-width label column,
   flexible field column) above it. Used by contact.php's field grid;
   reused by checkout/credit-authorization's form_desc/form_desc_data
   rows too (same underlying grid, different class names there since
   that markup is generated by a much larger set of pages). */
.aac-form-shell { display: flex; flex-direction: column; gap: 20px; }
@media (min-width: 768px) {
  .aac-form-shell { flex-direction: row; align-items: flex-start; gap: 30px; }
}
.aac-form-main { flex: 1 1 auto; min-width: 0; }
.aac-form-side { flex: 0 0 auto; }
@media (min-width: 768px) {
  .aac-form-side { width: 220px; }
}
.aac-form-fields { display: flex; flex-direction: column; gap: 18px; margin-top: 14px; }
.aac-form-row { display: flex; flex-direction: column; gap: 6px; }
@media (min-width: 600px) {
  .aac-form-row:not(.aac-form-row--full) { flex-direction: row; align-items: center; gap: 10px; }
  .aac-form-row:not(.aac-form-row--full) > label { flex: 0 0 130px; }
  .aac-form-row__data { flex: 1 1 auto; min-width: 0; }
}
.aac-form-row > label {
  font-size: .78em;
  font-weight: 700;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: #646d74;
}
/* Was five copies of style="width:350px; height:30px" on the individual
   inputs; centralized here so the sizing is a single source of truth.
   max-width keeps it from overflowing narrow viewports even though
   .aac-body input already guarantees that sitewide. Covers email/tel
   too, not just text, since c_from/c_from2/c_phone use those types. */
.aac-form-row__data input[type="text"],
.aac-form-row__data input[type="email"],
.aac-form-row__data input[type="tel"] {
  width: 100%;
  max-width: 420px;
  height: 42px;
  padding: 0 14px;
  box-sizing: border-box;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  font-size: 16px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.aac-form-row textarea {
  width: 100%;
  max-width: 600px;
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  box-sizing: border-box;
  font-size: 16px;
  font-family: inherit;
  resize: vertical;
}
/* background-color explicitly reset: menu.css's sitewide legacy
   input:focus rule paints every focused field a pale yellow
   (background:#FFC), which fights this modern red focus ring instead
   of ceding to it -- more specific here, so it wins, but only once
   background-color is retaken too, not just border-color/box-shadow. */
.aac-form-row__data input[type="text"]:focus,
.aac-form-row__data input[type="email"]:focus,
.aac-form-row__data input[type="tel"]:focus,
.aac-form-row textarea:focus {
  outline: none;
  background-color: #ffffff;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(185, 0, 0, .12);
}
/* Primary CTA: was a bare, unstyled <input type="submit"> -- the one
   control on the page that actually sends the message had no brand
   treatment or interaction states at all. Reuses the site's existing
   heading/accent red (#b90000, see .aac-bandred / the "Questions?"
   heading) rather than inventing a new brand color.
   .aac-btn--brand, not a bare .submit: credit_authorization(_intl).php
   also has inputs carrying class="submit" (its own, unstyled, base
   browser look) -- those are live payment-flow pages this change has
   no business touching, so the new look is opt-in per class instead
   of redefining a class name they already use for something else. */
.aac-btn--brand {
  display: inline-block;
  background-color: var(--color-brand);
  color: #ffffff;
  font-size: 14px;
  font-weight: bold;
  border: 0;
  border-radius: 6px;
  padding: 12px 22px;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.15s ease, box-shadow 0.15s ease;
}
/* Hover shadow comes from the shared "Button hover elevation" list --
   see that block, above .aac-buybtn. */
.aac-btn--brand:hover { background-color: var(--color-brand-hover); }
.aac-btn--brand:focus-visible { outline: 2px solid var(--color-brand-hover); outline-offset: 2px; }
.aac-btn--brand:active { background-color: var(--color-brand-active); }

/* A centered row of two or more buttons (e.g. page/faith2a's "More About
   Christianity" + "Questions for Jonathan Sisk"). DB-authored content
   spaced these with `&nbsp;&nbsp;` between the links, which is a
   horizontal gap only: once the row is narrow enough for the buttons to
   wrap onto separate lines they end up stacked edge to edge with nothing
   between them. A flex row with a real gap spaces them in both axes. */
.aac-btn-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
}

/* ===== Contact page (contact.php) ===== */
/* margin-top lines this up with the "Support" heading atop the left
   sidebar's category menu (.aac-sidemenu__scoped h2) -- both sit in
   independent layout columns with different default spacing above,
   so without it "Questions?" renders noticeably higher than its
   sidebar counterpart. */
.aac-contact__title { margin-bottom: 6px; color: var(--color-brand); }
.aac-contact__lede { margin: 0 0 24px; max-width: 560px; color: var(--color-text-tertiary); }
.aac-contact__notice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 24px;
  padding: 14px 16px;
  background-color: var(--color-error-bg);
  border: 1px solid var(--color-error-border);
  border-radius: 8px;
  color: var(--color-error-text);
}
.aac-contact__notice-icon { flex: 0 0 auto; margin-top: 2px; color: var(--color-brand); }
.aac-contact__notice-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.aac-contact__notice-links a {
  display: inline-block;
  padding: 6px 14px;
  background-color: #ffffff;
  border: 1px solid var(--color-brand);
  border-radius: 999px;
  color: var(--color-brand);
  font-size: .9em;
  font-weight: 600;
  text-decoration: none;
  transition: background-color .15s ease, color .15s ease;
}
.aac-contact__notice-links a:hover { background-color: var(--color-brand); color: #ffffff; }

.aac-alert {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 20px;
  padding: 12px 16px;
  border-radius: 8px;
  font-weight: 600;
}
.aac-alert--error { background-color: var(--color-error-bg); border: 1px solid var(--color-error-border); color: var(--color-error-heading); }
.aac-alert__icon { flex: 0 0 auto; margin-top: 1px; }

/* Neutral in-page callout box (e.g. page/Return's "Return Authorization
   Number required" notice) -- distinct from .aac-alert--error (a form
   validation error) and .aac-webnotice (the sitewide banner). */
.aac-notice { background-color: #e3eaf5; border: 1px solid #b9c6dd; border-radius: 8px; padding: 14px 20px; margin: 0 0 20px; text-align: center; font-weight: 600; }
.aac-notice p { margin: 0; }

.aac-contact-panel {
  background-color: var(--color-panel-bg);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 20px;
}
.aac-contact-panel__section + .aac-contact-panel__section { margin-top: 18px; }
.aac-contact-panel__row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: .95em;
  line-height: 1.5;
  color: var(--color-text-secondary);
}
.aac-contact-panel__row + .aac-contact-panel__row { margin-top: 14px; }
.aac-contact-panel__icon { flex: 0 0 auto; margin-top: 2px; color: var(--color-brand); }
.aac-contact-panel__note { margin-top: 6px; color: var(--color-text-meta, #707070); font-size: .85em; }  /* was #767676: 4.3:1 on the panel bg */
.aac-contact-panel__divider { height: 1px; background-color: var(--color-border); margin: 18px 0; }
.aac-contact-panel .aac-btn--brand { display: block; width: 100%; text-align: center; margin-top: 14px; }
/* The captcha widget is a fixed 304px wide (javascript/captcha-fit.js
   scales it to fit narrow containers). Exempt it from the sitewide
   `.aac-body div/iframe { max-width: 100% }` guard, which otherwise
   squeezes its inner elements to the container's width and clips the
   widget's right border. */
.g-recaptcha, .g-recaptcha div, .g-recaptcha iframe,
.cf-turnstile, .cf-turnstile div, .cf-turnstile iframe { max-width: none !important; }

.aac-contact__success {
  max-width: 480px;
  margin: 40px auto;
  padding: 32px 24px;
  background-color: var(--color-success-bg);
  border: 1px solid var(--color-success-border);
  border-radius: 10px;
  color: var(--color-success-text);
  text-align: center;
}
.aac-contact__success-icon { color: var(--color-success-icon); margin-bottom: 12px; }
.aac-contact__success h2 { margin: 0 0 8px; color: inherit; }
.aac-contact__success p { margin: 4px 0; }
.aac-contact__success a { color: inherit; font-weight: 600; }

/* ===== Blog (blog.php) ===== */
.aac-blog { width: 100%; max-width: 885px; margin: 0 auto; text-align: left; }

/* Topic pills atop the listing view -- was three fixed-red rectangular
   buttons with inline styles; now shares the pill language the rest of
   the site's chips/tags use. */
.aac-blog-topics {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  padding: 10px 0 20px;
}
.aac-blog-topic {
  display: inline-block;
  padding: 8px 20px;
  border: 1px solid var(--color-brand);
  border-radius: 999px;
  color: var(--color-brand);
  font-size: 13px;
  font-weight: bold;
  letter-spacing: .02em;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .15s ease, color .15s ease, box-shadow .15s ease;
}
.aac-blog-topic:hover { background-color: var(--color-brand); color: #ffffff; }
.aac-blog-topic--active { background-color: var(--color-brand); color: #ffffff; }

/* Listing grid: one column under 700px, two columns at and above it --
   matches the breakpoint .aac-globalmenu's two-column list already uses
   for the same "content area inside the sidebar layout" width. */
.aac-blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin: 0;
}
@media (min-width: 700px) {
  .aac-blog-grid { grid-template-columns: 1fr 1fr; }
}

.aac-blog-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  overflow: hidden;
}
.aac-blog-card__media {
  display: block;
  width: 100%;
  aspect-ratio: 855 / 338;
  object-fit: cover;
  background-color: var(--color-hover-bg);
}
.aac-blog-card__body { display: flex; flex-direction: column; flex: 1 1 auto; padding: 16px 18px 18px; }
.aac-blog-card__title { margin: 0 0 8px; font-size: 18px; font-weight: 600; line-height: 1.3; }
.aac-blog-card__title a { color: var(--color-brand); text-decoration: none; }
.aac-blog-card__title a:hover { text-decoration: underline; }
.aac-blog-card__tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 12px; }
/* Muted brand red rather than the surrounding grays (tags: #767676,
   excerpt: --color-text-tertiary) so the date reads as its own bit of
   metadata instead of blending into either. */
.aac-blog-card__date { font-size: 12px; color: rgba(185, 0, 0, 0.55); margin-right: 4px; }
.aac-blog-card__excerpt { flex: 1 1 auto; margin: 0 0 14px; font-size: 14px; line-height: 1.6; color: var(--color-text-tertiary); }
.aac-blog-card__excerpt p:first-child { margin-top: 0; }
.aac-blog-card__excerpt p:last-child { margin-bottom: 0; }
.aac-blog-card__cta { align-self: flex-start; font-size: 13px; font-weight: bold; letter-spacing: .02em; color: var(--color-brand); text-decoration: none; }
.aac-blog-card__cta:hover { text-decoration: underline; }

/* Small gray pill tags -- shared between listing cards and the single-
   post view below. */
.aac-blog-tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  background-color: var(--color-hover-bg);
  color: #666666;  /* was #767676: 4.06:1 on this background */
  font-size: 11px;
  text-decoration: none;
}
.aac-blog-tag:hover { background-color: #e6e6e6; }

/* ===== Blog: single-post view ===== */
/* margin-top matches blog.php's $top=15 inline offset on
   .aac-blog-subscribe, which is what actually positions the sidebar box
   at this width -- keeps the post's hero image top edge level with the
   sidebar's top edge instead of sitting 15px above it. */
.aac-blog-post__media { display: block; width: 100%; height: auto; max-height: 460px; object-fit: cover; border-radius: 10px; margin-top: 15px; margin-bottom: 20px; }
.aac-blog-post__title { margin: 0 0 10px; font-size: 26px; font-weight: 600; line-height: 1.3; color: var(--color-brand); }
.aac-blog-post__tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 22px; }
.aac-blog-post__date { font-size: 13px; color: rgba(185, 0, 0, 0.55); margin-right: 4px; }
.aac-blog-post__body { font-size: 16px; line-height: 1.7; color: var(--color-text-secondary); }
.aac-blog-post__body img { max-width: 100%; height: auto; border-radius: 8px; }
.aac-blog-post__share {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
  padding-top: 22px;
  border-top: 1px solid var(--color-border);
}
.aac-blog-post__share-label { font-weight: bold; margin-right: 4px; }
.aac-blog-post__share-icons { display: flex; gap: 10px; }
/* svg as well as img: the tiles are inline SVG now (blog.php), and an
   inline svg is display:inline by default, which leaves a descender gap
   under each one inside the flex row. */
.aac-blog-post__share-icons img,
.aac-blog-post__share-icons svg { display: block; }

/* ===== Blog: "Let's Stay Connected" subscribe card (sidebar) ===== */
.aac-blog-subscribe {
  background-color: var(--color-panel-bg);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 18px;
  text-align: left;
}
.aac-blog-subscribe__title { margin: 0 0 6px; font-size: 18px; }
.aac-blog-subscribe__note { margin: 0 0 16px; font-size: .8em; color: var(--color-text-meta, #707070); text-align: right; }  /* #767676 is 4.3:1 on the panel bg */
.aac-blog-subscribe__field { display: block; margin-bottom: 14px; }
.aac-blog-subscribe__label { display: block; margin-bottom: 6px; font-size: 13px; font-weight: bold; }
.aac-blog-subscribe__input {
  display: block;
  width: 100%;
  height: 38px;
  padding: 0 10px;
  box-sizing: border-box;
  font-size: 15px;
  border: 1px solid var(--color-border-input);
  border-radius: 3px;
}
.aac-blog-subscribe__captcha { margin: 0 0 14px; }
.aac-blog-subscribe .aac-btn--brand { width: 100%; text-align: center; border: none; }

/* ===== Blog: pagination ===== */
.aac-blog-pagination { width: 100%; max-width: 885px; padding: 10px 0 0; box-sizing: border-box; text-align: center; }
.aac-blog-pagination__cell--center { padding: 8px 0; }
.aac-blog-pagination__nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 12px; }
/* Matches the product_list pagination buttons (.aac-prodlist-pagination
   above) -- bordered, curved, bold, sized for a real tap target instead
   of a bare text link. */
.aac-blog-pagination__nav a,
.aac-blog-pagination__nav span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  padding: 0.6em 0.9em;
  color: #000000;
  background-color: #ffffff;
  border: 1px solid var(--color-border-input);
  border-radius: 3px;
  font-weight: bold;
  text-decoration: none;
  box-sizing: border-box;
}
.aac-blog-pagination__nav a { transition: background-color .15s ease, box-shadow .15s ease; }
.aac-blog-pagination__nav a:hover { background-color: var(--color-hover-bg); }

/* ===== Current page, every pagination =====
   The three pagination sets (product_list.php's div.product_nav, which
   blog.php also uses; .aac-blog-pagination__nav; .aac-search-nav) each
   mark the page you are on with a filled pill that is deliberately not
   a link. That fill was #7b858a -- the same gray as the nav band, which
   read as "disabled" rather than "you are here". Brand red instead, the
   one color on this site that already means "active/primary" (the Add
   and Go to buttons, .aac-pill-btn--red, .aac-btn--brand).

   Grouped in one rule rather than restated in three places so the three
   sets cannot drift apart again. White on #b90000 is 6.8:1, past AA for
   normal text; the border matches the fill so the pill doesn't keep a
   gray outline around a red face. */
div.product_nav span.red,
.aac-blog-pagination__nav span,
.aac-search-nav span {
  color: #ffffff;
  background-color: var(--color-brand);
  border-color: var(--color-brand);
}

/* ===== Download-list filter form ===== */
.aac-dlfilter {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 24px;
  padding: 16px 18px;
  background-color: var(--color-panel-bg);
  border: 1px solid var(--color-border);
  border-radius: 10px;
}
@media (min-width: 768px) {
  .aac-dlfilter { flex-direction: row; align-items: center; gap: 24px; }
}
.aac-dlfilter__fields { display: flex; flex-direction: column; gap: 12px; }
@media (min-width: 500px) {
  .aac-dlfilter__fields { flex-direction: row; align-items: flex-end; gap: 16px; }
}
.aac-dlfilter__row { display: flex; flex-direction: column; gap: 4px; }
.aac-dlfilter__row label {
  font-size: .78em;
  font-weight: 700;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: #646d74;
}
.aac-dlfilter__row select {
  height: 42px;
  padding: 0 12px;
  min-width: 160px;
  box-sizing: border-box;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background-color: #ffffff;
  /* 16px, not 15px: iOS Safari zooms the whole page in when a form
     control smaller than 16px takes focus, and does not zoom back out.
     These two selects were the site's last sub-16px controls. */
  font-size: 16px;
}
.aac-dlfilter__row select:focus {
  outline: none;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(185, 0, 0, .12);
}
.aac-dlfilter__row--submit { flex-direction: row; }
.aac-dlfilter__help { max-width: 420px; color: var(--color-text-tertiary); font-size: .92em; line-height: 1.5; }

/* ===== Download-list results (downloadlist.php) ===== */
/* margin-top lines this up with the left sidebar's own category
   heading (e.g. "Drive-up Intercom Systems for Banks and Pharmacies",
   .aac-sidemenu__scoped h2) -- same gap and same reason as
   .aac-contact__title's, two independent columns with different
   default spacing above. */
.aac-downloads__title { margin-bottom: 20px; color: var(--color-brand); }
.aac-download-results { display: flex; flex-direction: column; gap: 36px; }
.aac-download-group { padding-top: 4px; }
.aac-download-group:not(:first-child) {
  margin-top: 8px;
  padding-top: 28px;
  border-top: 1px solid var(--color-border);
}
.aac-download-group__title { margin: 0 0 14px; font-size: 1.2em; }
.aac-download-group__title span { font-weight: 400; color: var(--color-text-tertiary); }
/* One consistent uppercase micro-label for the type grouping (Manuals,
   Firmware, Drawings, ...) instead of a bare <b>, matching the same
   label treatment used sitewide (e.g. the sitemenu's PRODUCTS/SUPPORT
   dividers) rather than inventing a new one just for this page. */
.aac-download-type {
  margin: 18px 0 6px;
  color: #646d74;
  font-weight: 700;
  font-size: .8em;
  letter-spacing: .4px;
  text-transform: uppercase;
}
.aac-download-group__summary + .aac-download-type { margin-top: 0; }
.aac-download-list { list-style: none; margin: 0; padding: 0; }
.aac-download-item {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--color-divider);
  line-height: 1.5;
}
.aac-download-list li:last-child { border-bottom: 0; }
/* Icon lives inside the link now (not a separate sibling) so the whole
   row -- icon and text alike -- is one click target; text-decoration
   is dropped here since the icon isn't text to underline, but color
   is left alone so the link keeps its normal blue rather than reading
   as plain text. */
.aac-download-item__link { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
.aac-download-item__icon { flex: 0 0 auto; width: 16px; height: 16px; }
.aac-download-item__size { color: var(--color-text-meta, #707070); font-size: .88em; }
/* Some downloads.text_desc rows have their own authored <br>/<strong>/
   <ul> markup for release notes -- rendered as real HTML now (matches
   how every other admin-authored content field is already treated
   sitewide: pages.content, products.long_desc/faq, menus.menu are all
   echoed unescaped too; text_desc being the one escaped field was an
   inconsistency, not a deliberate trust boundary). Nested <ul>s need
   their own spacing/indent -- unstyled, they'd otherwise inherit the
   body copy's own left edge with no visual sign they're a sub-list. */
.aac-download-item__desc { flex-basis: 100%; color: var(--color-text-tertiary); font-size: .92em; }
.aac-download-item__desc ul { margin: 4px 0; padding-left: 20px; }
.aac-download-item__desc li { margin: 2px 0; }
.aac-download-item__desc strong { color: var(--color-text-secondary); }
/* Product-page download list (product_details.php).

   The group spacing here used to come from a bare <br> before each group
   inside the <ul>, which is invalid -- a <ul> takes only <li>. The markup
   now nests each group's list inside its own <li>; these two rules
   reproduce the gap the <br>s used to make, so the page looks unchanged.

   .aac-prod-section__title keeps "Downloads" and "Related Products" at the
   size they rendered at as <h3>. They became <h2> because they are direct
   subsections of the page's <h1> and an h1 -> h3 jump skips a level for
   anyone navigating by heading. */
.aac-download-groups > li { margin-top: 1em; }
.aac-download-groups { margin-bottom: 1em; }
/* No nested indent: the files line up with their group name instead of
   stepping in another 40px. The bullets stay; the outer list keeps just
   enough padding for them to hang at the left edge, so every bullet (group
   and file) sits in the same column and wrapped text lines up with the
   text above it. */
.aac-download-groups { padding-left: 1.2em; }
.aac-download-groups ul { padding-left: 0; }
/* A little air above the "Downloads" heading: the DB-authored heading at
   the top of the Downloads tab (hidden on mobile, where the accordion
   button replaces it) and the standalone h2 used when downloads aren't in
   a tab. */
.tab:has(> .aac-download-groups) > .tab__dup-heading,
#downloads { padding-top: 20px; }
.aac-prod-section__title { margin: 0; font-size: 1.17em; }

.aac-download-empty {
  padding: 32px 16px;
  text-align: center;
  color: var(--color-text-tertiary);
  background-color: var(--color-panel-bg);
  border: 1px solid var(--color-border);
  border-radius: 10px;
}

/* ===== Product listing ===== */
/* Mobile-first: the sidebar text column stacks below the listing, and
   each product row stacks image-above-description, below 1041px/500px
   respectively; both become side-by-side above those widths. */
/* SITE-WIDE PAGE-HEADER STANDARD
   ------------------------------
   A page's own header sits on the same line as the category heading in
   the side menu beside it, at the same size, so the two read as peers
   rather than one being an afterthought.

   The side menu's heading (.aac-sidemenu__scoped h2) renders at 19.5px
   /700 in the brand red, 15px below the top of its column, and both
   columns start at the same y -- so a page header matching those two
   numbers lands on the same line automatically at every desktop width.

   Weight and colour already matched everywhere; only size and the top
   offset needed stating. Apply .aac-page-title to the header element
   and let the page's own class keep any padding/margin-bottom.

   Below 1041px the side menu collapses into the hamburger, so there is
   nothing to align to and only the size applies. */
.aac-page-title {
  margin-top: 15px;
  font-size: 19.5px;
  line-height: normal;
}
/* The product name is this page's header, but the model/status text sits
   inline beside it, so the h1 stays inline -- margin-top does not apply
   to an inline box, and the standard's 15px offset comes from the panel
   instead. It used to be two leading <br />, which put it at 30px. */
.rounded_box.aac-product { margin-top: 15px; }
/* The model/status line under the product name. It was an inline <span>
   sitting on the h1's line, which reads fine for "1510" but breaks down
   as soon as the name is long: "Video Display for 1527 or OEM Driveup"
   filled the line, leaving the word "Model" stranded on the end of the
   title and "641-014-AA" wrapped onto the next line by itself.

   Block here rather than making the h1 a block, because the h1's
   display:inline is load-bearing for the margin note directly above. */
.aac-product__model { display: block; margin-top: 2px; }
/* CMS pages: the content is DB-authored and opens in several shapes --
   a bare <h2>, or one wrapped in a layout div -- whose own top margins
   differ, so simply dropping the leading <br /> landed them anywhere
   from 151px to 167px. State the 15px on the panel instead and zero
   whatever margin the first thing in the content brings with it (one
   level down too, since a wrapper's first child collapses its margin
   up through the wrapper). */
.aac-page-content { padding-top: 15px; }
/* The page's visually-hidden <h1> is out of flow but still :first-child,
   so the content's own opening element is matched through it. */
.aac-page-content > :first-child,
.aac-page-content > .aac-visually-hidden + * { margin-top: 0; }
/* Content often opens with a layout row (.aac-content-row is a flex
   container, so a heading inside it cannot collapse its margin out to
   the row). Zero the margin on a heading that OPENS that first block at
   any depth -- scoped to the opening block so mid-page section headings
   keep their spacing. */
.aac-page-content > .aac-visually-hidden + * h1:first-child,
.aac-page-content > .aac-visually-hidden + * h2:first-child,
.aac-page-content > .aac-visually-hidden + * h3:first-child { margin-top: 0; }
/* Authors used <h1> on 43 CMS pages and <h2> on 75, so the same visual
   role rendered at 26px on some pages and 19.5px on others. Where the
   heading OPENS the page -- the case where it lands on the side menu
   heading's line -- it takes the standard size. A heading further down
   the page (under a hero image, say) has nothing to line up with and
   keeps whatever size it was authored at. */
.aac-page-content > .aac-visually-hidden + h1,
.aac-page-content > .aac-visually-hidden + h3,
.aac-page-content > .aac-visually-hidden + * h1:first-child,
.aac-page-content > .aac-visually-hidden + * h3:first-child { font-size: 19.5px; }
.aac-prodlist__title {
  /* 30px below preserves the gap the three trailing <br /> used to make,
     so only the header itself moves. */
  margin-bottom: 30px;
  padding-left: 32px;
}
.aac-prodlist { display: flex; flex-direction: column; gap: 20px; width: 100%; }
@media (min-width: 1041px) {
  .aac-prodlist { flex-direction: row; max-width: 967px; }
}
.aac-prodlist__main { flex: 1 1 auto; min-width: 0; }
.aac-prodlist__side { flex: 0 0 auto; text-align: left; }
@media (min-width: 1041px) {
  .aac-prodlist__side { flex: 0 0 200px; width: 200px; }
}
/* Card grid, not a list of horizontal rows: explicit column counts per
   tier (matching this codebase's existing breakpoint convention,
   500/768/1041) rather than auto-fill/minmax -- auto-fill's column
   count is sized off the container alone, but a few product names/
   descriptions here are long enough to push their card's min-content
   width past a 190px cap, which collapsed the row to a single column
   instead of letting the overflow wrap inside a fixed-width track. */
.aac-prodlist__main .rounded_content {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px 24px;
}
@media (min-width: 500px) {
  .aac-prodlist__main .rounded_content { grid-template-columns: repeat(3, 1fr); gap: 28px 28px; }
}
@media (min-width: 768px) {
  .aac-prodlist__main .rounded_content { grid-template-columns: repeat(4, 1fr); gap: 28px 32px; }
}
@media (min-width: 1041px) {
  /* Full desktop tier: the compressed/tablet gap above still reads a
     little tight once there's a full 967px-max-width row (minus the
     200px sidebar) to breathe in. */
  .aac-prodlist__main .rounded_content { gap: 28px 48px; }
}
.aac-prodlist__item {
  display: flex;
  flex-direction: column;
  /* Stretch (the default), not center: centering here would let each
     flex child (the image wrapper, the info block) shrink-to-fit its
     own content instead of filling the card's full width, which then
     left the "Where to Buy" button's own width:100% resolve against
     that shrunk width instead of the actual card -- text-align:center
     centers the inline content without that side effect. */
  gap: 6px;
  text-align: center;
  /* Grid items default to min-width:auto, which lets a card's content
     (long unbroken text, the fixed-width product image) push wider
     than its 1fr track instead of shrinking to fit -- causing the
     whole grid, and the page, to overflow horizontally. */
  min-width: 0;
  /* Grid rows stretch items to the tallest item's height by default,
     but a flex column only consumes that extra space if told to --
     height:100% plus the actions row's margin-top:auto (below) is what
     actually pins every card's CTA button to the same baseline across
     a row, regardless of how long that product's description is. */
  height: 100%;
}
/* The card's img tag still carries width="152" height="114" attributes
   (a fixed thumbnail size reused elsewhere on the site) -- overridden
   here so the picture spans the same full card width as the "Where to
   Buy" button below it, rather than sitting narrower and centered.
   a/.img-shadow need display:block too, since inline elements only
   shrink-wrap their content instead of stretching to the card's width. */
.aac-prodlist__item-image { flex: 0 0 auto; text-align: center; }
.aac-prodlist__item-image a,
.aac-prodlist__item-image .img-shadow { display: block; }
.aac-prodlist__item-image img {
  width: 100%;
  height: auto;
  box-sizing: border-box;
  margin: 0;
}
.aac-prodlist__item-info { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.aac-prodlist__item-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  /* auto, not a fixed 6px: pushes the CTA/Details block down to the
     bottom of the card so it lines up with its neighbors in the same
     row even when a shorter description leaves extra space above. */
  margin-top: auto;
  padding-top: 6px;
  width: 100%;
}
/* Card layout only -- color/state styling comes from .aac-buybtn (shared
   with the product detail page's CTA, see below). Both buttons take the
   same width/padding so the pair reads as one stacked block; only the
   color separates the buy action from the secondary "Product Details"
   link. */
.aac-prodlist__cta,
.aac-prodlist__details { width: 100%; padding: 8px 10px; }

.aac-prodlist-pagination {
  width: 100%;
  max-width: 960px;
  margin-top: 10px;
  margin-bottom: 8px;
}
/* Page-number and prev/next (<< / >>) buttons: bigger tap area and more
   breathing room between them than the shared div.product_nav base
   (menu.css, also used by blog.php's pagination, so scoped here rather
   than changed there) -- and curved/bold to match .aac-buybtn's "How to
   Buy" CTA look instead of the old square-cornered box. */
.aac-prodlist-pagination div.product_nav a,
.aac-prodlist-pagination div.product_nav span.red {
  padding: 0.6em 0.9em;
  margin-right: 6px;
  border-radius: 3px;
  font-weight: bold;
}
/* Hover feedback on the clickable links only -- matches .aac-buybtn--info's
   hover treatment; the current-page span.red isn't a link, so it's left
   alone. */
.aac-prodlist-pagination div.product_nav a { transition: background-color .15s ease, box-shadow .15s ease; }
.aac-prodlist-pagination div.product_nav a:hover { background-color: var(--color-hover-bg); }

/* ===== page/Service_policy (DB content, pages.content) =====
   Class names are unique enough (aac-policy__*) to live unscoped --
   this content only ever renders inside the generic .rounded_content
   template shared by every simple content page, so there's no
   dedicated wrapper to hang a scoping class on, unlike the bespoke
   PHP templates (contact.php, credit_authorization.php) elsewhere in
   this file. */
.aac-policy__effective { margin: 0 0 4px; color: var(--color-text-meta, #707070); font-size: .9em; }
/* A plain div grid, not a <table> -- a real table here would fall
   under the sitewide "stack every cell of a table on phones" rule
   (built for 2-column photo-beside-text layouts), which flattens a
   table into DOM order: both header cells first, then every data
   cell after with no per-row grouping. For a genuine label/value
   table like this one, that reads as two disconnected header bars
   sitting above an unlabeled list -- not just unstyled, actually
   ambiguous about which value belongs to which column. Building it
   as rows of plain divs sidesteps that rule entirely and lets each
   stacked field carry its own inline label instead. */
.aac-policy__table-wrap { margin: 16px 0; }
.aac-policy__table {
  max-width: 620px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  overflow: hidden;
}
/* The 620px cap above never actually applied: every consumer of this
   component renders inside .aac-body (page/Service_policy and
   page/rollouts-ascentic via page.php, plus product long_desc -- the
   1580S and 1500BH AWG tables), and the sitewide
   ".aac-body div { max-width: 100% }" overflow guard outspecifies a bare
   .aac-policy__table (class+element beats class alone). A 2-column table
   of short values therefore stretched the full content column. Restate
   the cap at matching specificity so it wins. */
.aac-body .aac-policy__table { max-width: 620px; }
.aac-policy__row { display: grid; grid-template-columns: 1fr 1fr; }
.aac-policy__row:not(:last-child) { border-bottom: 1px solid var(--color-border); }
.aac-policy__row > div { padding: 10px 16px; }
.aac-policy__row--head {
  background-color: var(--color-brand);
  color: #ffffff;
  font-size: .85em;
  letter-spacing: .3px;
  text-transform: uppercase;
}
.aac-policy__row:not(.aac-policy__row--head):nth-child(even) { background-color: var(--color-panel-bg); }
.aac-policy__label { display: none; }
@media (max-width: 599px) {
  .aac-policy__row--head { display: none; }
  .aac-policy__row { grid-template-columns: 1fr; }
  .aac-policy__row > div:first-child { border-bottom: 1px solid var(--color-border); }
  .aac-policy__label {
    display: block;
    margin-bottom: 2px;
    color: #646d74;
    font-weight: 700;
    font-size: .75em;
    letter-spacing: .3px;
    text-transform: uppercase;
  }
}
.aac-policy__callout {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  max-width: 620px;
  margin: 20px auto;
  padding: 16px 20px;
  background-color: var(--color-error-bg);
  border: 1px solid var(--color-error-border);
  border-radius: 8px;
  color: var(--color-error-text);
  text-align: center;
}
.aac-policy__callout svg { flex: 0 0 auto; color: var(--color-brand); }
.aac-policy__callout p { margin: 0; font-weight: 700; }
.aac-policy__docs { display: flex; flex-direction: column; gap: 8px; margin: 16px 0; }
.aac-policy__doc {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  text-decoration: none;
}
.aac-policy__disclaimer { color: var(--color-text-meta, #707070); font-size: .85em; }

/* ===== page/glossary(-*) (DB content, pages.content) =====
   145 term/definition pairs -- was a <table> (no header row, so it
   didn't have Service_policy's exact stacking bug, but still forced
   every definition into a fixed 735px column and needed the sitewide
   table-stacking overrides to be readable on a phone at all). A <dl>
   is the actually-correct element for a glossary and needs none of
   that: dt/dd are block-level by nature, so it's responsive with no
   special-casing. Each dt+dd pair is wrapped in its own <div> (valid
   HTML5 inside dl, added to the spec for exactly this grouping case)
   so zebra striping and spacing can target one row at a time. */
.aac-glossary__title { margin: 20px 0 12px; color: var(--color-brand); }
.aac-glossary__intro { max-width: 800px; margin: 0 0 20px; color: var(--color-text-tertiary); line-height: 1.6; }
.aac-glossary__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  align-items: baseline;
  margin: 20px 0;
  padding: 12px 16px;
  background-color: var(--color-panel-bg);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  font-weight: 700;
}
.aac-glossary__nav a { text-decoration: none; }
.aac-glossary__nav a:hover { text-decoration: underline; }
.aac-glossary__nav-current { color: var(--color-brand); }
.aac-glossary { margin: 0; }
.aac-glossary__entry {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 4px 24px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--color-divider);
}
.aac-glossary__entry:nth-child(even) { background-color: var(--color-panel-bg); }
.aac-glossary__entry dt { font-weight: 700; color: #222222; }
.aac-glossary__entry dd { margin: 0; color: var(--color-icon); line-height: 1.5; }
@media (max-width: 599px) {
  .aac-glossary__entry { grid-template-columns: 1fr; gap: 2px; }
}

/* ===== page/employment_opportunities (DB content, pages.content) =====
   Was a single-cell layout <table> (a legacy centering hack, not real
   tabular data) full of repeated <span style="font-size:14pt"> inline
   styling around every paragraph. */
.aac-employment__banner { display: block; max-width: 100%; height: auto; margin: 0 0 20px; border-radius: 8px; }
.aac-employment__title { margin: 0 0 12px; color: var(--color-brand); }
.aac-employment__intro { max-width: 720px; margin: 0 0 24px; color: var(--color-icon); font-size: 1.05em; line-height: 1.6; }
.aac-employment__subtitle { margin: 28px 0 14px; color: var(--color-brand); font-size: 1.15em; }
.aac-employment__methods { display: flex; flex-direction: column; gap: 16px; max-width: 720px; }
.aac-employment__method {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 16px 18px;
  background-color: var(--color-panel-bg);
  border: 1px solid var(--color-border);
  border-radius: 8px;
}
.aac-employment__method svg { flex: 0 0 auto; margin-top: 2px; color: var(--color-brand); }
.aac-employment__method strong { font-size: 1.02em; }
.aac-employment__method p { margin: 4px 0 0; color: var(--color-text-tertiary); }
.aac-employment__address {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  max-width: 400px;
  padding: 16px 18px;
  background-color: var(--color-panel-bg);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  line-height: 1.6;
}
.aac-employment__address svg { flex: 0 0 auto; margin-top: 2px; color: var(--color-brand); }

/* ===== page/history (DB content, pages.content) =====
   Was a single-cell layout <table> (a legacy centering hack) holding
   the whole narrative in deeply nested <span style="font-size:12pt/
   14pt"> runs, a fixed-width photo+caption pair separated by bare
   <br>s, a second nested 2-column table for the intercom photo/story
   pairing, and a third table used purely as an image grid via empty
   width:20px/height:20px spacer cells. */
.aac-history__banner { display: block; max-width: 100%; height: auto; margin: 0 0 20px; border-radius: 8px; }
.aac-history__title { margin: 0 0 16px; color: var(--color-brand); }
.aac-history__text { max-width: 760px; margin: 0 0 18px; color: var(--color-text-secondary); font-size: 1.05em; line-height: 1.65; }
.aac-history__figure { margin: 24px auto; max-width: 433px; text-align: center; }
.aac-history__figure img { display: block; max-width: 100%; height: auto; margin: 0 auto; border-radius: 8px; }
.aac-history__figure figcaption { margin-top: 8px; color: var(--color-text-meta, #707070); font-size: .85em; }
.aac-history__row {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-start;
  max-width: 760px;
  margin: 0 0 18px;
}
.aac-history__row img { max-width: 100%; height: auto; border-radius: 8px; }
.aac-history__row p { margin: 0; color: var(--color-text-secondary); font-size: 1.05em; line-height: 1.65; }
@media (min-width: 650px) {
  .aac-history__row { flex-direction: row; gap: 24px; }
  /* Sized by height, not width -- at a fixed 300px-wide flex-basis the
     photo's own aspect ratio made it render much taller than its
     four-line paragraph, leaving a tall gap of empty space under the
     text. Capping height instead (width:auto keeps the image's real
     aspect ratio, so nothing gets cropped or distorted) brings it
     down close to the text block's own height. */
  .aac-history__row img { flex: 0 0 auto; max-width: 300px; max-height: 120px; width: auto; }
}
.aac-history__subtitle { margin: 32px 0 16px; color: var(--color-brand); }
.aac-history__gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  max-width: 900px;
}
@media (min-width: 650px) {
  .aac-history__gallery { grid-template-columns: repeat(3, 1fr); gap: 20px; }
}
.aac-history__gallery img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid var(--color-border);
  border-radius: 8px;
}

/* ===== page/intercom_examples (DB content, pages.content) ===== */
.aac-intercomex__title { margin: 16px 0 16px; color: var(--color-brand); }
.aac-intercomex__text { max-width: 800px; color: var(--color-text-secondary); font-size: 1.05em; line-height: 1.65; margin: 0 0 16px; }
.aac-intercomex__photo { margin: 24px 0; max-width: 900px; }
.aac-intercomex__photo img { width: 100%; height: auto; border-radius: 8px; }
.aac-intercomex__subtitle { margin: 32px 0 16px; color: var(--color-brand); }
.aac-intercomex__diagrams { margin: 0 0 16px; padding-left: 20px; }
.aac-intercomex__diagrams li { margin-bottom: 8px; line-height: 1.5; }
.aac-intercomex__matrix { margin: 16px 0; max-width: 620px; }
.aac-intercomex__matrix img { max-width: 100%; height: auto; border-radius: 8px; }

/* ===== page/buying_aviation_usa, page/buying_aviation_intl (DB content, pages.content) ===== */
.aac-buyaviation__title { margin: 16px 0 16px; color: var(--color-brand); }
.aac-buyaviation__notice {
  max-width: 800px;
  margin: 0 0 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  font-size: 1.05em;
  line-height: 1.6;
}
.aac-buyaviation__subtitle { margin: 8px 0 20px; color: var(--color-brand); }
.aac-buyaviation__dealer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  margin: 0 0 32px;
  text-align: center;
}
.aac-buyaviation__logo { flex: 0 0 auto; }
.aac-buyaviation__logo img { max-width: 260px; width: 100%; height: auto; }
.aac-buyaviation__logo img + img { margin-top: 12px; }
.aac-buyaviation__info strong { display: block; font-size: 1.1em; margin-bottom: 6px; }
.aac-buyaviation__info p { margin: 0; color: var(--color-icon); line-height: 1.6; }
@media (min-width: 600px) {
  .aac-buyaviation__dealer { flex-direction: row; align-items: center; text-align: left; gap: 40px; }
  .aac-buyaviation__logo { width: 300px; }
  .aac-buyaviation__logo img { max-width: 100%; }
}
.aac-buyaviation__disclaimer { margin-top: 8px; padding-top: 20px; border-top: 1px solid var(--color-border); }
.aac-buyaviation__disclaimer p { font-size: .85em; color: var(--color-text-meta, #707070); margin: 0 0 10px; }

/* ===== page/intercominfo (DB content, pages.content) ===== */
.aac-intercominfo__title { margin: 16px 0 16px; color: var(--color-brand); }
.aac-intercominfo__text { max-width: 800px; margin: 0 0 16px; color: var(--color-text-secondary); font-size: 1.05em; line-height: 1.65; }
.aac-intercominfo__brochure { margin: 24px 0; }
.aac-intercominfo__brochure img { max-width: 358px; width: 100%; height: auto; }
.aac-intercominfo__subtitle { margin: 32px 0 16px; color: var(--color-brand); }
.aac-intercominfo__list { margin: 0 0 16px; padding-left: 20px; }
.aac-intercominfo__list li { margin-bottom: 8px; line-height: 1.5; }

/* ===== admin/index.php (internal, IP+auth-gated dashboard) =====
   Replaces the old third-party "tabber" widget (one category visible
   at a time, no search) with a single scannable page: a sticky category
   index down the side, every tool listed underneath its group, and a
   client-side filter over all of them. An admin who knows the tool name
   should never have to know which of six categories it lives in. */
.aac-admin { max-width: 1040px; }

.aac-admin__alert {
  display: block;
  margin: 0 0 20px;
  padding: 12px 16px;
  background-color: var(--color-error-bg);
  border: 1px solid var(--color-error-border);
  border-radius: 8px;
  color: var(--color-error-text);
  text-decoration: none;
}
.aac-admin__alert:hover { border-color: var(--color-brand); }
.aac-admin__alert strong { color: var(--color-brand); font-size: 1.1em; }

.aac-admin__search { margin: 0 0 24px; }
.aac-admin__search-label {
  display: block;
  margin: 0 0 6px;
  font-size: 0.85em;
  font-weight: bold;
  color: var(--color-text);
}
.aac-admin__search-input {
  box-sizing: border-box;
  width: 100%;
  padding: 10px 14px;
  font-size: 1em;
  font-family: inherit;
  color: var(--color-text);
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 8px;
}
.aac-admin__search-input:focus {
  outline: none;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(185, 0, 0, 0.15);
}
.aac-admin__search-input::placeholder { color: var(--color-placeholder-gray); }

.aac-admin__layout { display: block; }

.aac-admin__toc { display: none; }

.aac-admin__group { margin: 0 0 32px; }
.aac-admin__group:last-of-type { margin-bottom: 0; }
.aac-admin__group-title {
  margin: 0 0 12px;
  /* Top padding lines this heading's text up with the top TOC entry's text
     (.aac-admin__toc a below): the TOC is sticky 16px down plus its own
     6px link padding, while this heading otherwise sits flush with the
     content column's top -- without it, whichever group you jump to reads
     visibly higher than "Content Creation" in the menu beside it. */
  padding: 21px 0 8px;
  border-bottom: 1px solid var(--color-border);
  font-size: 1.15em;
  color: var(--color-brand);
}

.aac-admin__list { margin: 0; padding: 0; list-style: none; }
.aac-admin__item { border-bottom: 1px solid var(--color-divider); }
.aac-admin__item:last-child { border-bottom: none; }

.aac-admin__item-link {
  display: block;
  padding: 10px 8px;
  text-decoration: none;
  border-radius: 6px;
}
.aac-admin__item-link:hover,
.aac-admin__item-link:focus {
  background: var(--color-hover-tint);
}
.aac-admin__item-link:focus {
  outline: 2px solid var(--color-brand);
  outline-offset: -2px;
}
.aac-admin__item-label {
  display: block;
  color: var(--color-text);
  font-weight: bold;
}
.aac-admin__item-link:hover .aac-admin__item-label,
.aac-admin__item-link:focus .aac-admin__item-label { color: var(--color-brand); }
.aac-admin__item-desc {
  display: block;
  margin-top: 2px;
  color: var(--color-text-secondary);
  font-size: 0.9em;
}

.aac-admin__empty { color: var(--color-text); font-style: italic; }

@media (min-width: 768px) {
  .aac-admin__layout {
    display: flex;
    align-items: flex-start;
    gap: 40px;
  }

  .aac-admin__toc {
    display: block;
    flex: 0 0 200px;
    position: sticky;
    top: 16px;
  }
  .aac-admin__toc ul { margin: 0; padding: 0; list-style: none; }
  .aac-admin__toc li { margin: 0 0 2px; }
  .aac-admin__toc a {
    display: block;
    padding: 6px 10px;
    border-radius: 6px;
    color: var(--color-text);
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9em;
    border-left: 2px solid transparent;
  }
  .aac-admin__toc a:hover { color: var(--color-brand); }
  .aac-admin__toc a.is-active {
    color: var(--color-brand);
    border-left-color: var(--color-brand);
    background: var(--color-hover-tint);
  }

  .aac-admin__content {
    flex: 1 1 auto;
    min-width: 0;
    /* The scrollspy in admin/index.php lights up a TOC entry once its
       section's heading has scrolled within OFFSET px of the viewport top.
       Without room to scroll past it, a short last section (e.g. Site
       Configuration, one item) can sit at the bottom of the page without
       ever reaching that point -- the page runs out of scroll room first,
       so its TOC entry never highlights. Scales with viewport height so
       it's enough room on any screen, not just the one this was tuned on. */
    padding-bottom: 60vh;
  }
}

/* ===== phpMyEdit (vendor CRUD grid used across most admin/*.php pages) =====
   Replaces the ~2005-era inline <style> block (heavy #004d9c table
   borders, #add8e6 header, browser-default submit buttons, blurry 15x16
   raster action icons) that used to be copy-pasted into every page that
   calls `new phpMyEdit($opts)`. phpMyEdit.class.php only ever emits
   `pme-*` classes (see getCSSclass() -- prefix "pme", then the element
   name, an optional page-type suffix, and a 0/1 zebra-stripe divider),
   so one shared stylesheet covers every page; no page should carry its
   own copy of this block again. Kept intentionally quiet/table-like
   (hairlines, not card chrome) since this renders dense data grids, not
   the tool-directory list style used on admin/index.php. */
/* These grids are 8-15 columns of real data, and the sitewide 1200px
   content column (.aac-body) plus the .rounded_box width admin pages
   hard-code inline (width:1200px, or a PHP $w) squeezes them into a
   fraction of a wide monitor while the columns themselves wrap and
   scroll. Admin tools are not reading-width documents -- give them the
   window, less a margin, on any page that actually contains a grid.

   :has() so this stays a stylesheet change: the ~15 admin/*.php pages
   that render a grid are otherwise untouched, and one that stops using
   phpMyEdit goes back to the normal content column on its own. (Same
   selector support the pme-navigation rules below already rely on.)

   !important on .rounded_box because those page widths are INLINE
   styles, which nothing else can outrank. */
.aac-body:has(.pme-main) { max-width: none; }
.aac-body:has(.pme-main) .rounded_box {
  width: auto !important;
  max-width: none;
}
/* menu.css pins .rounded_content to a flat 30px side margin. Scale it
   instead, so the margin is a comfortable gutter on a wide screen and
   doesn't eat a sixth of a phone's width. */
.aac-body:has(.pme-main) .rounded_content { margin: 0 clamp(8px, 1.5vw, 28px); }

.pme-main {
  width: 100%;
  border-collapse: collapse;
  background: #ffffff;
  border: 1px solid var(--color-border);
  font-family: var(--font-sans);
  font-size: 0.95em;
}
.pme-main th,
.pme-main td { padding: 8px 10px; text-align: left; vertical-align: middle; }

/* Header row */
.pme-header {
  background: var(--color-tile-bg);
  border-bottom: 3px solid var(--color-brand);
}
th.pme-header { color: #ffffff; font-weight: 600; white-space: nowrap; }
a.pme-header {
  color: #ffffff;
  text-decoration: none;
  border-bottom: 1px dotted rgba(255, 255, 255, 0.5);
}
a.pme-header:hover { border-bottom-style: solid; }
input.pme-search {
  padding: 5px 12px;
  font-size: 0.9em;
  font-family: inherit;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 5px;
  cursor: pointer;
}
input.pme-search:hover { background: rgba(255, 255, 255, 0.28); }

/* Active-sort / filter summary strip */
tr.pme-sortinfo { background: var(--color-hover-tint); }
td.pme-sortinfo {
  padding: 6px 10px;
  color: var(--color-link-muted-aa);
  font-size: 0.85em;
  border-bottom: 1px solid var(--color-border);
}
a.pme-sortinfo { color: var(--color-brand); text-decoration: none; font-weight: 600; }
a.pme-sortinfo:hover { text-decoration: underline; }

/* Data rows -- 0/1 is phpMyEdit's own zebra-stripe divider, not a
   semantic state; keep the stripe subtle rather than the old flat
   #ddd/#eee blocks. */
tr.pme-row-0, tr.pme-row-1 { border-bottom: 1px solid var(--color-divider); }
tr.pme-row-0:hover, tr.pme-row-1:hover { background: #e9d2c2; }
td.pme-cell-0, td.pme-cell-1,
td.pme-key-0, td.pme-key-1,
td.pme-value-0, td.pme-value-1,
td.pme-navigation-0, td.pme-navigation-1,
td.pme-help-0, td.pme-help-1 {
  border-bottom: 1px solid var(--color-divider);
  color: var(--color-text);
}
td.pme-key-0, td.pme-key-1 {
  width: 1%;
  white-space: nowrap;
  font-weight: 600;
  color: var(--color-link-muted-aa);
  background: #fafafa;
}
td.pme-help-0, td.pme-help-1 { color: var(--color-placeholder-gray); font-size: 0.85em; }
td.pme-filter { background: var(--color-hover-tint); }

/* "Name" column emphasis in list view. phpMyEdit has no per-field class of
   its own -- getCSSclass() only ever emits the zebra-stripe index (see
   pme-cell-0/1 above) -- so the field opts in with 'css' => array('postfix'
   => 'name') (feedback.php, pages.php, products.php, etc.), which appends
   "-name" to that cell's class. Selecting on the suffix, not a fixed class
   list, is what lets one rule cover every page that opts in. */
table.pme-main td[class$="-name"] { font-weight: 700; font-size: 1.05em; color: var(--color-text); }

/* Row action icons (view/change/copy/delete) -- authored as single-
   stroke SVG masks so they stay crisp at any zoom, instead of the
   vendor's blurry 15x16 raster PNGs. :has() lets one rule target the
   link by which icon image it wraps, since the surrounding href is
   record-specific and unmatchable by itself. */
/* phpMyEdit reuses the "pme-navigation-0/1" class for two structurally
   different cells in the same row -- the icon-actions cell AND, in
   tables with a selectable key column, a second cell holding just the
   row's radio button -- so the selector must single out the one that
   actually holds the icon links via :has(), never the bare class.
   Grid-ifying both (an earlier version of this rule did) decoupled the
   radio cell from the table's column-tracking algorithm and pushed
   every column after it out of alignment with its header. */
.aac-body .pme-main td.pme-navigation-0:has(a[title]),
.aac-body .pme-main td.pme-navigation-1:has(a[title]) {
  /* !important, and ".aac-body .pme-main" doubled up for specificity:
     outranks both the site's own "@media (min-width:768px) .aac-body td
     { display:table-cell !important }" (restores real table layout for
     stacked-on-mobile DB content tables at desktop width) and this
     file's own mobile ".aac-body .pme-main td { display:table-cell
     !important }" (keeps the data grid's columns intact under a
     horizontal scrollbar on phones) -- either would otherwise force
     this cell right back out of grid layout into a single column. */
  display: grid !important;
  grid-template-columns: repeat(2, auto);
  gap: 2px;
  width: max-content !important;
}
td.pme-navigation-0 a, td.pme-navigation-1 a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 5px;
}
td.pme-navigation-0 a:hover, td.pme-navigation-1 a:hover { background: var(--color-hover-tint); }
td.pme-navigation-0 img, td.pme-navigation-1 img { display: none; }
td.pme-navigation-0 a::before, td.pme-navigation-1 a::before {
  content: '';
  display: block;
  width: 16px;
  height: 16px;
  background-color: var(--color-link-muted-aa);
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: 16px;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: 16px;
}
td.pme-navigation-0 a:hover::before, td.pme-navigation-1 a:hover::before { background-color: var(--color-brand); }
td.pme-navigation-0 a:has(img[src$="pme-view.png"])::before,
td.pme-navigation-1 a:has(img[src$="pme-view.png"])::before {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1.5 10S4.5 4 10 4s8.5 6 8.5 6-3 6-8.5 6-8.5-6-8.5-6Z'/%3E%3Ccircle cx='10' cy='10' r='2.4'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1.5 10S4.5 4 10 4s8.5 6 8.5 6-3 6-8.5 6-8.5-6-8.5-6Z'/%3E%3Ccircle cx='10' cy='10' r='2.4'/%3E%3C/svg%3E");
}
td.pme-navigation-0 a:has(img[src$="pme-change.png"])::before,
td.pme-navigation-1 a:has(img[src$="pme-change.png"])::before {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M13.4 3.6l3 3L6.5 16.5l-3.8.9.9-3.8L13.4 3.6Z'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M13.4 3.6l3 3L6.5 16.5l-3.8.9.9-3.8L13.4 3.6Z'/%3E%3C/svg%3E");
}
td.pme-navigation-0 a:has(img[src$="pme-copy.png"])::before,
td.pme-navigation-1 a:has(img[src$="pme-copy.png"])::before {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='7' y='7' width='10' height='10' rx='1.5'/%3E%3Cpath d='M13 7V4.5A1.5 1.5 0 0 0 11.5 3h-8A1.5 1.5 0 0 0 2 4.5v8A1.5 1.5 0 0 0 3.5 14H6'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='7' y='7' width='10' height='10' rx='1.5'/%3E%3Cpath d='M13 7V4.5A1.5 1.5 0 0 0 11.5 3h-8A1.5 1.5 0 0 0 2 4.5v8A1.5 1.5 0 0 0 3.5 14H6'/%3E%3C/svg%3E");
}
td.pme-navigation-0 a:has(img[src$="pme-delete.png"])::before,
td.pme-navigation-1 a:has(img[src$="pme-delete.png"])::before {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 5.5h13M8 5.5V3.8a.8.8 0 0 1 .8-.8h2.4a.8.8 0 0 1 .8.8v1.7M5.5 5.5 6.3 16a1 1 0 0 0 1 .9h5.4a1 1 0 0 0 1-.9l.8-10.5'/%3E%3Cpath d='M8.3 8.5v5M11.7 8.5v5'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 5.5h13M8 5.5V3.8a.8.8 0 0 1 .8-.8h2.4a.8.8 0 0 1 .8.8v1.7M5.5 5.5 6.3 16a1 1 0 0 0 1 .9h5.4a1 1 0 0 0 1-.9l.8-10.5'/%3E%3Cpath d='M8.3 8.5v5M11.7 8.5v5'/%3E%3C/svg%3E");
}
td.pme-navigation-0 a:has(img[src$="pme-delete.png"]):hover::before,
td.pme-navigation-1 a:has(img[src$="pme-delete.png"]):hover::before { background-color: #b90000; }

/* Add/change form fields */
input.pme-input-0, input.pme-input-1,
select.pme-input-0, select.pme-input-1,
textarea.pme-input-0, textarea.pme-input-1 {
  box-sizing: border-box;
  max-width: 100%;
  padding: 7px 10px;
  font-size: 1em;
  font-family: inherit;
  color: var(--color-text);
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 6px;
}
input.pme-input-0:focus, input.pme-input-1:focus,
select.pme-input-0:focus, select.pme-input-1:focus,
textarea.pme-input-0:focus, textarea.pme-input-1:focus {
  outline: none;
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px rgba(185, 0, 0, 0.15);
}
textarea.pme-input-0, textarea.pme-input-1 { resize: vertical; }

/* Navigation / pagination bar */
.pme-navigation { border: none; border-top: 1px solid var(--color-border); }
tr.pme-navigation { background: #fafafa; }
td.pme-buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 10px;
}
td.pme-message { padding: 10px; text-align: center; color: var(--color-text); }
td.pme-stats {
  padding: 10px;
  text-align: right;
  color: var(--color-link-muted-aa);
  font-size: 0.85em;
  white-space: nowrap;
}
hr.pme-hr { display: none; }

/* Buttons -- native <input type="submit">, styled to match the site's
   button language rather than the browser default gray bevel. */
.pme-main input[type="submit"], .pme-navigation input[type="submit"] {
  padding: 8px 16px;
  font-size: 0.9em;
  font-family: inherit;
  font-weight: 600;
  color: var(--color-text);
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.pme-main input[type="submit"]:hover,
.pme-navigation input[type="submit"]:hover { background: var(--color-hover-tint); border-color: var(--color-brand); }
.pme-main input[type="submit"]:disabled,
.pme-navigation input[type="submit"]:disabled {
  opacity: .45;
  cursor: not-allowed;
  background: #ffffff;
  border-color: var(--color-border);
}
.pme-main input.pme-save, .pme-navigation input.pme-save,
.pme-main input.pme-add, .pme-navigation input.pme-add,
.pme-main input.pme-goto, .pme-navigation input.pme-goto {
  color: #ffffff;
  background: var(--color-brand);
  border-color: var(--color-brand);
}
.pme-main input.pme-save:hover, .pme-navigation input.pme-save:hover,
.pme-main input.pme-add:hover, .pme-navigation input.pme-add:hover,
.pme-main input.pme-goto:hover, .pme-navigation input.pme-goto:hover {
  background: var(--color-brand-hover);
  border-color: var(--color-brand-hover);
}
.pme-main input.pme-delete, .pme-navigation input.pme-delete {
  color: var(--color-brand);
  border-color: rgba(185, 0, 0, 0.4);
}
.pme-main input.pme-delete:hover, .pme-navigation input.pme-delete:hover {
  background: var(--color-brand);
  border-color: var(--color-brand);
  color: #ffffff;
}
select.pme-goto {
  padding: 7px 10px;
  font-size: 0.9em;
  font-family: inherit;
  color: var(--color-text);
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 6px;
}

/* Back-to-dashboard button (phpMyEdit.class.php, display_list_table_buttons()
   / display_record_buttons()) -- built as a button, matching the size/shape
   of every real <input type="submit"> beside it, but in a color none of
   them use (every button here is red-brand or neutral gray), a small left
   margin standing in for the divider a real button can't have, so it reads
   immediately as "leave this tool" rather than one more grid action. */
a.pme-admin-link {
  display: inline-flex;
  align-items: center;
  margin-left: 6px;
  padding: 8px 16px;
  border: 1px solid var(--color-link-blue);
  border-radius: 6px;
  font-size: 0.9em;
  font-weight: 600;
  color: var(--color-link-blue);
  background: #eaf1fd;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .15s ease, color .15s ease;
}
a.pme-admin-link:hover { background: var(--color-link-blue); color: #ffffff; }

/* Render-time footer note (phpMyEdit.class.php, $opts['display']['time']) */
.pme-timing { margin: 8px 2px 0; color: var(--color-placeholder-gray); font-size: 0.8em; }

/* The grid (or an add/change form -- some fields set a wide fixed
   character count via HTML cols/size, e.g. pages_direct.php's raw-HTML
   textarea at cols=100, which a phone-width media query alone can't
   catch since a desktop monitor narrower than that textarea's rendered
   width hits the same overflow) can be wider than the viewport; scroll
   the table itself sideways at ANY width rather than letting it force
   the whole page to scroll horizontally, or letting the site's own
   ".aac-body table/td/th { display:block !important }" (written for
   wide DB-authored content tables elsewhere, and active below 768px)
   stack it into one field-per-row with no columns at all -- outrank
   that with the doubled-up ".aac-body .pme-main" selector, and keep
   table/table-row/table-cell so the grid itself is unaffected and only
   gains a horizontal scrollbar. The pagination/button toolbar
   (.pme-navigation) is deliberately left out of this: it's just a
   buttons-cell and a stats-cell, which the site's default mobile
   table-stacking already turns into two clean full-width blocks below
   768px -- forcing it back into a two-column table instead would
   squeeze the button cell into a narrow, badly-wrapped column. */
.aac-body .pme-main {
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
  /* width:100%, not max-content: the grid should use the room the page
     gives it (see the .aac-body:has(.pme-main) block above) instead of
     shrink-wrapping to its columns and leaving a wide monitor's right
     third empty. The scroll behaviour is unchanged -- min-width on the
     row group below is what overflows this box when the columns really
     do need more width than the window has. */
  width: 100%;
  height: auto;
}
/* min-width:max-content keeps the columns at their natural width and
   pushes the overflow into .pme-main's own horizontal scroll, rather
   than letting width:100% squeeze every column until the text wraps to
   one word per line. phpMyEdit emits no thead/tfoot, so this is the one
   implicit row group -- there is no second table to fall out of
   alignment with. */
.aac-body .pme-main thead, .aac-body .pme-main tbody {
  display: table;
  width: 100%;
  min-width: max-content;
}
.aac-body .pme-main tr { display: table-row; width: auto; height: auto; }
.aac-body .pme-main td, .aac-body .pme-main th {
  display: table-cell !important;
  width: auto !important;
  height: auto !important;
  margin-bottom: 0;
}
/* Individual wide fields (a raw-HTML textarea, redirects.php's 65em
   input override, etc.) still must not stretch past the scroll
   container's own natural size back out to the viewport. */
.aac-body .pme-main input, .aac-body .pme-main select, .aac-body .pme-main textarea {
  max-width: min(100%, 90vw);
}

@media (max-width: 767px) {
  .pme-main th, .pme-main td { font-size: 0.9em; }
  td.pme-buttons { justify-content: flex-start; }
}

/* ===== DB-authored responsive layout blocks (page/product content) =====
   Offered to editors from the "Insert Template" button in the WYSIWYG
   editor (admin/js.php) as a replacement for the table-based layouts
   (fixed pixel widths, a lone <tr><td> just to get a box) that make up
   most of the site's existing page/product content -- that pattern needs
   the blunt ".aac-body table { display:block }" stacking rule earlier in
   this file to become readable on a phone at all. Flexbox wraps on its
   own as the viewport narrows, with no table-specific CSS required, so
   content built from these classes needs no separate mobile handling. */
.aac-content-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 24px;
  margin: 16px 0;
}
.aac-content-row__media { flex: 0 1 300px; }
.aac-content-row__media img { display: block; max-width: 100%; height: auto; border-radius: 8px; }
/* Placeholder box the "Insert Template" content starts with, in place of
   a real photo -- an editor replaces it via Insert > Image and this rule
   no longer applies (it only targets the empty placeholder markup). */
.aac-content-row__media--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 160px;
  padding: 16px;
  border: 1px dashed var(--color-border);
  border-radius: 8px;
  background: #fafafa;
  color: #666666;  /* placeholder gray is 4.35:1 on #fafafa */
  font-size: 0.9em;
  text-align: center;
}
.aac-content-row__text { flex: 1 1 320px; min-width: 0; }
.aac-content-row--reverse { flex-direction: row-reverse; }
@media (max-width: 599px) {
  /* row (not column): flex-basis on .aac-content-row__media is a WIDTH
     budget (300px) -- under flex-direction:column that basis becomes a
     HEIGHT instead, reserving a tall empty box above/below the image.
     Reverting to row keeps the media item's flex-basis meaning "width"
     so it wraps onto its own line via flex-wrap exactly like the base
     (non-reversed) rows already do at this width. */
  .aac-content-row--reverse { flex-direction: row; }
}

/* page/faith1's intro: a small centered Cross & Bible icon above a
   standard photo-beside-copy .aac-content-row. Once the row wraps on a
   phone the photo drops onto its own line directly under the icon, so
   the two images stack -- icon centered, photo flush left -- reading as
   two false starts before the copy. Below the wrap point, collapse the
   content row's own box with display:contents so its media and text
   become items of this wrapper instead: the icon and the photo then sit
   side by side on one centered line, with the copy full-width beneath.
   Above the wrap point nothing here applies and the desktop layout
   (icon centered over the whole column) is untouched. */
@media (max-width: 599px) {
  .aac-faith-intro {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-evenly;
    gap: 16px;
  }
  .aac-faith-intro > .aac-content-row { display: contents; }
  /* Photo first, icon after it: the icon is the wrapper's first child so
     that it sits centered above the row on desktop, but at this width the
     pair reads better with the person on the left and the icon to its
     right. order (not a markup swap) keeps the desktop stacking intact. */
  .aac-faith-intro__icon { order: 2; flex: 0 0 auto; }
  /* Shrink-to-fit, overriding .aac-content-row__media's 300px flex-basis:
     that basis plus the icon exceeds a phone's width, so the pair would
     wrap back apart onto separate lines. Both images are small and fixed
     (139px and 75px wide), so their intrinsic size is what should decide
     the layout here. */
  .aac-faith-intro .aac-content-row__media { flex: 0 0 auto; }
  .aac-faith-intro .aac-content-row__text { order: 3; flex: 1 1 100%; }
}

.aac-content-cols {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 24px;
  margin: 16px 0;
}
.aac-content-cols > * { flex: 1 1 260px; min-width: 0; }

/* ===== page/access_tips (DB content, pages.content) ===== */
.aac-access-tips__title { margin: 0 0 20px; color: var(--color-brand); }
.aac-access-tips__discontinued { color: var(--color-placeholder-gray); font-weight: 400; font-size: .65em; }
.aac-access-tips__caption { margin: 10px 0 24px; color: var(--color-icon); font-size: .95em; line-height: 1.55; }
.aac-access-tips__caption:last-child { margin-bottom: 0; }
.aac-access-tips__links { margin: 16px 0 0; padding-left: 20px; }
.aac-access-tips__links li { margin-bottom: 8px; }

/* ===== page/1500training (DB content, pages.content) =====
   Replaces a single-column table of fixed-533px-wide videos/thumbnails
   (huge unused margin on anything wider than a phone) with a grid that
   actually uses the available width, and true aspect-ratio video
   embeds instead of a fixed pixel height. */
.aac-training__intro { max-width: 700px; margin: 0 auto 28px; text-align: center; }
.aac-training__intro h2 { margin-top: 0; color: var(--color-brand); }
.aac-training__intro p { margin: 0 0 10px; color: var(--color-icon); line-height: 1.55; }
.aac-training__intro p:last-child { margin-bottom: 0; }

.aac-training__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin: 0 0 44px;
}
.aac-training__grid--single { grid-template-columns: minmax(0, 700px); justify-content: center; }

/* Numbered step-by-step map grid (page location.php) -- a plain
   <ol> so the browser/AT supplies the step numbers instead of a
   hand-authored "01/02/03" label. Same auto-fit card-grid shape as
   .aac-training__grid, but image-on-top-of-caption instead of
   side-by-side (a wide 500x300 map next to one short sentence, via
   .aac-content-row, left a tall dead-space gap below the text). */
.aac-directions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin: 0 0 20px;
  padding-left: 0;
  list-style-position: inside;
}
.aac-directions-step {
  background: var(--color-panel-bg);
  border-radius: 8px;
  overflow: hidden;
}
.aac-directions-step img { display: block; width: 100%; height: auto; }
.aac-directions-step p { margin: 0; padding: 12px 14px; line-height: 1.5; }
.aac-directions-step::marker { color: var(--color-brand); font-weight: 700; }

/* Thumbnail card with a caption beneath it. .aac-training__thumb on its
   own is a bare linked image (the 1500training / gpu-review1 grids), but
   the product tutorial rows -- 2835A-B1 and 2870A-B1, converted from
   fixed-width <table> mosaics -- pair each thumbnail with a one-line
   description. Sits as a direct child of .aac-training__grid, which
   already auto-fits and wraps. Not .aac-directions-grid: that one is an
   <ol> whose ::marker numbers each step, and these tutorials are an
   unordered set. */
.aac-training__card > .aac-training__thumb { margin-bottom: 10px; }
.aac-training__card > p { margin: 0; line-height: 1.45; }

.aac-training__video {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  overflow: hidden;
  background: #000000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .18);
}
.aac-training__video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.aac-training__thumb {
  display: block;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .18);
  transition: transform .15s ease, box-shadow .15s ease;
}
.aac-training__thumb:hover, .aac-training__thumb:focus-visible {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, .24);
}
.aac-training__thumb img { display: block; width: 100%; height: auto; }

/* Prev/next row on individual lesson pages (page/1500training-N) --
   caps at the same 700px measure as .aac-training__intro so it lines up
   under the single-video grid above it. */
.aac-training__nav { display: flex; justify-content: space-between; align-items: center; max-width: 700px; margin: 0 auto 28px; gap: 16px; }
.aac-training__nav-link { font-weight: 600; color: var(--color-brand); text-decoration: none; }
.aac-training__nav-link:hover, .aac-training__nav-link:focus-visible { text-decoration: underline; }
.aac-training__nav-link--next { margin-left: auto; }

/* ===== page/intercom_faq (DB content, pages.content) =====
   Replaces a single table cell holding a wall of Q&A text (deeply
   nested, redundant inline-styled <span>s, no way to scan 21 questions
   except reading straight through) with a native <details>/<summary>
   accordion -- keyboard- and screen-reader-accessible for free, no JS,
   and collapsed by default so the page is scannable at a glance. */
/* .aac-body prefixed for specificity: otherwise the sitewide
   ".aac-body div { max-width:100% }" safety rule above wins and this
   never applies at all. */
.aac-body .aac-faq { max-width: 600px; }
.aac-faq__title { margin: 0 0 24px; color: var(--color-brand); }
.aac-faq__section { margin: 0 0 36px; }
.aac-faq__section:last-child { margin-bottom: 0; }
.aac-faq__section-title {
  margin: 0 0 4px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--color-border);
  color: var(--color-text);
}
.aac-faq__item { border-bottom: 1px solid var(--color-divider); }
.aac-faq__q {
  position: relative;
  padding: 14px 32px 14px 4px;
  font-weight: 700;
  color: var(--color-text);
  cursor: pointer;
  list-style: none;
  border-radius: 6px;
}
.aac-faq__q::-webkit-details-marker { display: none; }
.aac-faq__q::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 8px;
  width: 10px;
  height: 10px;
  margin-top: -6px;
  border-right: 2px solid var(--color-brand);
  border-bottom: 2px solid var(--color-brand);
  transform: rotate(45deg);
  transition: transform .15s ease;
}
.aac-faq__item[open] > .aac-faq__q::after { transform: rotate(-135deg); margin-top: -2px; }
.aac-faq__q:hover, .aac-faq__q:focus-visible { color: var(--color-brand); background: var(--color-hover-tint); }
.aac-faq__q:focus-visible { outline: 2px solid var(--color-brand); outline-offset: -2px; }
.aac-faq__a { padding: 0 4px 18px; color: var(--color-text-secondary); line-height: 1.6; }
.aac-faq__a p { margin: 0 0 12px; }
.aac-faq__a p:last-child { margin-bottom: 0; }

/* ===== Generic legacy-page modernization components (traffic-priority
   batch of /page/* content that was still raw table markup). Reused
   across many pages rather than a bespoke class per page, since the
   underlying shapes repeat: a plain-text/list page, a distributor or
   OEM-partner card list, and a grid of product/model download cards. ===== */

/* Plain heading + paragraphs + lists (no imagery, no repeating cards) --
   capped at a comfortable reading measure like .aac-faq. .aac-body
   prefixed for specificity over the sitewide ".aac-body div { max-width:
   100% }" safety rule (see .aac-faq above for the same issue). */
.aac-body .aac-page-copy { max-width: 720px; }
.aac-page-copy p { margin: 0 0 14px; line-height: 1.6; }
.aac-page-copy p:last-child { margin-bottom: 0; }
.aac-page-copy ul { margin: 0 0 14px; padding-left: 22px; line-height: 1.6; }
.aac-page-copy h3 { margin: 28px 0 10px; color: var(--color-brand); }

/* Row of partner/association logos inside .aac-page-copy -- page/associations. */
.aac-logo-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 28px; margin: 0 0 20px; }
.aac-logo-row img { max-width: 100%; height: auto; }

/* N-up icon/image + heading + paragraph cards, auto-wrapping -- used by
   page/rollouts-ascentic for both its top service-line row and its
   "What We Do" process-step row. Not scoped to .aac-page-copy's 720px
   reading measure since it's meant for a full-width landing section. */
.aac-feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 28px; margin: 0 0 24px; text-align: center; }
.aac-feature-card img { max-width: 100%; height: auto; }
.aac-feature-card h3 { margin: 14px 0 8px; font-size: 1.05em; }
.aac-feature-card p { margin: 0; line-height: 1.55; }

/* Product specification columns: N side-by-side blocks, each a section
   heading plus a bullet list of specs. Replaces the DB-authored
   fixed-width <table> spec layouts (e.g. the "width: 700px" 2-column
   tables shared across the 1500/1580 intercom products), which pinned a
   desktop-only column width and carried inline arial/font-size:small
   spans on every list item. auto-fit gives 2-up on desktop and 1-up on a
   phone from the same markup, with no media query and without relying on
   the sitewide table-stacking rule to do it.
   Left-aligned, so distinct from .aac-feature-grid above (centered
   icon/heading/paragraph cards). */
.aac-spec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 4px 32px;
  margin: 16px 0 24px;
}
.aac-spec-block > h4 { margin: 0 0 6px; font-size: 1em; }
.aac-spec-block > ul { margin: 0 0 16px; padding-left: 20px; line-height: 1.5; }
.aac-spec-block > ul > li { margin-bottom: 4px; }

/* Distributor / OEM-partner card list: a logo beside a name+address
   block, repeated. Used by page/distributors, page/online_resellers,
   and the OEM-partner section of page/buy_intercom_usa. */
.aac-distributor-list { list-style: none; margin: 20px 0; padding: 0; }
.aac-distributor-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--color-divider);
}
.aac-distributor-list > li:first-child .aac-distributor-card { padding-top: 0; }
.aac-distributor-list > li:last-child .aac-distributor-card { border-bottom: 0; padding-bottom: 0; }
.aac-distributor-card__logo { flex: 0 0 auto; width: 180px; text-align: center; }
.aac-distributor-card__logo img { max-width: 100%; height: auto; }
.aac-distributor-card__info { flex: 1 1 260px; min-width: 0; line-height: 1.5; color: var(--color-text-secondary); }
.aac-distributor-card__info a { word-break: break-word; }

/* Model/product download-card grid: image, model name, one or more
   download links (usually [down] shortcodes) per card. Used by
   page/gpu-manuals. */
.aac-model-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 28px 20px;
  margin: 20px 0;
  text-align: center;
}
.aac-model-card__img { display: block; max-width: 100%; height: auto; margin: 0 auto 10px; border-radius: 8px; }
.aac-model-card__name { display: block; margin-bottom: 8px; }
.aac-model-card__downloads { display: block; }
.aac-model-card__downloads a { display: block; margin-top: 4px; }

/* Manual-category grid: a colored header band over a list of [down]
   downloads, repeated per category. Used by page/product_manuals. */
.aac-manual-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px 28px;
  margin: 20px 0;
}
.aac-manual-card__header {
  margin: 0 0 12px;
  padding: 10px 14px;
  background: var(--color-brand);
  color: #ffffff;
  font-size: 1em;
}
.aac-manual-card__list .aac-download-item__link { display: block; margin: 4px 0; }
.aac-manual-card__more { display: block; margin-top: 8px; }

/* Product specification rows: name/link, one or more product photos, and a
   spec list, repeated per model. Used by page/psb-support. */
.aac-spec-list { list-style: none; margin: 20px 0; padding: 0; }
.aac-spec-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  padding: 20px 0;
  border-bottom: 1px solid var(--color-divider);
}
.aac-spec-list > li:first-child .aac-spec-row { padding-top: 0; }
.aac-spec-list > li:last-child .aac-spec-row { border-bottom: 0; padding-bottom: 0; }
.aac-spec-row__name { flex: 0 0 160px; font-weight: 700; line-height: 1.4; }
.aac-spec-row__imgs { flex: 0 0 auto; display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.aac-spec-row__imgs img { max-width: 100%; height: auto; border-radius: 8px; }
.aac-spec-row__specs { flex: 1 1 240px; min-width: 0; margin: 0; padding-left: 20px; line-height: 1.5; color: var(--color-text-secondary); }

/* Numbered sequential install-step list, each step full-width with its own
   photo. Used by page/cust-assy. */
.aac-steps { list-style: none; counter-reset: aac-step; margin: 20px 0; padding: 0; max-width: 900px; }
.aac-step {
  counter-increment: aac-step;
  position: relative;
  margin: 0 0 20px;
  padding: 16px 20px 20px 56px;
  border: 2px solid #d2dee4;
  border-radius: 4px;
}
.aac-step::before {
  content: counter(aac-step);
  position: absolute;
  top: 16px;
  left: 16px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--color-brand);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.9em;
  line-height: 26px;
  text-align: center;
}
.aac-step p { margin: 0 0 12px; line-height: 1.5; }
.aac-step img { display: block; max-width: 100%; height: auto; margin: 0 auto; border-radius: 8px; }

/* Prev/title/next header for a series of wide wiring-diagram pages (e.g.
   page_wide/mht2018w1..w4f), followed by the full diagram image. */
.aac-wall-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  margin: 0 0 20px;
}
.aac-wall-nav__side { flex: 0 0 auto; width: 140px; }
.aac-wall-nav__side img { display: block; max-width: 100%; height: auto; border-radius: 8px; }
.aac-wall-nav__main { flex: 1 1 auto; text-align: center; }
.aac-wall-nav__main h2 { margin: 0 0 8px; }
.aac-wall-nav__main p { margin: 0; line-height: 1.6; color: var(--color-text-secondary); }
.aac-wall-nav__diagram { display: block; max-width: 100%; height: auto; margin: 0 auto; }
@media (max-width: 700px) {
  .aac-wall-nav { flex-wrap: wrap; justify-content: center; }
  .aac-wall-nav__side { width: 110px; order: 2; }
  .aac-wall-nav__main { flex: 1 1 100%; order: 1; }
}

/* Dark feature-callout panel: a content-row variant with a colored
   background and light text, for landing-page emphasis sections. */
.aac-highlight-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 24px;
  margin: 24px 0;
  padding: 28px;
  background: #667074;  /* was #707a7e: 4.4:1 with white text */
  border-radius: 6px;
  color: #ffffff;
}
.aac-highlight-row__media { flex: 1 1 280px; }
.aac-highlight-row__media img { display: block; max-width: 100%; height: auto; margin: 0 auto; border-radius: 8px; }
.aac-highlight-row__text { flex: 1 1 280px; }
.aac-highlight-row__text h2 { margin: 0 0 12px; color: #ffffff; }
.aac-highlight-row__text ul { margin: 0; padding-left: 22px; line-height: 1.7; }
.aac-highlight-row__text a { color: #ffffff; }

/* ===== Mobile readability and touch targets =====
   Everything size-related here is inside max-width: 1040px -- the
   hamburger-header cutoff -- so the desktop layout is untouched. The
   few rules outside it only give new mobile-only elements (the homepage
   banner caption, the downloads summary, the video poster) their
   desktop-neutral default.

   Audited 2026-09-15 at 390px: the 13px body font (newsite.css) and the
   em-sized labels under it put hundreds of text runs below 12px, and
   inline-sized links (download rows, blog tags, glossary letters) were
   15-20px tall -- under the 24px minimum of WCAG 2.5.8. */

/* Homepage banner: the anchor was inline, so its hit box was one 15px
   line box rather than the image. Block changes nothing visually. */
.aac-hero > a { display: block; }
.aac-hero__caption { display: none; }

/* Downloads groups are <details open> (downloadlist.php). On desktop the
   summary is just the heading it replaced -- no marker, not clickable. */
.aac-download-group__summary { display: block; list-style: none; }
.aac-download-group__summary::-webkit-details-marker { display: none; }
.aac-download-group__count { display: none; }
@media (min-width: 1041px) {
  .aac-download-group__summary { pointer-events: none; }
}

/* Click-to-play YouTube poster (include.php $embedify, yt-facade.js).
   Same box as the iframe[src*="youtube"] rule it stands in for. */
.aac-yt {
  position: relative;
  display: block;
  width: 100%;
  max-width: 845px;
  aspect-ratio: 16 / 9;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  overflow: hidden;
  background: #000000 center / cover no-repeat;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .18);
  cursor: pointer;
}
.aac-training__video .aac-yt { position: absolute; inset: 0; max-width: none; height: 100%; box-shadow: none; }
.aac-yt__play {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 68px;
  height: 48px;
  border-radius: 12px;
  background-color: rgba(33, 33, 33, .85);
  transform: translate(-50%, -50%);
  transition: background-color .15s ease;
}
.aac-yt__play::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  border-style: solid;
  border-width: 11px 0 11px 19px;
  border-color: transparent transparent transparent #ffffff;
  transform: translate(-35%, -50%);
}
.aac-yt:hover .aac-yt__play,
.aac-yt:focus-visible .aac-yt__play { background-color: var(--color-brand); }
@media (prefers-reduced-motion: reduce) {
  .aac-yt__play { transition: none; }
}

@media (max-width: 1040px) {
  body { font-size: 15px; }

  /* Micro-labels that were ~10px once scaled off the 13px body. */
  .aac-dlfilter__row label { font-size: .8em; }
  /* px, not em: inside a product tab the policy table sits in a smaller
     inherited size, so .8em still came out at ~10px there. */
  .aac-policy__label,
  .aac-footer__phone-label { font-size: 12px; }
  .aac-blog-card__date { font-size: 13px; }
  .aac-search-result__meta { font-size: 13px; }

  .aac-hero__caption {
    display: block;
    margin: 14px 4px 0;
    color: var(--color-text-tertiary);
    line-height: 1.55;
    text-align: left;
  }

  .aac-blog-tag {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 12px;
    font-size: 12px;
  }
  .aac-blog-card__cta { display: inline-flex; align-items: center; min-height: 44px; }
  /* Result URLs are one unbroken string -- at 15px the longest ran 87px
     past a 390px screen. Break anywhere rather than scroll the page. */
  .aac-search-result__url { display: inline-block; max-width: 100%; padding-block: 6px; overflow-wrap: anywhere; }

  .aac-glossary__nav { gap: 4px 6px; padding: 8px 10px; }
  .aac-glossary__nav a,
  .aac-glossary__nav-current {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 8px;
  }

  /* Download rows: the link is the whole row's height, not one line. */
  .aac-download-item { padding: 2px 0; }
  .aac-download-item__link { min-height: 40px; }

  /* Collapsed groups read as a list of models: tighter rhythm, a file
     count and a chevron on the summary row. */
  .aac-download-results { gap: 0; }
  .aac-download-group,
  .aac-download-group:not(:first-child) { margin-top: 0; padding-top: 0; }
  .aac-download-group:not(:first-child) { border-top: 1px solid var(--color-border); }
  .aac-download-group__summary {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 52px;
    cursor: pointer;
  }
  .aac-download-group__summary .aac-download-group__title { flex: 1 1 auto; margin: 0; }
  .aac-download-group__count { display: block; color: var(--color-text-tertiary); font-size: .85em; white-space: nowrap; }
  .aac-download-group__summary::after {
    content: "";
    flex: 0 0 auto;
    width: 8px;
    height: 8px;
    margin: 0 6px 4px 0;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
  }
  /* A little air between collapsed rows so adjacent models read as
     separate targets, not one continuous list. */
  .aac-download-group:not([open]) { padding-block: 5px; }
  details[open] > .aac-download-group__summary { margin-bottom: 10px; }
  details[open] > .aac-download-group__summary::after { margin-bottom: -4px; transform: rotate(-135deg); }
  .aac-download-group[open] { padding-bottom: 16px; }
}
