*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-family: "Inter", system-ui, sans-serif;
}

body {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem;
  color: #1d1d1d;
}

a,
a:visited {
  color: #0000ee;
  text-decoration: none;
}

a:hover,
a:focus-visible,
a:active,
a[aria-current="page"] {
  text-decoration: underline;
}

p {
  margin-block: 4px;
  line-height: 1.3;
}

main {
  min-width: 0;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  padding: .5rem 1rem;
}

form {
  display: grid;
  gap: 1.5rem;
  margin-block: 1.5rem;
}

form label {
  display: grid;
  gap: .35rem;
  font-weight: 600;
}

form input:not([type="checkbox"], [type="radio"], [type="hidden"]),
form select,
form textarea {
  width: min(100%, 40rem);
  padding: .5rem;
}

form textarea {
  min-height: 7rem;
  resize: both;
}

form fieldset {
  display: grid;
  gap: .75rem;
  margin: 0;
  padding: 1rem;
  border: 1px solid #bbb;
}

form legend {
  padding-inline: .25rem;
  font-weight: 600;
}

form button {
  justify-self: start;
}

.form-option,
.subscription,
.options label {
  display: flex;
  gap: .5rem;
  align-items: flex-start;
  font-weight: 400;
}

.form-option input,
.subscription input,
.options input {
  flex: 0 0 auto;
  margin-top: .2rem;
  padding: 0;
}

[role="status"] {
  min-height: 1.5rem;
}

.site-header {
  margin-bottom: 1rem;
}

.header-graphic-container {
  position: relative;
  width: fit-content;
  max-width: 100%;
}

.header-graphic {
  display: block;
  max-width: 100%;
  max-height: 300px;
  object-fit: contain;
}

.site-header .header-auth-link,
.site-header .header-auth-link:visited {
  z-index: 1;
  padding: 5px 8px;
  border-bottom-left-radius: 2px;
  background: rgba(0, 0, 0, 0.7);
  font-weight: 400;
  color: #fff;
}

.header-graphic-container .header-auth-link {
  position: absolute;
  top: 2px;
  right: 4px;
}

.site-navigation {
  width: 100vw;
  margin-inline: calc(50% - 50vw);
  background: #000;
}

