/* The site's one stylesheet on top of Bootstrap 5.3, loaded after
   bootstrap.min.css; page groups add their own (booking.css, parent.css...).
   See docs/frameworkAndLayout.md (FE-7). It replaced site.css, which was
   mostly the pre-2022 site.

   The look follows what we had under MDB5 (decided 2026-10-07). Widgets we
   build read these variables, so a change here reaches them too. Line
   heights are unitless, so smaller text doesn't inherit a big fixed line. */

/* Source Serif 4, Adobe's open serif (SIL Open Font License,
   fonts/SourceSerif4-OFL.txt): taller lowercase and steadier strokes than
   the Garamond it replaced, so it reads well at text size for an older
   audience (picked 2026-10-10; Crimson Pro was the close second, if a
   warmer Garamond feel is wanted later). Latin subset, one variable file
   per style with weights 400-700 and optical sizes, so headings get the
   finer display cut. The vws template preloads the upright one. */
@font-face {
  font-family: "Source Serif 4";
  src: url("/css/fonts/SourceSerif4.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("/css/fonts/SourceSerif4-Italic.woff2") format("woff2");
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}

:root {
  /* 18px text for an older audience */
  --bs-body-font-family: "Source Serif 4", Georgia, serif;
  --bs-body-font-size: 1.125rem;
  --bs-body-line-height: 1.6;

  /* brand red as primary and danger */
  --bs-primary: #d7322d;
  --bs-primary-rgb: 215, 50, 45;
  --bs-danger: #d7322d;
  --bs-danger-rgb: 215, 50, 45;
  --bs-secondary-rgb: 178, 60, 0;

  --bs-body-color: #4f4f4f;
  --bs-body-color-rgb: 79, 79, 79;
  --bs-border-color: #e0e0e0;
  --bs-border-radius: 0.25rem;

  --bs-link-color: #3b71ca;
  --bs-link-color-rgb: 59, 113, 202;
  --bs-link-hover-color: #2f5aa2;
  --bs-link-hover-color-rgb: 47, 90, 162;

  /* Focus: fields get a red border, as they had under MDB; buttons and
     other controls get a dark outline, which shows on red buttons too.
     Never Bootstrap's blue. */
  --theme-focus-color: #4f4f4f;
  --theme-focus-halo: rgba(79, 79, 79, 0.25);
  --bs-focus-ring-color: var(--theme-focus-halo);

  --theme-shadow-raised: 0 4px 9px -4px rgba(0, 0, 0, 0.35);
  --theme-shadow-lifted:
    0 8px 9px -4px rgba(0, 0, 0, 0.15), 0 4px 18px 0 rgba(0, 0, 0, 0.1);
  --theme-shadow-menu:
    0 2px 15px -3px rgba(0, 0, 0, 0.07), 0 10px 20px -2px rgba(0, 0, 0, 0.04);
}

p {
  line-height: 1.55;
}

/* Brand words and headings. .title is the red italic page heading. */
.red {
  color: var(--bs-primary);
}
.bg-red {
  background-color: var(--bs-primary);
}
.grey {
  color: var(--bs-body-color);
}
.title,
.title-small,
.title-xsmall {
  color: var(--bs-primary);
  font-weight: 700;
  font-style: italic;
}
.title {
  font-size: 2.5rem;
}
.title-small {
  font-size: 1.8rem;
}
.title-xsmall {
  font-size: 1.2rem;
}

.nav-link {
  line-height: 1.3;
}
.footer-link {
  color: #661d1b;
}

/* Hides an element until a script shows it (classList.remove("hidden")). */
.hidden {
  display: none !important;
}

/* Links have no underline, except inside running text, where color alone
   isn't enough to tell a link apart (WCAG 1.4.1). */
a {
  text-decoration: none;
}
p a:not(.btn),
.prose a:not(.btn),
.card-text a:not(.btn) {
  text-decoration: underline;
}

.skip-link {
  text-decoration: underline;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--bs-primary);
  box-shadow: inset 0 0 0 1px var(--bs-primary);
  outline: 0;
}
.form-check-input:focus {
  border-color: var(--bs-primary);
  box-shadow: 0 0 0 0.2rem rgba(var(--bs-primary-rgb), 0.25);
}
.form-check-input:checked {
  background-color: var(--bs-primary);
  border-color: var(--bs-primary);
}

/* The skip link focuses <main>, which isn't a control, so no ring there. */
#main:focus {
  outline: 0;
}

