/* Bootstrap 3-era class shims for Bootstrap 5.
   Keeps existing template markup/styles working after upgrading Bootstrap. */

/* BS3 caret (used in dropdown toggles) */
.caret {
  display: inline-block;
  width: 0;
  height: 0;
  margin-left: 4px;
  vertical-align: middle;
  border-top: 4px solid currentColor;
  border-right: 4px solid transparent;
  border-left: 4px solid transparent;
}

/* BS3 navbar toggle bars */
.navbar-toggle {
  display: inline-block;
  padding: 9px 10px;
  margin: 8px 15px 8px 0;
  background-color: transparent;
  background-image: none;
  border: 1px solid transparent;
  border-radius: 4px;
}

.navbar-toggle:focus {
  outline: 0;
}

.navbar-toggle .icon-bar {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: 1px;
}

.navbar-toggle .icon-bar + .icon-bar {
  margin-top: 4px;
}

/* BS3 screen-reader helper alias */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* Bootstrap 5 uses `.show` instead of BS3 `.open` to display dropdown menus. */
.dropdown-menu.show {
  display: block;
}

/* Bootstrap 5 tabs use `.nav-link.active` instead of `li.active > a`. Keep legacy selectors working. */
.nav-tabs > li > a.nav-link {
  display: block;
}

.nav-tabs > li.active > a,
.nav-tabs > li > a.nav-link.active {
  color: inherit;
}

/* Template-specific: keep existing `.recent-events` tab styling when BS5 toggles `.active` on the link. */
.recent-events .nav-tabs > li > a.nav-link.active,
.recent-events .nav-tabs > li > a.nav-link.active:focus,
.recent-events .nav-tabs > li > a.nav-link.active:hover {
  color: #222;
  cursor: default;
  background-color: #f7f7f7;
  border: 0px solid #ddd;
}

/* BS3 panel component (used by older accordions/FAQs markup) */
.panel {
  margin-bottom: 20px;
  background-color: #fff;
  border: 1px solid transparent;
  border-radius: 4px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
}

.panel-body {
  padding: 15px;
}

.panel-heading {
  padding: 10px 15px;
  border-bottom: 1px solid transparent;
  border-top-left-radius: 3px;
  border-top-right-radius: 3px;
}

.panel-title {
  margin: 0;
  font-size: 16px;
}

.panel-default {
  border-color: #ddd;
}

.panel-default > .panel-heading {
  color: #333;
  background-color: #f5f5f5;
  border-color: #ddd;
}

.panel-group {
  margin-bottom: 20px;
}

.panel-group .panel {
  margin-bottom: 0;
  border-radius: 4px;
}

.panel-group .panel + .panel {
  margin-top: 5px;
}

/* BS4 responsive embeds (removed in BS5) */
.embed-responsive {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  overflow: hidden;
}

.embed-responsive::before {
  display: block;
  content: "";
}

.embed-responsive .embed-responsive-item,
.embed-responsive iframe,
.embed-responsive embed,
.embed-responsive object,
.embed-responsive video {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.embed-responsive-21by9::before {
  padding-top: 42.857143%;
}

.embed-responsive-16by9::before {
  padding-top: 56.25%;
}

.embed-responsive-4by3::before {
  padding-top: 75%;
}

.embed-responsive-1by1::before {
  padding-top: 100%;
}

/* Remove template background pattern that becomes visually distracting under BS5 spacing */
.h2-local-brands {
  background: none !important;
}