.site-navigation ul {
  display: flex;
  flex-wrap: wrap;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

.site-navigation a {
  display: block;
  padding: 0.75rem 0.75rem;
  color: #fff;
}

.site-navigation .public-menu-action-start {
  margin-left: auto;
}

.site-navigation .public-menu-action a,
.site-navigation .public-menu-action a:visited {
  color: #ffffe0;
}

.site-navigation a:hover,
.site-navigation a:focus-visible,
.site-navigation a.selected {
  background: #333;
}

.site-navigation a.selected {
  animation: menu-item-blink 1.5s ease-in-out 2;
}

@keyframes menu-item-blink {
  50% {
    opacity: .7;
  }
}

.sign-in-page .sign-in {
  width: min(100%, 288px);
  margin: 1.5rem auto;
  padding: 1rem;
  border: 1px solid #ccc;
  border-radius: .25rem;
}

.sign-in-page .sign-in form {
  gap: .75rem;
  margin: 0;
}

.sign-in-page .sign-in input {
  width: 100%;
}

.sign-in-page .sign-in button {
  margin-top: .25rem;
}

.sign-in-page .sign-in-error {
  margin: 0;
  color: #a40000;
}

.home-page .carousel {
  margin: 1.5rem 0;
}

.home-page .carousel-image {
  margin: 0;
}

.home-page .glide__slide img {
  display: block;
  width: 100%;
  max-height: 600px;
  object-fit: contain;
}

.home-page .carousel-image figcaption {
  padding: .75rem 1rem;
  background: #f3f3f3;
  text-align: center;
}

.home-page .carousel-image h2 {
  margin: 0 0 .5rem;
}

.home-page .carousel-image-metadata {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .35rem 1.5rem;
  margin: 0;
}

.home-page .carousel-image-metadata > div {
  display: flex;
  gap: .4rem;
}

.home-page .carousel-image-metadata dt {
  font-weight: 700;
}

.home-page .carousel-image-metadata dd {
  margin: 0;
}

.home-page .glide__arrows {
  display: flex;
  justify-content: space-between;
  margin-top: .5rem;
}

.home-page .welcome {
  position: relative;
  top: 9px;
  flex: 1;
  margin: 0 1rem;
  font-size: 1.25rem;
  font-weight: 600;
  text-align: center;
}

.home-page .upcoming-meetings {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 2rem 0;
  border: 1px solid #bbb;
  border-radius: .25rem;
}

.home-page .upcoming-meeting {
  min-width: 0;
  padding: 1rem;
}

.home-page .upcoming-meeting + .upcoming-meeting {
  border-left: 1px solid #bbb;
}

.home-page .upcoming-meeting h2 {
  margin-top: 0;
}

.home-page .activities {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.home-page .activities img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.home-page .testimonials {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  padding: 0;
  list-style: none;
}

.home-page .testimonial {
  min-width: 0;
}

.home-page blockquote {
  margin: 0;
  padding: 1rem;
  background: #f5f5f5;
}

.home-page blockquote footer {
  font-weight: 600;
}

.news-page-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1rem;
  margin-block: 1.5rem;
}

.news-page-header h1 {
  margin-top: 0;
}

.news-add-post {
  display: inline-block;
  padding: .5rem 1rem;
  border: 1px solid #767676;
  background: #eee;
  color: #1d1d1d;
  text-decoration: none;
}

.news-add-post:hover,
.news-add-post:focus-visible {
  background: #ddd;
}

.news-form-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.news-form-actions button {
  justify-self: auto;
}

.news-list {
  width: 100%;
  border-collapse: collapse;
}

.news-list th,
.news-list td {
  padding: .5rem;
  border-bottom: 1px solid #ccc;
  text-align: left;
}

.news-post-row {
  cursor: pointer;
}

.news-post-row:hover,
.news-post-row:focus-visible {
  background: #f1f1f1;
}

.news-thumbnail {
  display: block;
  width: 100px;
  height: 75px;
  object-fit: cover;
}

.news-placeholder {
  display: grid;
  place-items: center;
  background: #eee;
  font-weight: 700;
}

.news-title {
  max-width: 500px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.news-post-navigation {
  display: flex;
  gap: 1rem;
  margin-block: 1rem;
}

.news-post-navigation span {
  color: #666;
}

.news-detail-image {
  display: block;
  max-width: 100%;
  max-height: 600px;
  margin-block: 1rem;
  object-fit: contain;
}

.news-body {
  line-height: 1.5;
}

.calendar-controls {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
  margin-top: 1.5rem;
}

.calendar-controls h1 {
  margin: 0;
  text-align: center;
}

.calendar-controls .month-navigation-form {
  display: block;
  margin: 0;
}

.calendar-controls .next-month {
  justify-self: end;
}

.current-month-form {
  display: none;
}

.calendar-view-switcher {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: .5rem;
  align-items: center;
  margin: 1rem 0;
}

.calendar-view-options {
  grid-column: 2;
  display: flex;
  gap: .5rem;
}

.calendar-view-switcher a {
  display: inline-flex;
  box-sizing: border-box;
  width: 6rem;
  min-height: 2.4rem;
  padding: .5rem .75rem;
  align-items: center;
  justify-content: center;
  border: 1px solid #7d0000;
  border-radius: .25rem;
  color: #7d0000;
  text-decoration: none;
}

.calendar-view-switcher .calendar-add-post {
  grid-column: 3;
  justify-self: end;
}

.calendar-view-switcher a[aria-current="page"] {
  background: #7d0000;
  color: #fff;
}

.event-add-form {
  width: min(100%, 42rem);
  gap: 1rem;
}

.event-add-form input,
.event-add-form select,
.event-add-form textarea {
  width: 100%;
}

.event-add-form textarea {
  min-height: 10rem;
}

.event-add-form #event-attachments-help {
  margin-top: -1rem;
  color: #555;
}

.event-form-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.event-form-actions button {
  justify-self: auto;
}

.calendar-grid-wrapper {
  overflow-x: auto;
}

.calendar-grid {
  width: 100%;
  min-width: 700px;
  table-layout: fixed;
  border-collapse: collapse;
}

.calendar-grid th,
.calendar-grid td {
  border: 1px solid #bbb;
}

.calendar-grid th {
  padding: .5rem;
  background: #f2f2f2;
}

.calendar-grid td {
  height: 8rem;
  padding: .4rem;
  vertical-align: top;
}

.calendar-grid .outside-month {
  background: #f6f6f6;
  color: #666;
}

.calendar-day-events {
  display: grid;
  gap: .25rem;
  margin: .4rem 0 0;
  padding: 0;
  list-style: none;
}

.calendar-day-events li,
.linear-event {
  border-left: .35rem solid var(--event-color);
}

.calendar-day-events li {
  padding: .2rem .3rem;
  overflow-wrap: anywhere;
}

.calendar-event-thumbnail {
  display: block;
  width: 100%;
  height: 5rem;
  margin-bottom: .3rem;
  border-radius: .2rem;
  object-fit: cover;
}

.calendar-day-events li + li {
  border-top: 1px solid #ddd;
}

.linear-calendar {
  max-height: 70vh;
  overflow-y: auto;
  border: 1px solid #bbb;
  scroll-behavior: smooth;
}

.linear-day {
  padding: 1rem;
  border-top: 1px solid #bbb;
  scroll-margin-top: 0;
}

.linear-day:first-child {
  border-top: 0;
}

.linear-day.outside-month {
  background: #f6f6f6;
}

.linear-event.has-thumbnail {
  display: grid;
  grid-template-columns: 8rem minmax(0, 1fr);
  gap: .75rem;
  align-items: start;
}

.linear-event .calendar-event-thumbnail {
  width: 8rem;
  height: 6rem;
  margin: 0;
}

.linear-event-content {
  min-width: 0;
}

.calendar-grid .today,
.linear-day.today {
  position: relative;
  background: #ffffef;
}

.calendar-grid .today > time,
.linear-day.today h2 {
  color: #7d0000;
  font-weight: 800;
}

.linear-day h2,
.linear-event h3 {
  margin-top: 0;
}

.linear-event {
  margin-top: 1rem;
  padding-left: .75rem;
}

.event-byline {
  color: #555;
}

.event-description {
  line-height: 1.5;
}

.event-description > :first-child {
  margin-top: 0;
}

.event-description > :last-child {
  margin-bottom: 0;
}

.event-empty {
  color: #666;
  font-style: italic;
}

.event-detail {
  max-width: 50rem;
}

#delete-event {
  margin-top: 1rem;
}