.dropdown-menu {
  --bs-dropdown-font-size: 1rem;
  --bs-dropdown-padding-y: 0.375rem;
  --bs-dropdown-border-width: 0;
  --bs-dropdown-border-radius: 0.5rem;
  --bs-dropdown-box-shadow: var(--theme-shadow-menu);
  --bs-dropdown-item-padding-y: 0.5rem;
  --bs-dropdown-item-padding-x: 1.25rem;
  --bs-dropdown-link-color: var(--bs-primary);
  --bs-dropdown-link-hover-color: #a32622;
  --bs-dropdown-link-hover-bg: #fbeceb;
  --bs-dropdown-link-active-color: #a32622;
  --bs-dropdown-link-active-bg: #fbeceb;
  box-shadow: var(--bs-dropdown-box-shadow);
}

/* Site header (views/vws/vwsSiteTemplate.pug). Under 1200px the links fold
   into the menu button, so tablets in either orientation get a menu with
   48px rows instead of a squeezed row. */
.site-nav {
  --bs-navbar-padding-y: 0.5rem;
  --bs-navbar-color: var(--bs-primary);
  --bs-navbar-hover-color: #a32622;
  --bs-navbar-active-color: #a32622;
  --bs-navbar-nav-link-padding-x: 0.75rem;
  --bs-navbar-toggler-border-color: transparent;
  --bs-navbar-toggler-padding-x: 0.5rem;
  --bs-navbar-toggler-font-size: 1.5rem;
}
.site-nav .navbar-toggler {
  color: var(--bs-primary);
  min-width: 48px;
  min-height: 48px;
}
/* Bootstrap rings the button on any focus, so it stayed ringed after a tap.
   Show the site's focus outline for keyboard focus only. */
.site-nav .navbar-toggler:focus {
  box-shadow: none;
}
.site-nav .navbar-toggler:focus-visible {
  outline: 3px solid var(--theme-focus-color);
  outline-offset: 2px;
}
.site-logo {
  height: 56px;
  width: auto;
}
@media (min-width: 576px) {
  .site-logo {
    height: 70px;
  }
}
/* The current page sits on the same soft tint the menus use on hover. A
   drop-down's toggle gets it too when one of its pages is open. */
.site-nav .nav-link[aria-current="page"],
.site-nav .nav-link.is-current,
.site-nav .dropdown-item[aria-current="page"] {
  background: #fbeceb;
  color: #a32622;
}
.site-nav .nav-link[aria-current="page"],
.site-nav .nav-link.is-current {
  border-radius: 999px;
}
.site-book {
  white-space: nowrap;
}
/* The cart next to Book Your Visit when a visit is on hold. */
.site-cart {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: 2px solid var(--bs-primary);
  border-radius: 50%;
  color: var(--bs-primary);
  font-size: 1.25rem;
  text-decoration: none;
}
.site-cart:focus-visible {
  outline: 3px solid var(--theme-focus-color);
  outline-offset: 2px;
}
.site-cart:hover,
.site-cart:focus-visible {
  background: rgba(var(--bs-primary-rgb), 0.08);
  color: var(--bs-primary);
}
.site-cart-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 1.4rem;
  height: 1.4rem;
  padding: 0 0.3rem;
  border-radius: 0.7rem;
  background: var(--bs-primary);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.4rem;
  text-align: center;
}
@media (max-width: 1199.98px) {
  .site-nav .navbar-collapse {
    border-top: 1px solid var(--bs-border-color);
    margin-top: 0.5rem;
    max-height: calc(100vh - 6rem);
    overflow-y: auto;
  }
  .site-nav .nav-link,
  .site-nav .dropdown-item {
    display: flex;
    align-items: center;
    min-height: 48px;
    font-size: 1.125rem;
  }
  .site-nav .nav-link {
    width: 100%;
    text-align: start;
    padding-inline: 0.75rem;
  }
  /* In the folded menu the current row gets a red bar on its left edge. */
  .site-nav .nav-link[aria-current="page"],
  .site-nav .nav-link.is-current,
  .site-nav .dropdown-item[aria-current="page"] {
    border-radius: 0;
    box-shadow: inset 3px 0 0 var(--bs-primary);
  }
  .site-nav .dropdown-menu {
    box-shadow: none;
    border-inline-start: 3px solid var(--bs-border-color);
    border-radius: 0;
    margin-inline-start: 0.75rem;
  }
}

