.accessibility-tools {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 100;
  display: grid;
  justify-items: end;
  max-width: calc(100vw - 2rem);
  font-size: 1rem;
}

.accessibility-trigger {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  max-width: 100%;
  min-height: 48px;
  padding: .55rem .9rem .55rem .6rem;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #261638;
  color: #fff;
  box-shadow: 0 5px 20px rgb(20 8 38 / 25%);
  font: inherit;
  font-weight: 850;
  cursor: pointer;
}

.accessibility-trigger:hover {
  background: #000;
}

.accessibility-trigger-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  color: #261638;
  font-size: .82rem;
  font-weight: 900;
  letter-spacing: -.05em;
}

.accessibility-panel {
  position: absolute;
  right: 0;
  bottom: calc(100% + .75rem);
  width: min(390px, calc(100vw - 2rem));
  max-height: min(680px, calc(100vh - 6rem));
  overflow-y: auto;
  padding: 1.15rem;
  border: 2px solid #261638;
  border-radius: 20px;
  background: #fff;
  color: #261638;
  box-shadow: 0 16px 45px rgb(20 8 38 / 28%);
}

.accessibility-panel[hidden] {
  display: none;
}

.accessibility-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.accessibility-kicker {
  margin: 0;
  color: #5c3a7d;
  font-size: .7rem;
  font-weight: 900;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.accessibility-panel h2 {
  margin: .25rem 0 0;
  color: #261638;
  font-size: 1.35rem;
  line-height: 1.15;
  letter-spacing: -.025em;
}

.accessibility-close {
  display: grid;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  place-items: center;
  padding: 0;
  border: 1px solid #bba8cd;
  border-radius: 50%;
  background: #f5f0f8;
  color: #261638;
  font: inherit;
  font-size: 1.55rem;
  line-height: 1;
  cursor: pointer;
}

.accessibility-intro {
  margin: .85rem 0 1rem;
  color: #51445f;
  font-size: .84rem;
  line-height: 1.5;
}

.accessibility-option-list {
  display: grid;
  gap: .55rem;
}

.accessibility-option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: .85rem;
  align-items: center;
  width: 100%;
  min-height: 62px;
  padding: .7rem .75rem;
  border: 2px solid #d2c5dd;
  border-radius: 13px;
  background: #fff;
  color: #261638;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.accessibility-option:hover {
  border-color: #6f3fb0;
  background: #f8f4fb;
}

.accessibility-option[aria-pressed="true"] {
  border-color: #4c2287;
  background: #f0e8f7;
}

.accessibility-option strong,
.accessibility-option small {
  display: block;
}

.accessibility-option strong {
  font-size: .9rem;
}

.accessibility-option small {
  margin-top: .2rem;
  color: #655970;
  font-size: .72rem;
  line-height: 1.35;
}

.accessibility-option-state {
  display: grid;
  min-width: 46px;
  min-height: 30px;
  place-items: center;
  padding: .25rem .5rem;
  border-radius: 999px;
  background: #e9e2ee;
  color: #4f4260;
  font-size: .7rem;
  font-weight: 900;
}

.accessibility-option[aria-pressed="true"] .accessibility-option-state {
  background: #4c2287;
  color: #fff;
}

.accessibility-reset {
  margin-top: .9rem;
  padding: .55rem .2rem;
  border: 0;
  border-radius: .3rem;
  background: transparent;
  color: #4c2287;
  font: inherit;
  font-size: .8rem;
  font-weight: 850;
  text-decoration: underline;
  text-underline-offset: .2em;
  cursor: pointer;
}

html[data-text-size="large"] {
  font-size: 120%;
}

html[data-text-size="large"] .header-inner {
  flex-wrap: wrap;
  gap: .75rem 1.25rem;
  padding-block: .65rem;
}

html[data-text-size="large"] .desktop-nav {
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: .6rem 1rem;
}

html[data-text-size="large"] :is(.attraction-heading, .card-footer, .results-heading, .reviews-heading-row) {
  flex-wrap: wrap;
}

html[data-text-spacing="wide"] body {
  letter-spacing: .025em;
  line-height: 1.65;
  word-spacing: .06em;
}

html[data-text-spacing="wide"] :is(h1, h2, h3, h4, .brand-name, .brand-lockup-words span, .brand-lockup-words strong) {
  letter-spacing: .01em;
  line-height: 1.2;
}

html[data-motion="reduced"] {
  scroll-behavior: auto;
}

html[data-motion="reduced"] *,
html[data-motion="reduced"] *::before,
html[data-motion="reduced"] *::after {
  scroll-behavior: auto !important;
  transition-duration: .01ms !important;
  animation-duration: .01ms !important;
  animation-iteration-count: 1 !important;
}

html[data-contrast="high"] {
  --ink: #000;
  --text: #000;
  --muted: #1b1b1b;
  --primary: #000;
  --primary-dark: #000;
  --violet: #000;
  --border: #000;
  --paper: #fff;
  --white: #fff;
  --accent: #000;
  --focus: #ffbf00;
}

html[data-contrast="high"] body {
  background: #fff;
  color: #000;
}

html[data-contrast="high"] body :where(h1, h2, h3, h4, p, li, label, legend, small, span) {
  color: inherit;
}