.settings-page #settings-form > section,
.account-page .danger {
  border-top: 2px solid #7d0000;
  padding-top: 1rem;
}

.settings-page #settings-form > section {
  display: grid;
  gap: 1rem;
}

.account-page #account-form > section {
  display: grid;
  gap: 1rem;
}

.account-page #account-form > .personal-information,
.account-page #account-form > .photographic-profile {
  border-top: 1px solid #bbb;
  padding-top: 1rem;
}

.account-page .membership-detail {
  margin: 0;
  white-space: pre-wrap;
}

.settings-page .gallery-options {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding: .5rem;
}

.settings-page .gallery-option {
  display: grid;
  flex: 0 0 160px;
  gap: .5rem;
  padding: .5rem;
  border: 3px solid transparent;
  background: #fff;
  text-align: left;
}

.settings-page .gallery-option.active {
  border-color: #7d0000;
}

.settings-page .gallery-option img,
.settings-page .empty-thumbnail {
  width: 150px;
  height: 100px;
  background: #eee;
  object-fit: cover;
}

.settings-page .empty-thumbnail {
  display: grid;
  place-items: center;
}

.settings-page .activity-images,
.settings-page .testimonials,
.settings-page .meeting-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.settings-page .testimonials {
  padding: 0;
  list-style: none;
}

.settings-page .activity-image,
.settings-page .testimonial,
.settings-page .testimonial fieldset {
  min-width: 0;
}

.settings-page .activity-image input,
.settings-page .testimonial input,
.settings-page .testimonial textarea {
  width: 100%;
}

.settings-page input[type="number"],
.settings-page select[name="homepage_carousel_display_seconds"] {
  width: auto;
  justify-self: start;
}

.settings-page .activity-image img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.settings-page .meeting-card {
  display: grid;
  gap: .5rem;
  padding: 1rem;
  border: 1px solid #bbb;
  background: #f7f7f7;
  text-align: left;
}

.settings-page .options {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.settings-page dialog {
  max-width: 650px;
}

.settings-page dialog p {
  white-space: pre-wrap;
}

.contact-page form,
.join-page form,
.visit-page form,
.account-page #account-form {
  max-width: 40rem;
}

.visit-page hr {
  width: 100%;
}

.thank-you-page .home-link {
  text-align: center;
}

.administration-page .user-table,
.pending-page .pending-table {
  max-height: 65vh;
  overflow: auto;
  border: 1px solid #bbb;
}

