/* ==========================================================================
   Plugpoint — accessibility widget.
   Self-contained replacement for the third-party tool that used to run here:
   that one could not reach its backend from a static mirror and injected its
   policy bar twice per page. This one is local, keyboard-operable, and stores
   the visitor's choices in localStorage so they survive navigation.
   ========================================================================== */

.pp-a11y-btn{
  position:fixed;
  inset-inline-start:1.6rem;
  bottom:1.6rem;
  z-index:99998;
  width:5.4rem;height:5.4rem;
  border-radius:50%;
  border:0;
  background:var(--pp-accent,#FF6A00);
  color:var(--pp-dark,#241A14);
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;
  box-shadow:0 4px 16px rgba(36,26,20,.28);
  transition:transform .15s ease, background .15s ease;
}
.pp-a11y-btn:hover{transform:scale(1.07);background:var(--pp-accent-hover,#FF8124);}
.pp-a11y-btn:focus-visible{outline:3px solid var(--pp-dark,#241A14);outline-offset:3px;}
.pp-a11y-btn svg{width:3rem;height:3rem;fill:currentColor;}

.pp-a11y-panel{
  position:fixed;
  inset-inline-start:1.6rem;
  bottom:7.8rem;
  z-index:99999;
  width:min(32rem,calc(100vw - 3.2rem));
  max-height:min(74vh,60rem);
  overflow-y:auto;
  background:#FFFFFF;
  color:#241A14;
  border-radius:1.6rem;
  box-shadow:0 12px 40px rgba(36,26,20,.28);
  padding:1.8rem;
  direction:rtl;
  font-family:inherit;
  display:none;
}
.pp-a11y-panel[data-open="true"]{display:block;}

.pp-a11y-panel h2{
  font-size:1.8rem;font-weight:700;margin:0 0 .4rem;color:#241A14;
}
.pp-a11y-panel .pp-a11y-sub{
  font-size:1.25rem;color:#7A6455;margin:0 0 1.4rem;line-height:1.5;
}
.pp-a11y-grid{display:grid;grid-template-columns:1fr 1fr;gap:.8rem;}
.pp-a11y-grid button{
  font-family:inherit;font-size:1.3rem;line-height:1.35;
  padding:1.1rem .8rem;
  border:2px solid #EADFD4;border-radius:1rem;
  background:#FFF8F2;color:#241A14;
  cursor:pointer;text-align:center;
  display:flex;flex-direction:column;align-items:center;gap:.5rem;
  transition:border-color .12s ease, background .12s ease;
}
.pp-a11y-grid button:hover{border-color:var(--pp-accent,#FF6A00);}
.pp-a11y-grid button:focus-visible{outline:3px solid var(--pp-accent,#FF6A00);outline-offset:2px;}
.pp-a11y-grid button[aria-pressed="true"]{
  border-color:var(--pp-accent,#FF6A00);
  background:rgba(255,106,0,.12);
  font-weight:700;
}
.pp-a11y-grid svg{width:2.2rem;height:2.2rem;stroke:var(--pp-accent-text,#C2410C);
  fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;}

.pp-a11y-foot{
  margin-top:1.4rem;padding-top:1.2rem;border-top:1px solid #EADFD4;
  display:flex;flex-direction:column;gap:.9rem;
}
.pp-a11y-foot a{font-size:1.3rem;color:var(--pp-accent-text,#C2410C);font-weight:600;}
.pp-a11y-reset{
  font-family:inherit;font-size:1.3rem;font-weight:700;
  padding:.9rem;border-radius:.8rem;border:0;cursor:pointer;
  background:#241A14;color:#FFFFFF;
}
.pp-a11y-reset:focus-visible{outline:3px solid var(--pp-accent,#FF6A00);outline-offset:2px;}

.pp-a11y-close{
  position:absolute;inset-inline-end:1.4rem;top:1.4rem;
  width:3rem;height:3rem;border:0;border-radius:50%;
  background:#F3E9DF;color:#241A14;cursor:pointer;font-size:1.8rem;line-height:1;
}
.pp-a11y-close:focus-visible{outline:3px solid var(--pp-accent,#FF6A00);outline-offset:2px;}

/* ==========================================================================
   The states the widget applies to the page.
   Everything is scoped to <html> so it survives any section markup.
   ========================================================================== */
html[data-pp-contrast="high"]{filter:contrast(1.32);}
html[data-pp-grayscale="on"]{filter:grayscale(1);}
html[data-pp-contrast="high"][data-pp-grayscale="on"]{filter:contrast(1.32) grayscale(1);}

html[data-pp-links="on"] a{
  text-decoration:underline !important;
  text-underline-offset:.25em;
  font-weight:700 !important;
}

html[data-pp-motion="off"] *,
html[data-pp-motion="off"] *::before,
html[data-pp-motion="off"] *::after{
  animation:none !important;
  transition:none !important;
  scroll-behavior:auto !important;
}

html[data-pp-font="readable"] body,
html[data-pp-font="readable"] body *:not(i):not(svg):not(path){
  font-family:Arial,"Segoe UI",sans-serif !important;
  letter-spacing:.02em !important;
}

/* text scaling — the theme sizes everything in rem off the root */
html[data-pp-text="1"]{font-size:68.75%;}   /* 110% of the theme's 62.5% base */
html[data-pp-text="2"]{font-size:75%;}      /* 120% */
html[data-pp-text="3"]{font-size:81.25%;}   /* 130% */

@media print{.pp-a11y-btn,.pp-a11y-panel{display:none !important;}}
