/* AP Systems readability patch v9. Preserves the v8 visual language.
 * Text colors selected for readable light/dark surface contrasts.
 * No external dependencies. Loaded last on all pages.
 */

/* Color system for text on pale panels and white cards. */
body.ap8 {
  --readable-ink: #17392c;
  --readable-body: #3e5849;
  --readable-muted: #4e6858;
  --readable-green: #245e40;
  --readable-light: #e5f3e8;
}
body.ap8 .muted { color: #536a5c; }
body.ap8 .service-index,
body.ap8 .industry-eyebrow,
body.ap8 .v5-route-number { color: #3b6349; }
body.ap8 .v5-route-card:first-child .v5-route-number { color:#c2e7c6; }
body.ap8 .integration-art-caption { color: #385e4e; }
body.ap8 .ribbon-list span { color:#e5f2e7; }
body.ap8 .enterprise-ribbon .ribbon-inner > strong { color:#edf8ee; }
body.ap8 .enterprise-ribbon .ribbon-inner > p { color:#c6decf; }
body.ap8 .ap8-home-feature .ap8-eyebrow { color:#276a41; }
body.ap8 .ap8-home-feature-lead h2 em { color:#356843; }
body.ap8 .ap8-home-feature-lead p { color:#405f4d; }
body.ap8 .ap8-home-tile:not(:first-child) p { color:#4d6754; }
body.ap8 .ap8-agent-card p { color:#4a6251; }
body.ap8 .ap8-agent-tag { color:#2c6944; }
body.ap8 .ap8-section-label { color:#315f42; }
body.ap8 .ap8-section-head p,
body.ap8 .ap8-security p,
body.ap8 .ap8-feature-layout p { color:#3e5949; }
body.ap8 .ap8-count { color:#49634f; }
body.ap8 .ap8-start-panel-top>span { color:#286844; }
body.ap8 .ap8-start-panel-top p { color:#4e6656; }
body.ap8 .ap8-call-sub,
body.ap8 .ap8-call-foot { color:#496352; }
body.ap8 .ap8-filters button:not(.active) { color:#305c42; }
body.ap8 .ap8-home-tile:not(:first-child)>span { color:#286342; }
body.ap8 .sales-caption { color:#55695b; }
body.ap8 .contact-note span,
body.ap8 .form-method,
body.ap8 .field-hint { color:#4f6655; }
body.ap8 .ap8-language-label {color:#234c37;}

/* Correct light-on-dark surfaces that inherited generic light-theme labels. */
body.ap8 .ap8-cta .ap8-section-label,
body.ap8 .v5-footer-banner .v5-section-label,
body.ap8 .dark-statement .v5-section-label { color:#d0f2a4; }
body.ap8 .ap8-cta p,
body.ap8 .v5-footer-banner p { color:#cfe4d4; }
body.ap8 .ap8-home-tile:first-child strong {color:#f6fff5;}
body.ap8 .ap8-home-tile:first-child p {color:#d2e8d5;}
body.ap8 .ap8-home-tile:first-child>span {color:#d6ff9c;}
body.ap8 .v5-route-card:first-child .v5-route-bottom {color:#d2e5d5;}

/* Deliberately readable content even without IntersectionObserver or while scrolling fast.
 * Keep hover interactions, live demos and decorative animation, but never make body text opacity:0. */
body.ap8.ap6-ready .ap6-reveal:not(.ap6-visible),
body.ap8.ap6-ready .ap6-reveal,
body.ap8 .ap8-reveal {
  opacity:1!important;
  transform:none!important;
  transition:box-shadow .24s ease,border-color .24s ease,background-color .24s ease!important;
}

/* Accessible focus, selectable fields, placeholder copy and button states. */
body.ap8 input::placeholder,
body.ap8 textarea::placeholder {color:#627568;opacity:1;}
body.ap8 :is(a,button,select,input,textarea):focus-visible {
  outline:3px solid #418c58;
  outline-offset:3px;
}
body.ap8 .ap8-voice-hero :is(a,button):focus-visible,
body.ap8 .ap8-catalog-hero :is(a,button):focus-visible,
body.ap8 .ap8-cta :is(a,button):focus-visible {
  outline-color:#e0ff9c;
}
body.ap8 button:disabled {opacity:.75;}

/* Preserve white text on dark-colored choices, banners and panels. */
body.ap8 .ap8-demo-choice.active,
body.ap8 .ap8-btn-dark,
body.ap8 .ap8-btn-outline {color:#fff;}
body.ap8 .ap8-section .ap8-btn-dark {color:#fff;}

/* A small screen should never need to zoom to read body text. */
@media(max-width:600px) {
  body.ap8 .ap8-agent-card p,
  body.ap8 .ap8-demo-summary p {font-size:14px;line-height:1.65;}
  body.ap8 .ap8-hero-small {font-size:13px;}
  body.ap8 .ap8-start-panel-top p {font-size:14px;}
}
@media(prefers-reduced-motion:reduce) {
  body.ap8 .ap8-reveal,body.ap8 .ap6-reveal {animation:none!important;transition:none!important;opacity:1!important;transform:none!important;}
}
/* Final component-specific contrast fixes found in the rendered audit. */
body.ap8 .enterprise-ribbon .ribbon-list span {
  background:#e8f3e7;
  border-color:#cadfcb;
  color:#244e35;
}
body.ap8 .solution-row .overline-num {color:#2b6543;}
body.ap8 .v5-route-heading>p {color:#3f5d49;}
body.ap8 .sales-caption {color:#4b6052!important;}
body.ap8 .contact-shortcut p {color:#385341;}
body.ap8 .ap8-start-panel-top>span {color:#25643e;}
/* Inner-page audit: demo UI, integrations, project steps, resources, legal copy. */
body.ap8 .demo-screen-top { color:#365b43; }
body.ap8 .demo-screen-breadcrumb { color:#2b6842; }
body.ap8 .demo-record-head { color:#355f45; }
body.ap8 .demo-status { color:#295b3d; }
body.ap8 .demo-record-grid small {color:#496454;}
body.ap8 .demo-timeline div {color:#435f50;}
body.ap8 .demo-timeline .done {color:#1a5c38;}
body.ap8 .demo-screen-foot {color:#496452;}
body.ap8 .integrations-cell small {color:#476451;}
body.ap8 .disclosure {color:#4e6857;}
body.ap8 .smallprint {color:#4f6654;}
body.ap8 .roadmap-out strong {color:#2d6741;}
body.ap8 .roadmap-out p {color:#425b4b;}
body.ap8 .resources-card-list span {color:#2c6542;}
body.ap8 .demo-product-head small {color:#365c44;}