.administration-page table,
.pending-page table {
  width: 100%;
  border-collapse: collapse;
}

.administration-page th,
.administration-page td,
.pending-page th,
.pending-page td {
  padding: .6rem;
  border-bottom: 1px solid #ddd;
  text-align: left;
}

.administration-page th,
.pending-page th {
  position: sticky;
  top: 0;
  background: #fff;
}

.administration-page .administrator {
  background: #fff1c9;
}

.roster-page .roster-filter {
  display: flex;
  gap: .5rem;
  margin: .25rem 0 1rem;
}

.roster-page .roster-actions {
  display: flex;
  margin-block: 0 1rem;
}

.roster-page .roster-filter input {
  flex: 1 1 40rem;
  max-width: 40rem;
  min-width: 0;
  padding: .5rem;
}

.roster-page .roster-table {
  overflow-x: auto;
}

.roster-page table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid #000;
}

.roster-page th,
.roster-page td {
  padding: .75rem;
  border: 1px solid #000;
  text-align: left;
}

.roster-page th {
  background: #fff;
}

.member-detail-page main > nav,
.pending-detail-page main > nav {
  display: flex;
  gap: .5rem;
  align-items: center;
}

.member-detail-page .member-details,
.pending-detail-page .application-details {
  display: grid;
  gap: .75rem;
  max-width: 52rem;
}

.member-detail-page .member-details > div,
.pending-detail-page .application-details > div {
  display: grid;
  grid-template-columns: minmax(8rem, 12rem) minmax(0, 1fr);
  gap: 1rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid #ddd;
}

.member-detail-page .member-details dt,
.pending-detail-page .application-details dt {
  font-weight: 700;
}

.member-detail-page .member-details dd,
.pending-detail-page .application-details dd {
  margin: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.pending-detail-page .application-actions {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.pending-detail-page .application-actions form {
  margin: 0;
}

.member-detail-page .member-administration {
  display: grid;
  gap: 1rem;
  max-width: 52rem;
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 2px solid #7d0000;
}

.member-detail-page .member-administration p {
  margin: 0;
}

.member-detail-page #club-roles-form {
  display: grid;
  gap: .5rem;
  max-width: 40rem;
}

.member-detail-page #club-roles-form textarea {
  min-height: 6rem;
}

.member-detail-page #club-roles-form button,
.member-detail-page #delete-member {
  justify-self: start;
}

.member-detail-page #delete-member {
  margin-top: 1rem;
}

.password-reset-page main > nav {
  display: flex;
  gap: .5rem;
  align-items: center;
}

.password-reset-page #password-reset-form {
  display: grid;
  gap: 1rem;
  max-width: 40rem;
}

.reliquary-page .reliquary-filter {
  display: grid;
  gap: .35rem;
  width: min(100%, 40rem);
  margin-bottom: 1rem;
  font-weight: 600;
}

.reliquary-page .reliquary-filter input {
  padding: .5rem;
}

.reliquary-page .reliquary-table {
  overflow-x: auto;
}

.reliquary-page table {
  width: 100%;
  border-collapse: collapse;
}

.reliquary-page th,
.reliquary-page td {
  padding: .75rem;
  border: 1px solid #bbb;
  text-align: left;
  vertical-align: top;
}

.reliquary-page .reliquary-thumbnail-cell {
  width: 100px;
}

.reliquary-page .reliquary-thumbnail,
.reliquary-page .reliquary-thumbnail-placeholder {
  display: block;
  width: 80px;
  height: 60px;
  border-radius: .25rem;
}

.reliquary-page .reliquary-thumbnail {
  background: #eee;
  object-fit: cover;
}

.reliquary-page .reliquary-thumbnail-placeholder {
  display: grid;
  place-items: center;
  background: #eee;
  color: #666;
  font-size: 1.5rem;
}

.reliquary-page .reliquary-document-name {
  color: #7d0000;
  font-weight: 600;
}

.reliquary-page .reliquary-document-actions {
  display: inline-flex;
  gap: .65rem;
  margin-left: .65rem;
}

.reliquary-page .reliquary-document-actions a {
  color: #7d0000;
}

.reliquary-page .reliquary-document-actions a:hover,
.reliquary-page .reliquary-document-actions a:focus-visible {
  color: #000;
}

.reliquary-page .reliquary-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin: 1rem 0 1.5rem;
}

