/* ==========================================================================
   ShowPoppy display preferences
   --------------------------------------------------------------------------
   Hooks for the controls on /accessibility.html. Attributes are set on <html>
   by showpoppy-prefs.js before paint, so nothing flashes. Every page that
   loads this file honours whatever the visitor chose.
   ========================================================================== */

/* Text size. The stylesheets are pixel based, so scaling the whole body keeps
   layout proportions intact rather than breaking them the way a root font
   change would. */
html[data-sp-text="lg"] body{zoom:1.10}
html[data-sp-text="xl"] body{zoom:1.22}

/* Higher contrast. Darkens secondary text and strengthens hairlines. The
   brand palette is untouched. */
html[data-sp-contrast="on"]{
  --slate:#39465A;
  --slate-soft:#39465A;
  --line:#C6CED8;
  --line-soft:#D6DCE4;
}
html[data-sp-contrast="on"] .hero-fine,
html[data-sp-contrast="on"] .price-note,
html[data-sp-contrast="on"] .footer-legal,
html[data-sp-contrast="on"] .footer-col h2{color:#39465A}
html[data-sp-contrast="on"] .section--navy .lead,
html[data-sp-contrast="on"] .agents .closing,
html[data-sp-contrast="on"] .replies p,
html[data-sp-contrast="on"] .final p,
html[data-sp-contrast="on"] .final .reassure{color:#EDF2F7}

/* Reduced motion, chosen on the site rather than in the operating system. */
html[data-sp-motion="reduce"] *,
html[data-sp-motion="reduce"] *::before,
html[data-sp-motion="reduce"] *::after{
  animation-duration:.01ms !important;
  animation-iteration-count:1 !important;
  transition-duration:.01ms !important;
}
html[data-sp-motion="reduce"]{scroll-behavior:auto !important}

/* Always underline links, for people who do not reliably see color change. */
html[data-sp-links="underline"] a{text-decoration:underline;text-underline-offset:3px}
html[data-sp-links="underline"] a.btn,
html[data-sp-links="underline"] a.brand{text-decoration:none}
