/* TravelGraph — performance & a11y overrides (keep small) */

.back-top {
  border: 0;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.back-top::before {
  content: none;
}

.back-top .bi {
  font-size: 1.35rem;
  line-height: 1;
}

@media (max-width: 767.98px) {
  .back-top .bi {
    font-size: 1rem;
  }
}

#bd-theme {
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.tg-site-notices__item--test {
  color: #92400e;
}

[data-bs-theme="dark"] .tg-site-notices__item--test {
  color: #fcd34d;
}

.tg-site-notices__item--ai {
  color: #4338ca;
}

[data-bs-theme="dark"] .tg-site-notices__item--ai {
  color: #c7d2fe;
}

.hero-slide__media {
  object-fit: cover;
  object-position: center left;
}

.card > picture:has(> .hero-slide__media) {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.card > picture:has(> .hero-slide__media) > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center left;
}

/* Equal-height category cards (title may wrap to 2 lines) */
#categories .tns-item,
#categories .tiny-slider-inner > div {
  height: 100%;
}

.tg-category-card {
  justify-content: flex-start;
}

.tg-category-card__title {
  min-height: 2.75em;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  line-height: 1.35;
}

/* Theme dropdown carets used Font Awesome; use Bootstrap Icons instead */
.dropdown .dropdown-toggle::after {
  content: "\f282";
  font-family: bootstrap-icons !important;
  font-weight: normal !important;
  border: none;
  vertical-align: -0.125em;
}

.dropup .dropdown-toggle::after {
  content: "\f286";
  font-family: bootstrap-icons !important;
  font-weight: normal !important;
  border: none;
  vertical-align: -0.125em;
}

.dropstart .dropdown-toggle::before {
  content: "\f284";
  font-family: bootstrap-icons !important;
  font-weight: normal !important;
  border: none;
  vertical-align: -0.125em;
}

.dropend .dropdown-toggle::after {
  content: "\f285";
  font-family: bootstrap-icons !important;
  font-weight: normal !important;
  border: none;
  vertical-align: -0.125em;
}

/* Modern format <picture> inside scaled cards */
.card-img-scale-wrapper > picture,
.card-img-scale-wrapper picture {
  display: block;
  width: 100%;
  height: 100%;
}

.card-img-scale-wrapper > picture > img,
.card-img-scale-wrapper picture > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Theme toggle — brand purple, not warning/orange */
#bd-theme {
  color: var(--bs-primary) !important;
}

#bd-theme:hover,
#bd-theme:focus,
#bd-theme[aria-expanded="true"] {
  color: var(--bs-primary-text-emphasis, #392f98) !important;
}

#bd-theme .theme-icon-active {
  fill: currentColor;
}

/* Higher contrast meta text (places count, subtitles) — Bootstrap text-muted fails WCAG here */
.tg-meta-text {
  color: #495057;
}

[data-bs-theme="dark"] .tg-meta-text {
  color: #ced4da;
}