.reliquary-page .reliquary-detail {
  display: grid;
  grid-template-columns: minmax(180px, 300px) minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
}

.reliquary-page .reliquary-detail h1 {
  margin-top: 0;
}

.reliquary-page .reliquary-detail-thumbnail {
  width: 100%;
  min-height: 180px;
  max-height: 300px;
  object-fit: contain;
}

.reliquary-page .reliquary-detail-thumbnail.reliquary-thumbnail-placeholder {
  height: 240px;
  font-size: 2rem;
}

.reliquary-page .reliquary-detail-thumbnail.reliquary-thumbnail-placeholder span {
  font-size: 1rem;
}

.reliquary-page .reliquary-detail-metadata {
  display: grid;
  gap: .75rem;
  margin: 0 0 1.5rem;
}

.reliquary-page .reliquary-detail-metadata div {
  display: grid;
  grid-template-columns: 7rem 1fr;
  gap: .75rem;
}

.reliquary-page .reliquary-detail-metadata dt {
  font-weight: 700;
}

.reliquary-page .reliquary-detail-metadata dd {
  margin: 0;
}

.reliquary-page .reliquary-detail-description {
  white-space: pre-wrap;
}

.forums-page .forum-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin: 1rem 0 1.5rem;
}

.forums-page .forum-page-header {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
}

.forums-page .forum-page-header h1 {
  margin-block: 0;
}

.forums-page .button-link {
  display: inline-block;
  padding: .5rem 1rem;
  border: 1px solid #767676;
  border-radius: .2rem;
  background: #efefef;
  color: #1d1d1d;
}

.forums-page .button-link:hover,
.forums-page .button-link:focus-visible {
  background: #ddd;
}

.forums-page .button-link.secondary {
  background: #fff;
}

.forums-page .forum-topic-composer {
  margin-block: 1.5rem 2rem;
  padding: 1rem;
  border: 1px solid #bbb;
  border-radius: .25rem;
  background: #f8f8f8;
}

.forums-page .forum-topic-composer h2 {
  margin-top: 0;
}

.forums-page .forum-topic-composer form {
  margin-bottom: 0;
}

.forums-page .forum-topic-composer textarea {
  min-height: 10rem;
}

.forums-page .forum-directory {
  display: grid;
  gap: .75rem;
  padding: 0;
  list-style: none;
}

.forums-page .forum-directory li {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  justify-content: space-between;
  padding: 1rem;
  border: 1px solid #bbb;
}

.forums-page .forum-search {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: end;
}

.forums-page .forum-search label {
  flex: 1 1 20rem;
}

.forums-page .forum-search input {
  width: 100%;
}

.forums-page .forum-search a {
  align-self: center;
}

.forums-page .forum-table {
  overflow-x: auto;
}

.forums-page table {
  width: 100%;
  border-collapse: collapse;
}

.forums-page th,
.forums-page td {
  padding: .75rem;
  border: 1px solid #bbb;
  text-align: left;
  vertical-align: top;
}

.forums-page .forum-delete {
  padding: .25rem .5rem;
  color: #7d0000;
}

.forums-page .forum-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem 1rem;
  align-items: center;
  justify-content: center;
  margin-block: 1.5rem;
}

.forums-page .forum-pagination [aria-disabled="true"] {
  color: #666;
}

.forums-page .forum-history {
  display: grid;
  gap: 1rem;
  max-height: 65vh;
  padding-right: .5rem;
  overflow-y: auto;
}

.forums-page .forum-history-item,
.forums-page .forum-message {
  padding: 1rem;
  border: 1px solid #bbb;
  border-radius: .25rem;
}

.forums-page .forum-history-item header,
.forums-page .forum-history-item footer,
.forums-page .forum-message footer {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: center;
  justify-content: space-between;
}

.forums-page .forum-history-item h2 {
  margin: 0;
  font-size: 1rem;
}

.forums-page .forum-message-body {
  margin-block: 1rem;
  overflow-wrap: anywhere;
  line-height: 1.5;
}

.forums-page .forum-post-form textarea {
  min-height: 16rem;
}

.forums-page .forum-form-actions {
  display: flex;
  gap: .75rem;
  align-items: center;
}

.forums-page .forum-form-actions button {
  justify-self: auto;
}

.videos-page .video-filter {
  display: grid;
  gap: .35rem;
  width: min(100%, 40rem);
  margin-bottom: 1rem;
  font-weight: 600;
}