html[data-contrast="high"] :is(
  .site-header,
  .hero,
  .confidence-card,
  .brand-lockup,
  .search-form,
  .region-browser,
  .region-map-card,
  .region-status,
  .attraction-card,
  .attraction-media,
  .attraction-logo,
  .ticket-info,
  .attraction-body details,
  .pagination,
  .status-card,
  .method,
  .method-steps li,
  .contact-hero,
  .contact-form-card,
  .about-hero,
  .about-story-card,
  .about-founder-card,
  .about-value-card,
  .about-process-card,
  .country-directory-hero,
  .country-attraction-card,
  .detail-hero,
  .jarvis-status-card,
  .lift-availability-card,
  .unavailable-lift-list li,
  .no-lifts-listed,
  .detail-main-card,
  .review-contribute,
  .visitor-review,
  .review-summary,
  .review-loading,
  .review-empty,
  .review-load-error,
  .review-message,
  .signed-in-panel,
  .important-note,
  .carer-booking-guidance,
  .carer-overpayment-warning,
  .carer-evidence
) {
  border-color: #000 !important;
  background: #fff !important;
  background-image: none !important;
  color: #000 !important;
  box-shadow: none !important;
}

html[data-contrast="high"] .jarvis-status-reason {
  border: 2px solid #000;
  background: #fff;
  color: #000;
}

html[data-contrast="high"] .lift-availability-mark,
html[data-contrast="high"] :is(.unavailable-lift-list li span, .no-lifts-listed span) {
  border-color: #000 !important;
  background: #000 !important;
  color: #fff !important;
  box-shadow: none !important;
}

html[data-contrast="high"] :is(.jarvis-status-light, .jarvis-signal-lamp, .jarvis-key-light) {
  border-color: #000;
  box-shadow: none;
  filter: none;
}

html[data-contrast="high"] :is(
  .jarvis-status-light.is-green,
  .jarvis-status-light.is-red,
  .jarvis-signal-lamp.is-green,
  .jarvis-signal-lamp.is-red,
  .jarvis-key-light.is-green,
  .jarvis-key-light.is-red
) {
  color: #fff !important;
}

html[data-contrast="high"] :is(
  .jarvis-status-light.is-amber,
  .jarvis-signal-lamp.is-amber,
  .jarvis-key-light.is-amber
) {
  color: #000 !important;
}

html[data-contrast="high"] .hero::before,
html[data-contrast="high"] .hero::after {
  display: none;
}

html[data-contrast="high"] :is(.planning-card, .contact-aside, .about-cta, .founder-photo-placeholder, footer, .detail-ticket-card, .attraction-type) {
  border-color: #fff !important;
  background: #000 !important;
  background-image: none !important;
  color: #fff !important;
  box-shadow: none !important;
}

html[data-contrast="high"] :is(
  .button-primary,
  .search-form button,
  .filter.active,
  .region-filter.active,
  .page-button.active,
  .card-footer .card-detail-link,
  .country-switcher a[aria-current="page"],
  .ticket-icon,
  .carer-direct-button
) {
  border-color: #000 !important;
  background: #000 !important;
  color: #fff !important;
}

html[data-contrast="high"] :is(
  .button-outline,
  .button-gold,
  .filter,
  .region-filter,
  .page-button,
  .checked,
  .tag-list li,
  .detail-tags li,
  .detail-tags a,
  .detail-meta-row > span,
  .detail-meta-row > a,
  .detail-category-help,
  .country-switcher a,
  .country-tags li,
  .country-status,
  .place strong
) {
  border-color: #000 !important;
  background: #fff !important;
  color: #000 !important;
}

html[data-contrast="high"] :is(input, select, textarea) {
  border: 2px solid #000 !important;
  background: #fff !important;
  color: #000 !important;
}

html[data-contrast="high"] body a:not(.button):not(.brand):not(.accessibility-trigger) {
  text-decoration: underline !important;
  text-decoration-thickness: 2px !important;
  text-underline-offset: .18em;
}

html[data-contrast="high"] :is(button, a, input, select, textarea):focus-visible {
  outline: 4px solid #ffbf00 !important;
  outline-offset: 3px !important;
  box-shadow: 0 0 0 2px #000 !important;
}

html[data-contrast="high"] .map-region {
  fill: #fff;
  stroke: #000;
  stroke-width: 3;
}

html[data-contrast="high"] .map-region.has-results {
  fill: #000;
}

html[data-contrast="high"] .map-region.active {
  fill: #ffcf00;
  stroke: #000;
  stroke-width: 5;
}

html[data-contrast="high"] .accessibility-panel {
  border-color: #000;
  background: #fff;
  color: #000;
  box-shadow: none;
}

html[data-contrast="high"] :is(.accessibility-option, .accessibility-close) {
  border-color: #000;
  background: #fff;
  color: #000;
}

html[data-contrast="high"] .accessibility-option[aria-pressed="true"] {
  border-width: 3px;
  background: #ffcf00;
}

html[data-contrast="high"] .accessibility-option-state,
html[data-contrast="high"] .accessibility-option[aria-pressed="true"] .accessibility-option-state {
  background: #000;
  color: #fff;
}

@media (max-width: 640px) {
  .accessibility-tools {
    right: max(.65rem, env(safe-area-inset-right));
    bottom: max(.65rem, env(safe-area-inset-bottom));
    max-width: calc(100vw - 1.3rem);
  }

  .accessibility-trigger {
    min-height: 44px;
    padding: .45rem .75rem .45rem .5rem;
    font-size: .82rem;
  }

  .accessibility-trigger-icon {
    width: 30px;
    height: 30px;
  }

  .accessibility-panel {
    width: min(390px, calc(100vw - 2.5rem));
    max-width: calc(100vw - 2.5rem);
    max-height: calc(100vh - 5.5rem);
  }
}
