/* Agent Directory service pages (job 554a). */
.adir-snip { margin: 1.25rem 0; }
.adir-snip h3 { margin-bottom: .35rem; }
.adir-snip pre { overflow-x: auto; white-space: pre; max-width: 100%; }
.adir-copy { float: right; margin: 0 0 .35rem .5rem; padding: .2rem .7rem; font: inherit; font-size: .85rem; cursor: pointer; border: 1px solid currentColor; border-radius: 6px; background: transparent; color: inherit; }
.adir-copy:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
/* Compare view (job 554c). Desktop: one column per listing. <= 640 px: one card per listing, no horizontal page scroll. */
.adir-nm { font-style: italic; }
.adir-cmp p, .adir-cmp li, .adir-cmp .mono, .adir-cmp td, .adir-cmp th, .adir-cmp dd { overflow-wrap: anywhere; word-break: break-word; }
.adir-cmp-wide { overflow-x: auto; max-width: 100%; }
.adir-cmp-table { width: 100%; table-layout: fixed; border-collapse: collapse; }
.adir-cmp-table th, .adir-cmp-table td { vertical-align: top; text-align: left; padding: .45rem .5rem; border-bottom: 1px solid rgba(127, 127, 127, .3); }
.adir-cmp-table thead th:first-child { width: 10rem; }
.adir-cmp-cards { display: none; }
.adir-cmp-card { border: 1px solid rgba(127, 127, 127, .35); border-radius: 8px; padding: .75rem 1rem; margin: 0 0 1rem; max-width: 100%; box-sizing: border-box; }
.adir-cmp-card h3 { margin: 0 0 .25rem; }
.adir-cmp-card dl { margin: 0; }
.adir-cmp-card dt { font-weight: 600; margin-top: .55rem; }
.adir-cmp-card dd { margin: 0; }
.adir-cmp input[name="q"] { max-width: 100%; box-sizing: border-box; }
@media (max-width: 640px) {
  .adir-cmp-wide { display: none; }
  .adir-cmp-cards { display: block; }
}
/* 554b claim form: the listing-ids box (cols=50) must not widen the page on phones (554c QA: 411 px at 360/390). */
textarea[name="listing_ids"] { max-width: 100%; box-sizing: border-box; }
/* Job 550 polish: the service, claim and compare pages use section.section > .container, which style.css does not
   define, so they hugged the left edge at desktop width. Same box as .wrap on /agents (style.css: 1160px, 24px; 18px <= 640px). */
.section > .container { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
@media (max-width: 640px) { .section > .container { padding: 0 18px; } }
/* Weekly review (14 Nov 2026): /agents scrolled sideways on phones (scrollWidth 1628 at 390 px: the submit curl line, plus the
   verified-services table). Long code lines and wide tables now scroll inside their own box; the page itself does not.
   Desktop: tables keep their normal layout (the table rule is phone-width only). */
.prose-card pre { max-width: 100%; overflow-x: auto; }
@media (max-width: 640px) {
  .prose-card table:not(.adir-cmp-table) { display: block; max-width: 100%; overflow-x: auto; }
}