.videos-page .video-filter input {
  padding: .5rem;
}

.videos-page .video-sort {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  margin-bottom: 1.5rem;
}

.videos-page .video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 1.5rem;
}

.videos-page .video-card {
  min-width: 0;
  padding: 1rem;
  border: 1px solid #bbb;
  border-radius: .25rem;
}

.videos-page .video-player {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.videos-page .video-card h2 {
  margin-bottom: .5rem;
}

.videos-page .video-description {
  white-space: pre-wrap;
}

.videos-page .video-edit-form {
  gap: .75rem;
  margin-top: 1rem;
}

.videos-page .video-edit-form label {
  display: grid;
  gap: .35rem;
  font-weight: 600;
}

.videos-page .video-edit-form input,
.videos-page .video-edit-form textarea {
  box-sizing: border-box;
  width: 100%;
  padding: .5rem;
}

.videos-page .video-edit-form textarea {
  min-height: 7rem;
  resize: vertical;
}

.videos-page .video-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  justify-content: flex-end;
}

.videos-page .video-actions button {
  justify-self: auto;
}

.videos-page .video-metadata,
.videos-page .video-upload #video-upload-help {
  color: #555;
}

.videos-page .video-upload #video-upload-help {
  margin: -.75rem 0 0;
}

.galleries-page .gallery-page-header,
.galleries-page .gallery-detail-header {
  margin-block: 1.5rem;
}

.galleries-page .gallery-page-header {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: start;
  justify-content: space-between;
}

.galleries-page .gallery-page-header h1,
.galleries-page .gallery-detail-header h1 {
  margin-top: 0;
}

.galleries-page .gallery-create-link,
.galleries-page .gallery-create-link:visited {
  display: inline-block;
  padding: .5rem 1rem;
  border: 1px solid #767676;
  border-radius: .25rem;
  background: #eee;
  font-weight: 700;
  color: #1d1d1d;
}

.galleries-page .gallery-create-link:hover,
.galleries-page .gallery-create-link:focus-visible {
  background: #ddd;
}

.galleries-page.gallery-create-page main {
  max-width: 40rem;
}

.galleries-page .gallery-location-options,
.galleries-page .gallery-location-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.galleries-page .gallery-location-options {
  margin-bottom: .5rem;
}

.galleries-page .gallery-location-fields label {
  flex: 1 1 12rem;
}

.galleries-page .gallery-search {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: end;
  margin-block: .5rem 1rem;
}

.galleries-page .gallery-search label {
  flex: 1 1 24rem;
}

.galleries-page .gallery-search input {
  width: 100%;
}

.galleries-page .gallery-search a {
  align-self: center;
}

.galleries-page .gallery-view-switcher,
.galleries-page .gallery-form-actions,
.galleries-page .gallery-carousel-controls,
.galleries-page .gallery-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: center;
}

.galleries-page .gallery-view-switcher {
  margin-block: 1rem;
}

.galleries-page .gallery-view-switcher button[aria-pressed="true"] {
  border-color: #7d0000;
  background: #7d0000;
  color: #fff;
}

.galleries-page [hidden] {
  display: none !important;
}

.galleries-page .gallery-list-thumbnails,
.galleries-page .gallery-image-thumbnails {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1rem;
  padding: .5rem;
  overflow-x: hidden;
  overflow-y: auto;
  border: 1px solid #bbb;
  scrollbar-gutter: stable;
  scroll-snap-type: y proximity;
}

.galleries-page .gallery-list-thumbnails {
  grid-auto-rows: 15.5rem;
  max-height: 49.5rem;
}

.galleries-page .gallery-image-thumbnails {
  grid-auto-rows: 12rem;
  max-height: 39rem;
}

.galleries-page .gallery-thumbnail-card,
.galleries-page .gallery-image-thumbnail {
  min-width: 0;
  overflow: hidden;
  scroll-snap-align: start;
}