/* Footer: icons and links big enough to tap. */
.footer-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  font-size: 1.75rem;
  color: var(--grey-color, #5e5e5e);
}
.site-footer .footer-link {
  display: inline-block;
  padding: 0.5rem;
  font-size: 1rem;
  color: #661d1b;
}

.card {
  --bs-card-spacer-y: 1.5rem;
  --bs-card-spacer-x: 1.5rem;
  --bs-card-cap-padding-x: 1.5rem;
  --bs-card-cap-bg: transparent;
  --bs-card-border-width: 0;
  --bs-card-border-radius: 0.5rem;
}

/* Buttons: readable text, rounded corners, a soft shadow that grows on
   hover, no border. Small buttons are shorter, not smaller print. */
.btn {
  --bs-btn-padding-x: 1.5rem;
  --bs-btn-font-size: 1rem;
  --bs-btn-font-weight: 500;
  --bs-btn-line-height: 1.5;
  --bs-btn-border-width: 0;
  --bs-btn-border-radius: 0.5rem;
  padding-top: 0.5rem;
  padding-bottom: 0.4375rem;
  box-shadow: var(--theme-shadow-raised);
}
.btn:hover:not(:focus-visible) {
  box-shadow: var(--theme-shadow-lifted);
}
.btn-sm {
  --bs-btn-padding-x: 1rem;
  --bs-btn-font-size: 1rem;
  --bs-btn-border-radius: 0.4rem;
  padding-top: 0.25rem;
  padding-bottom: 0.1875rem;
}
[class*="btn-outline-"] {
  --bs-btn-border-width: 2px;
  --bs-btn-padding-x: 1.375rem;
  padding-top: 0.5rem;
  padding-bottom: 0.375rem;
}
.btn.shadow-none {
  box-shadow: none;
}

/* The brand red button, darker on hover and press. */
.btn-red {
  --bs-btn-color: #fff;
  --bs-btn-bg: #d7322d;
  --bs-btn-hover-color: #fff;
  --bs-btn-hover-bg: #b92b27;
  --bs-btn-active-color: #fff;
  --bs-btn-active-bg: #a32622;
  --bs-btn-disabled-color: #fff;
  --bs-btn-disabled-bg: #d7322d;
  --bs-btn-focus-shadow-rgb: 215, 50, 45;
}

/* Labels, hints and messages sit closer than running text. */
.form-label,
.form-text,
.form-check-label,
.invalid-feedback,
legend {
  line-height: 1.35;
}
.form-text {
  margin-top: 0.25rem;
}

/* Field borders a step darker than card borders, as MDB had them, so the
   boxes are easy to see. */
.form-control,
.form-select {
  border-color: #bdbdbd;
}

.form-control {
  line-height: 1.6;
  padding-top: 0.28rem;
  padding-bottom: 0.23rem;
}

/* Outlined fields with the label inside, the way MDB drew them: the label
   rests in the box like a placeholder and moves up into a gap in the top
   border while the field is focused or filled. Bootstrap's own floating
   label makes a 58px box; this one is the height of a plain field. The
   field needs a placeholder (the label text) for :placeholder-shown. */
.form-floating > .form-control,
.form-floating > .form-select {
  height: auto;
  min-height: 0;
  padding: 0.33em 0.75em;
  font-size: 1.125rem;
}
.form-floating > .form-control:focus,
.form-floating > .form-control:not(:placeholder-shown),
.form-floating > .form-control:-webkit-autofill,
.form-floating > .form-select {
  padding-top: 0.33em;
  padding-bottom: 0.33em;
}
.form-floating > label {
  height: auto;
  font-size: 1.125rem;
  margin: calc(0.33em + 1px) 0 0 0.5em;
  padding: 0 0.25em;
  border: 0;
  color: var(--bs-body-color);
  /* the same line as the field's text (Bootstrap's floating fields use 1.25) */
  line-height: 1.25;
  transform-origin: 0 0;
}
.form-floating > .form-control:focus ~ label,
.form-floating > .form-control:not(:placeholder-shown) ~ label,
.form-floating > .form-control:-webkit-autofill ~ label,
.form-floating > .form-select ~ label {
  background: var(--bs-body-bg);
  color: var(--bs-body-color);
  transform: translateY(-0.9em) scale(0.8);
}
.form-floating > .form-control:focus ~ label {
  color: var(--bs-primary);
}
/* Bootstrap paints a box behind a raised textarea label; the label has
   its own background here. */
.form-floating > label::after {
  display: none;
}

/* Pieces MDB gave us that Bootstrap doesn't have. Kept so pages that use
   them render the same; drop each one when its last page is rebuilt. */

