/* Rivers Edge Boat Lift Services — Accessibility Widget (see js/accessibility-widget.js)
   Brand: navy #002554 · signal orange #f39a2b · Archivo / Figtree

   Bottom-right launcher. Below 1080px the fixed .call-bar (58px + safe area)
   owns the bottom edge, so the launcher and panel move up to clear it. */

.rb-a11y-launch {
  position: fixed;
  right: 26px;
  bottom: 24px;
  z-index: 2147483300;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid #f39a2b;
  background: #002554;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 8px 24px rgb(0 37 84 / 0.35);
  transition: background .15s ease, transform .15s ease;
}
.rb-a11y-launch:hover { background: #0b3a78; transform: translateY(-2px); }
.rb-a11y-launch:focus-visible { outline: 3px solid #f39a2b; outline-offset: 3px; }
.rb-a11y-launch svg { width: 28px; height: 28px; }

/* ── Panel ── */
.rb-a11y-panel {
  position: fixed;
  right: 18px;
  bottom: 86px;
  z-index: 2147483301;
  width: min(330px, calc(100vw - 36px));
  max-height: min(70vh, 620px);
  overflow-y: auto;
  background: #ffffff;
  color: #002554;
  border: 1px solid #d6dfea;
  border-top: 5px solid #f39a2b;
  border-radius: 6px;
  box-shadow: 0 24px 60px -16px rgb(0 37 84 / 0.45);
  padding: 18px;
  display: none;
  font-family: 'Figtree Variable', 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
.rb-a11y-panel.is-open { display: block; }

.rb-a11y-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.rb-a11y-head h2 {
  margin: 0; font-family: 'Archivo Variable', 'Archivo', 'Arial Narrow', sans-serif; font-style: italic;
  font-size: 1.3rem; font-weight: 800; color: #002554;
}
.rb-a11y-close {
  flex: none; width: 36px; height: 36px; border: 0; border-radius: 4px;
  background: #eef3f8; color: #002554; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.rb-a11y-close svg { width: 20px; height: 20px; }
.rb-a11y-close:hover { background: #d6dfea; }
.rb-a11y-intro { margin: 0 0 14px; font-size: .92rem; line-height: 1.5; color: #4a5a6e; }

/* ── Text-size stepper ── */
.rb-a11y-step {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  border: 1px solid #d6dfea; border-radius: 6px; padding: 10px 12px; margin-bottom: 12px; background: #fff;
}
.rb-a11y-step__label { font-weight: 700; font-size: .95rem; }
.rb-a11y-step__ctrls { display: inline-flex; align-items: center; gap: 8px; }
.rb-a11y-step__btn {
  width: 38px; height: 38px; border: 1.5px solid #c9ced2; border-radius: 4px;
  background: #fff; color: #002554; font-weight: 700; font-size: 1.1rem; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.rb-a11y-step__btn:hover { border-color: #d9821a; }
.rb-a11y-step__btn[disabled] { opacity: .4; cursor: default; }
.rb-a11y-step__val { min-width: 2.6em; text-align: center; font-weight: 700; font-size: .9rem; }

/* ── Toggle options ── */
.rb-a11y-opts { display: grid; gap: 8px; }
.rb-a11y-opt {
  display: flex; align-items: center; gap: 12px; width: 100%;
  border: 1px solid #d6dfea; border-radius: 6px; background: #fff; color: #002554;
  padding: 10px 12px; font: inherit; font-weight: 600; font-size: .98rem; text-align: left; cursor: pointer;
}
.rb-a11y-opt:hover { border-color: #d9821a; }
.rb-a11y-opt__icon {
  flex: none; width: 34px; height: 34px; border-radius: 4px; background: #eef3f8; color: #002554;
  display: inline-flex; align-items: center; justify-content: center;
}
.rb-a11y-opt__icon svg { width: 19px; height: 19px; }
.rb-a11y-opt__txt { flex: 1 1 auto; }
.rb-a11y-opt__state {
  flex: none; font-family: 'Archivo Variable', 'Archivo', 'Arial Narrow', sans-serif;
  font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #4a5a6e;
}
.rb-a11y-opt[aria-pressed="true"] { background: #002554; color: #fff; border-color: #002554; }
.rb-a11y-opt[aria-pressed="true"] .rb-a11y-opt__icon { background: #f39a2b; color: #002554; }
.rb-a11y-opt[aria-pressed="true"] .rb-a11y-opt__state { color: #f39a2b; }

.rb-a11y-panel button:focus-visible { outline: 3px solid #f39a2b; outline-offset: 2px; }

.rb-a11y-reset {
  margin-top: 14px; width: 100%; border: 1.5px solid #002554; border-radius: 4px;
  background: transparent; color: #002554; padding: 10px 14px;
  font-family: 'Archivo Variable', 'Archivo', 'Arial Narrow', sans-serif; font-weight: 700; font-size: .85rem;
  letter-spacing: .05em; text-transform: uppercase; cursor: pointer;
}
.rb-a11y-reset:hover { background: #eef3f8; }
.rb-a11y-foot { margin: 12px 0 0; font-size: .85rem; line-height: 1.5; color: #4a5a6e; text-align: center; }
.rb-a11y-foot a { color: #0b3a78; }

@media (max-width: 1079px) {
  .rb-a11y-launch { right: 14px; bottom: calc(72px + env(safe-area-inset-bottom)); width: 48px; height: 48px; }
  .rb-a11y-panel { bottom: calc(130px + env(safe-area-inset-bottom)); max-height: calc(100vh - 160px); }
}
@media (max-width: 767px) {
  .rb-a11y-panel { right: 10px; left: 10px; width: auto; }
}

/* =========================================================================
   Applied accessibility states (classes set on <html>)
   ========================================================================= */

/* Text size — the site's type is rem-based */
html.rb-fs-1 { font-size: 106.25%; }
html.rb-fs-2 { font-size: 112.5%; }
html.rb-fs-3 { font-size: 125%; }

/* High contrast — push the muted design tokens to full contrast on both the
   light and the ink sections, and outline cards and controls. */
html.rb-contrast {
  --stone: #000;
  --on-dark-muted: #fff;
  --tide: #0b2a38;
  --line: #002554;
  --paper: #fff;
  --sand: #fff;
}
html.rb-contrast a { text-decoration: underline !important; }
html.rb-contrast input,
html.rb-contrast select,
html.rb-contrast textarea { border: 2px solid #002554 !important; }
html.rb-contrast .card,
html.rb-contrast .svc,
html.rb-contrast .side-card { outline: 2px solid currentColor; }

/* Highlight links */
html.rb-links a {
  text-decoration: underline !important;
  text-decoration-thickness: 2px !important;
  text-underline-offset: 3px !important;
  outline: 2px dashed #f39a2b;
  outline-offset: 2px;
}

/* Readable font — a highly legible face with generous spacing */
html.rb-readable body,
html.rb-readable p,
html.rb-readable li,
html.rb-readable a,
html.rb-readable h1, html.rb-readable h2, html.rb-readable h3, html.rb-readable h4,
html.rb-readable button, html.rb-readable input, html.rb-readable textarea,
html.rb-readable select, html.rb-readable .lead {
  font-family: Verdana, Tahoma, 'Segoe UI', Arial, sans-serif !important;
  font-style: normal !important;
  letter-spacing: 0.02em !important;
  word-spacing: 0.08em !important;
}
html.rb-readable p, html.rb-readable li, html.rb-readable .lead { line-height: 1.85 !important; }

/* Reduce motion — stop animations, transitions, smooth scroll, and reveal effects */
html.rb-reduce-motion,
html.rb-reduce-motion *,
html.rb-reduce-motion *::before,
html.rb-reduce-motion *::after {
  animation: none !important;
  transition: none !important;
  scroll-behavior: auto !important;
}
html.rb-reduce-motion [data-reveal] { opacity: 1 !important; transform: none !important; }