.galleries-page .gallery-thumbnail-card h2,
.galleries-page .gallery-image-thumbnail h2 {
  display: -webkit-box;
  margin-block: .5rem .25rem;
  overflow-wrap: anywhere;
  overflow: hidden;
  font-size: 1rem;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.galleries-page .gallery-thumbnail-card > p {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.galleries-page .gallery-list-thumbnail,
.galleries-page .gallery-image-thumbnail .gallery-image-viewer-trigger {
  display: block;
  width: 100%;
  height: 140px;
  border-radius: .2rem;
  background: #eee;
  object-fit: contain;
}

.galleries-page .gallery-image-thumbnail .gallery-image-viewer-trigger img {
  object-fit: contain;
}

.galleries-page .gallery-placeholder {
  display: grid;
  place-items: center;
  color: #666;
  font-size: 2rem;
}

.galleries-page .gallery-detailed-list,
.galleries-page .gallery-image-list {
  display: grid;
  gap: 1rem;
  max-height: 70vh;
  padding-right: .5rem;
  overflow-y: auto;
}

.galleries-page .gallery-list-card,
.galleries-page .gallery-image-list-item {
  display: grid;
  grid-template-columns: minmax(180px, 280px) minmax(0, 1fr);
  gap: 1rem;
  padding: 1rem;
  border: 1px solid #bbb;
  border-radius: .25rem;
}

.galleries-page .gallery-list-card h2,
.galleries-page .gallery-image-list-item h2 {
  margin-top: 0;
}

.galleries-page .gallery-list-cover,
.galleries-page .gallery-image-list-item > .gallery-image-viewer-trigger {
  display: block;
  width: 100%;
  height: 190px;
  background: #eee;
  object-fit: contain;
}

.galleries-page .gallery-image-viewer-trigger {
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: .2rem;
  background: #eee;
  cursor: zoom-in;
}

.galleries-page .gallery-image-viewer-trigger img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.galleries-page .gallery-list-cover {
  object-fit: cover;
}

.galleries-page .gallery-description {
  white-space: pre-wrap;
}

.galleries-page .gallery-metadata,
.galleries-page .gallery-carousel-help,
.galleries-page .gallery-reorder-help,
.galleries-page #gallery-upload-help {
  color: #555;
}

.galleries-page .gallery-reorder-help {
  align-self: flex-end;
  margin: 0 0 0 auto;
  text-align: right;
  transform: translateY(6px);
}

.galleries-page .gallery-empty {
  color: #666;
  font-style: italic;
}

.galleries-page #gallery-map {
  width: 100%;
  height: min(70vh, 650px);
  min-height: 400px;
  border: 1px solid #bbb;
  border-radius: 3px;
}

.galleries-page .gallery-map-marker {
  border: 2px solid #fff;
  border-radius: .2rem;
  background: #333;
  box-shadow: 0 1px 6px rgba(0, 0, 0, .65);
  cursor: pointer;
}

.galleries-page .gallery-map-marker img {
  display: block;
  width: 68px;
  height: 50px;
  border-radius: .1rem;
  object-fit: cover;
}

.galleries-page .gallery-breadcrumb {
  margin-block: 1rem 1.5rem;
}

.galleries-page .gallery-image-thumbnail[draggable="true"] {
  cursor: grab;
}

.galleries-page .gallery-image-thumbnails.drop-target {
  outline: 2px dashed #7d0000;
  outline-offset: -4px;
}

.galleries-page .gallery-image-thumbnail.dragging {
  opacity: .45;
  cursor: grabbing;
}

.galleries-page .gallery-image-metadata {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: .35rem .75rem;
}

.galleries-page .gallery-image-metadata dt {
  font-weight: 700;
}

.galleries-page .gallery-image-metadata dd {
  margin: 0;
}

.galleries-page .gallery-image-edit-form {
  gap: .75rem;
  margin: 0;
}

.galleries-page .gallery-image-edit-form input,
.galleries-page .gallery-image-edit-form textarea {
  width: 100%;
}

.galleries-page .gallery-image-edit-form input[type="radio"] {
  width: auto;
}

.galleries-page .gallery-form-actions button {
  justify-self: auto;
}

.galleries-page .gallery-carousel-controls {
  justify-content: center;
}

.galleries-page .gallery-carousel-controls,
.galleries-page .gallery-carousel-help,
.galleries-page .gallery-carousel-slide figcaption {
  opacity: 1;
  transition: opacity 1s ease-in-out;
}

.galleries-page .gallery-carousel-view.carousel-chrome-hidden .gallery-carousel-controls,
.galleries-page .gallery-carousel-view.carousel-chrome-hidden .gallery-carousel-help,
.galleries-page .gallery-carousel-view.carousel-chrome-hidden .gallery-carousel-slide figcaption {
  opacity: 0;
  pointer-events: none;
}

.galleries-page .gallery-carousel-controls label {
  display: flex;
  gap: .5rem;
  align-items: center;
  font-weight: 600;
}