/* Hero sections: a background image with an overlay on top. */
.bg-image {
  position: relative;
  overflow: hidden;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center center;
}

.mask {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

/* Testimonial cards: a faint edge shadow. */
.shadow-2-strong {
  box-shadow:
    0 0 3px 0 rgba(0, 0, 0, 0.16),
    0 2px 2px 0 rgba(0, 0, 0, 0.1) !important;
}

/* MDB's spacing steps past Bootstrap's 5, and its tight heading spacing. */
.mb-6 {
  margin-bottom: 3.5rem !important;
}
.mb-9 {
  margin-bottom: 6rem !important;
}
.ls-tight {
  letter-spacing: -0.025em !important;
}

/* A floating label textarea keeps the height its rows ask for. */
.form-floating > textarea.form-control {
  height: auto;
}

/* Content pages and the blog (views/vws/contentPage.pug, views/blog). */

/* Running text: left-aligned at a readable line length. */
.prose {
  max-width: 44rem;
  margin-inline: auto;
  text-align: start;
}
.prose h2 {
  color: var(--bs-primary);
  font-size: 1.6rem;
  font-weight: 700;
  font-style: italic;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
}
.prose h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}
.prose li + li {
  margin-top: 0.5rem;
}
.prose blockquote {
  border-inline-start: 4px solid var(--bs-border-color);
  padding-inline-start: 1.25rem;
  font-style: italic;
}

/* Page header with a lead image under the title. */
.content-hero {
  aspect-ratio: 16 / 7;
  object-fit: cover;
  width: 100%;
}

/* Question and answer cards (FAQ, visit ideas, reasons). */
.qa-card .card-title {
  color: var(--bs-primary);
  font-size: 1.4rem;
  font-weight: 700;
  font-style: italic;
  margin-bottom: 0.75rem;
}
.qa-card .card-text > :last-child {
  margin-bottom: 0;
}

/* Diary cards: the title link covers the card (stretched-link), so show the
   focus ring on the whole card. */
.blog-card .card-img-top {
  aspect-ratio: 3 / 1;
  object-fit: cover;
}
.blog-card:has(.stretched-link:focus-visible) {
  outline: 3px solid var(--theme-focus-color);
  outline-offset: 3px;
}
.blog-card .stretched-link:focus-visible {
  outline: 0;
}
.blog-card .card-title a {
  color: inherit;
}
.blog-card:hover .card-title a {
  text-decoration: underline;
}
.blog-hero {
  aspect-ratio: 3 / 1;
  object-fit: cover;
}
.content-hero.object-top {
  object-position: center 20%;
}

/* Home page banner (views/vws/home.pug), tuned with production's MDB
   version: a fixed 575px with the photo centered, so the crop shows the
   girl and the tablet at every width, and the words in a narrow column on
   the photo's empty left side. Phones start the words near the top (no
   centering) so they stay above her hands. */
.home-hero {
  height: 575px;
  overflow: hidden;
  background: #ececec url("/images/pages/home-hero.jpg") 50% 50% / cover
    no-repeat;
  text-align: center;
}
/* The words are a size up from tablets on, with roomier lines. */
.home-hero-text {
  font-style: italic;
  line-height: 1.7;
}
@media (min-width: 576px) {
  .home-hero-text {
    font-size: 1.25rem;
  }
}
.home-testimonial-img {
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.home-more-link,
.home-next-link {
  color: var(--bs-primary);
}
.home-more-link {
  font-size: 1.25rem;
}
.home-more-link:hover,
.home-next-link:hover {
  color: #a32622;
}
.home-more-link .fa-chevron-right,
.home-next-link .fa-chevron-right {
  font-size: 0.75em;
}
/* The home page's ending: a light band with white link tiles. */
.home-next {
  background: #f7f3f2;
}
.home-next-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: 100%;
  min-height: 56px;
  padding: 0.75rem 1.25rem;
  border-radius: 0.75rem;
  background: #fff;
  box-shadow: var(--theme-shadow-raised);
  font-size: 1.125rem;
  line-height: 1.35;
}
.home-next-link:hover {
  box-shadow: var(--theme-shadow-lifted);
}
.home-next-link:focus-visible {
  outline: 3px solid var(--theme-focus-color);
  outline-offset: 2px;
}

/* Gift tickets (views/donateTo). */
.gift-org-logo {
  max-width: min(100%, 22rem);
  max-height: 10rem;
  object-fit: contain;
}
