:root {
  --site-dark-page: #191b20;
  --site-dark-surface: #24272e;
  --site-dark-surface-alt: #2d3139;
  --site-dark-text: #d5d8df;
  --site-dark-heading: #e3e5e9;
  --site-dark-muted: #a9aeb8;
  --site-dark-line: #454b56;
}

.site-footer {
  position: relative;
}

.site-theme-toggle {
  align-items: center;
  background: #000066;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 50%;
  bottom: 0.65rem;
  box-shadow: 0 0.45rem 1rem rgba(0, 0, 60, 0.24);
  color: #fff;
  display: inline-flex;
  font-size: 1.2rem;
  height: 2.55rem;
  justify-content: center;
  line-height: 1;
  padding: 0;
  position: absolute;
  right: 0.8rem;
  transition: background-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
  width: 2.55rem;
  z-index: 1;
}

.site-theme-toggle:hover,
.site-theme-toggle:focus-visible {
  background: #252b92;
  box-shadow: 0 0.6rem 1.3rem rgba(0, 0, 60, 0.3);
  color: #fff;
  transform: translateY(-1px);
}

body.has-site-dark-mode {
  background: var(--site-dark-page) !important;
  color: var(--site-dark-text);
  color-scheme: dark;
}

body.has-site-dark-mode main,
body.has-site-dark-mode .landing-page,
body.has-site-dark-mode .titles-page,
body.has-site-dark-mode .about-page,
body.has-site-dark-mode .policy-page,
body.has-site-dark-mode .pamphlet-detail-page,
body.has-site-dark-mode .sefer-detail-page {
  background-color: var(--site-dark-page) !important;
  color: var(--site-dark-text);
}

body.has-site-dark-mode h1,
body.has-site-dark-mode h2,
body.has-site-dark-mode h3,
body.has-site-dark-mode h4,
body.has-site-dark-mode h5,
body.has-site-dark-mode h6,
body.has-site-dark-mode .landing-hebrew-title,
body.has-site-dark-mode .publication-overview__availability,
body.has-site-dark-mode .subscription-tenure,
body.has-site-dark-mode .subscription-callout {
  color: var(--site-dark-heading) !important;
}

body.has-site-dark-mode a:not(.btn):not(.nav-link) {
  color: #aecbff;
}

body.has-site-dark-mode .card,
body.has-site-dark-mode .modal-content,
body.has-site-dark-mode .dropdown-menu,
body.has-site-dark-mode .list-group-item,
body.has-site-dark-mode .subscription-layout,
body.has-site-dark-mode .subscription-details,
body.has-site-dark-mode .subscription-option,
body.has-site-dark-mode .catalog-card,
body.has-site-dark-mode .policy-shell,
body.has-site-dark-mode .error-page__card {
  background-color: var(--site-dark-surface) !important;
  border-color: var(--site-dark-line) !important;
  color: var(--site-dark-text);
}

body.has-site-dark-mode .titles-catalog__filters,
body.has-site-dark-mode .parshah-filter-header,
body.has-site-dark-mode .parshah-filter-menu,
body.has-site-dark-mode .parshah-filter-tabs,
body.has-site-dark-mode input:not([type="submit"]):not([type="button"]),
body.has-site-dark-mode select,
body.has-site-dark-mode textarea {
  background-color: var(--site-dark-surface) !important;
  border-color: var(--site-dark-line) !important;
  color: var(--site-dark-text) !important;
}

body.has-site-dark-mode .titles-catalog__filters a:not(.active) {
  color: #b5c9eb;
}

body.has-site-dark-mode .subscription-option:nth-child(2n),
body.has-site-dark-mode .bg-odd-div,
body.has-site-dark-mode .bg-light,
body.has-site-dark-mode .bg-white {
  background-color: var(--site-dark-surface-alt) !important;
}

body.has-site-dark-mode .title-links,
body.has-site-dark-mode .seasonal-section,
body.has-site-dark-mode .parenting-section,
body.has-site-dark-mode .subscription-options,
body.has-site-dark-mode hr {
  border-color: var(--site-dark-line) !important;
}

body.has-site-dark-mode .text-dark,
body.has-site-dark-mode .text-body,
body.has-site-dark-mode .card-title,
body.has-site-dark-mode .card-text {
  color: var(--site-dark-text) !important;
}

body.has-site-dark-mode .text-muted,
body.has-site-dark-mode small,
body.has-site-dark-mode .titles-catalog__eyebrow,
body.has-site-dark-mode .landing-memory {
  color: var(--site-dark-muted) !important;
}

body.has-site-dark-mode .site-theme-toggle {
  background: #c7cad1;
  border-color: #c7cad1;
  color: #24272e;
}

body.has-site-dark-mode .site-theme-toggle:hover,
body.has-site-dark-mode .site-theme-toggle:focus-visible {
  background: #d3d6dc;
  border-color: #d3d6dc;
  color: #1d2026;
}

@media (max-width: 640px) {
  .site-theme-toggle {
    bottom: 0.55rem;
    height: 2.35rem;
    right: 0.55rem;
    width: 2.35rem;
  }
}