.galleries-page .gallery-carousel-controls input {
  width: 5rem;
  padding: .45rem;
}

.galleries-page .gallery-carousel-help {
  text-align: center;
}

.galleries-page .gallery-carousel {
  position: relative;
  height: min(70vh, 700px);
  min-height: 420px;
  overflow: hidden;
  background: #000;
}

.galleries-page .gallery-carousel-slide {
  position: absolute;
  z-index: 0;
  inset: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  margin: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease-in-out;
}

.galleries-page .gallery-carousel-slide.active {
  z-index: 1;
  opacity: 1;
  pointer-events: auto;
}

.galleries-page .gallery-carousel-slide > .gallery-image-viewer-trigger {
  width: 100%;
  height: 100%;
  min-height: 0;
  border-radius: 0;
  background: #000;
}

.galleries-page .gallery-carousel-slide figcaption {
  max-height: 35vh;
  padding: 1rem;
  overflow-y: auto;
  background: #000;
  color: #fff;
}

.galleries-page .gallery-carousel-slide figcaption h2 {
  margin-top: 0;
}

.galleries-page .gallery-carousel-slide figcaption .gallery-empty {
  color: #ddd;
}

.galleries-page.gallery-image-viewer-open {
  overflow: hidden;
}

.galleries-page .gallery-image-viewer {
  position: fixed;
  z-index: 2000;
  inset: 0;
  display: grid;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  place-items: center;
  background: #000;
  cursor: none;
  outline: none;
}

.galleries-page .gallery-image-viewer-content {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  width: 100%;
  height: 100%;
}

.galleries-page .gallery-image-viewer img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
}

.galleries-page .gallery-image-viewer-metadata {
  padding: .75rem 1rem;
  background: #000;
  color: #fff;
}

.galleries-page .gallery-image-viewer-metadata h2 {
  margin: 0 0 .5rem;
}

.galleries-page .gallery-image-viewer-metadata dl {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem 1.5rem;
  margin: 0;
}

.galleries-page .gallery-image-viewer-metadata dl > div {
  display: flex;
  gap: .4rem;
}

.galleries-page .gallery-image-viewer-metadata dt {
  font-weight: 700;
}

.galleries-page .gallery-image-viewer-metadata dd {
  margin: 0;
}

.galleries-page .gallery-management {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 2px solid #7d0000;
}

.galleries-page .gallery-management form {
  width: min(100%, 40rem);
  gap: 1rem;
}

.galleries-page #gallery-upload-metadata {
  display: grid;
  gap: 1rem;
}

.galleries-page #gallery-upload-metadata textarea {
  min-height: 5rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 700px) {
  .settings-page .activity-images,
  .settings-page .testimonials,
  .settings-page .meeting-cards {
    grid-template-columns: 1fr;
  }

  .reliquary-page .reliquary-detail {
    grid-template-columns: 1fr;
  }

  .reliquary-page .reliquary-detail > div:first-child {
    max-width: 300px;
  }

  .galleries-page .gallery-list-card,
  .galleries-page .gallery-image-list-item {
    grid-template-columns: 1fr;
  }

  .galleries-page .gallery-list-card > a,
  .galleries-page .gallery-image-list-item > .gallery-image-viewer-trigger {
    width: min(100%, 320px);
  }
}

@media (max-width: 600px) {
  .home-page .upcoming-meetings {
    grid-template-columns: 1fr;
  }

  .home-page .upcoming-meeting + .upcoming-meeting {
    border-top: 1px solid #bbb;
    border-left: 0;
  }

  .home-page .activities {
    grid-template-columns: 1fr;
  }

  .calendar-view-switcher {
    grid-template-columns: 1fr auto;
  }

  .calendar-view-options {
    grid-column: 1 / -1;
    justify-self: center;
  }

  .calendar-view-switcher .calendar-add-post {
    grid-column: 2;
    grid-row: 2;
  }

  .calendar-controls {
    grid-template-columns: 1fr 1fr;
  }

  .calendar-controls h1 {
    grid-column: 1 / -1;
    grid-row: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-navigation a.selected {
    animation: none;
  }

  .galleries-page .gallery-carousel-slide {
    transition: none;
  }

  .galleries-page .gallery-carousel-controls,
  .galleries-page .gallery-carousel-help,
  .galleries-page .gallery-carousel-slide figcaption {
    transition: none;
  }
}
