/**
 * Trends page (township-based design).
 */
.trends-page {
  font-family: "Sofia Pro", Arial, sans-serif;
  color: #2A2A2A;
}
.trends-page .color-red {
  color: #B60926;
}
.trends-page .color-green {
  color: #1E7D34;
}
.trends-page .trends-empty {
  margin: 30px 0 10px;
  font-size: 16px;
  color: #8A8A8A;
}
.trends-page .trends-hero {
  position: relative;
  min-height: 420px;
  background-size: cover;
  background-position: 50% 50%;
  background-repeat: no-repeat;
  display: flex;
}
.trends-page .trends-hero__overlay {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px 90px;
}
.trends-page .trends-hero__text {
  max-width: 720px;
  text-align: center;
  color: #fff;
}
.trends-page .trends-hero__title {
  font-size: 46px;
  font-weight: 700;
  margin: 0 0 16px;
  color: #fff;
}
.trends-page .trends-hero__subtitle {
  font-size: 16px;
  line-height: 1.5;
  margin: 0;
  color: #fff;
}
.trends-page .trends-container {
  max-width: 1110px;
  margin: 0 auto;
  padding: 0 15px 60px;
}
.trends-page .trends-search {
  display: flex;
  gap: 20px;
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
  padding: 20px;
  margin: -55px 0 40px;
  position: relative;
  z-index: 2;
}
.trends-page .trends-search__field {
  flex: 1;
  display: flex;
  border: 1px solid #E7E7EC;
  border-radius: 3px;
  overflow: hidden;
}
.trends-page .trends-search__input {
  flex: 1;
  border: 0;
  padding: 14px 18px;
  font-size: 16px;
  font-family: "Sofia Pro", Arial, sans-serif;
  outline: none;
  color: #2A2A2A;
}
.trends-page .trends-search__btn {
  border: 0;
  background: #1B2B79;
  color: #fff;
  width: 56px;
  cursor: pointer;
  font-size: 16px;
}
.trends-page .trends-search__sort {
  display: flex;
}
.trends-page .trends-search__select {
  border: 1px solid #E7E7EC;
  border-radius: 3px;
  padding: 14px 40px 14px 18px;
  font-size: 15px;
  font-family: "Sofia Pro", Arial, sans-serif;
  color: #2A2A2A;
  background-color: #fff;
  cursor: pointer;
  min-width: 260px;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%232A2A2A' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}
.trends-page .trends-listing__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 22px;
}
.trends-page .trends-listing__title {
  font-size: 24px;
  font-weight: 700;
  margin: 0;
}
.trends-page .trends-listing__count {
  color: #8A8A8A;
  font-size: 14px;
}
.trends-page .trends-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 26px;
}
.trends-page .trend-card {
  border: 1px solid #E7E7EC;
  border-radius: 6px;
  padding: 22px 24px 18px;
  background: #fff;
  display: flex;
  flex-direction: column;
}
.trends-page .trend-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
.trends-page .trend-card__name {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 8px;
  min-width: 0;
}
.trends-page .trend-card__township {
  font-size: 22px;
  font-weight: 700;
}
.trends-page .trend-card__pill {
  display: inline-block;
  background: #E9ECF1;
  color: #4a4a4a;
  font-size: 12px;
  letter-spacing: 0.3px;
  padding: 4px 10px;
  border-radius: 3px;
  white-space: nowrap;
}
.trends-page .trend-card__pill-short {
  display: none;
}
.trends-page .trend-card__stats {
  display: flex;
  margin-top: 18px;
}
.trends-page .trend-card__chart {
  margin-top: 22px;
  flex: 1 0 auto;
}
.trends-page .trend-card__chart-title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.trends-page .trend-card__chart-empty {
  margin: 0;
  padding: 24px 0;
  font-size: 14px;
  color: #8A8A8A;
}
.trends-page .trend-card__details {
  display: block;
  width: 100%;
  text-align: center;
  background: #fff;
  border: 1px solid #E7E7EC;
  border-radius: 3px;
  color: #1B2B79;
  font-size: 15px;
  padding: 12px;
  margin-top: 20px;
  cursor: pointer;
  transition: background 0.15s ease;
}
.trends-page .trend-card__details:hover {
  background: #f6f7fb;
}
.trends-page .trend-card__more {
  display: inline-block;
  color: #B60926;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #E7E7EC;
}
.trends-page .trend-card__more i {
  margin-right: 6px;
}
.trends-page .trend-card__more:hover {
  color: #B60926;
  text-decoration: none;
}
.trends-page .trend-badge {
  flex: 0 0 auto;
  font-size: 14px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 3px;
}
.trends-page .trend-badge.is-rising {
  color: #B60926;
  background: #FCE8EA;
}
.trends-page .trend-badge.is-falling {
  color: #1E7D34;
  background: #E5F3E9;
}
.trends-page .trend-badge.is-stable {
  color: #1B2B79;
  background: #EEF0F7;
}
.trends-page .trend-stat {
  flex: 1;
}
.trends-page .trend-stat--change {
  padding-left: 24px;
  margin-left: 24px;
  border-left: 1px solid #E7E7EC;
}
.trends-page .trend-stat__label {
  font-size: 15px;
  color: #2A2A2A;
  margin-bottom: 6px;
}
.trends-page .trend-stat__value {
  font-size: 26px;
  font-weight: 700;
  line-height: 1.1;
}
.trends-page .trend-stat__note {
  font-size: 13px;
  color: #8A8A8A;
  margin-top: 4px;
}
.trends-page .trend-bars {
  margin-bottom: 8px;
}
.trends-page .trend-bar {
  display: flex;
  align-items: center;
  height: 30px;
}
.trends-page .trend-bar__year {
  flex: 0 0 42px;
  font-size: 14px;
  color: #2A2A2A;
}
.trends-page .trend-bar__track {
  flex: 1;
  display: flex;
  align-items: center;
  height: 100%;
  border-left: 1px solid #C9C9D4;
  padding-left: 0;
  position: relative;
}
.trends-page .trend-bar__fill {
  display: block;
  height: 18px;
  width: 0;
  background: #E4E4F0;
  border-radius: 0 2px 2px 0;
}
.trends-page .trend-bar__fill.is-peak {
  background: #B60926;
}
.trends-page .trend-bar__value {
  margin-left: 8px;
  font-size: 13px;
  color: #2A2A2A;
  background: #fff;
  border: 1px solid #E7E7EC;
  border-radius: 3px;
  padding: 1px 7px;
  white-space: nowrap;
}
.trends-page .trend-axis {
  display: flex;
  justify-content: space-between;
  padding-left: 42px;
  border-top: 1px solid #C9C9D4;
  padding-top: 6px;
}
.trends-page .trend-axis__tick {
  font-size: 12px;
  color: #8A8A8A;
}
.trends-page .trends-pagination {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 45px;
}
.trends-page .trends-pagination__item {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: #EEF0F7;
  color: #1B2B79;
  font-size: 15px;
  text-decoration: none;
}
.trends-page .trends-pagination__item.is-active {
  background: #1B2B79;
  color: #fff;
}
.trends-page .trends-pagination__item:hover {
  text-decoration: none;
}
@media screen and (max-width: 992px) {
  .trends-page .trends-hero {
    min-height: 300px;
  }
  .trends-page .trends-hero__title {
    font-size: 32px;
  }
  .trends-page .trends-search {
    flex-direction: column;
    gap: 14px;
    margin-top: -40px;
  }
  .trends-page .trends-search__select {
    min-width: 0;
    width: 100%;
  }
  .trends-page .trends-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}
@media screen and (max-width: 640px) {
  .trends-page .trend-card__pill-long {
    display: none;
  }
  .trends-page .trend-card__pill-short {
    display: inline;
  }
  .trends-page .trend-card__stats {
    flex-direction: column;
  }
  .trends-page .trend-stat--change {
    padding-left: 0;
    margin-left: 0;
    border-left: 0;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #E7E7EC;
  }
  .trends-page .trend-stat {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-areas: "label value" "note value";
    column-gap: 12px;
    align-items: center;
  }
  .trends-page .trend-stat__label {
    grid-area: label;
    margin-bottom: 2px;
  }
  .trends-page .trend-stat__value {
    grid-area: value;
    align-self: center;
    text-align: right;
  }
  .trends-page .trend-stat__note {
    grid-area: note;
    margin-top: 0;
  }
}

.trends-modal {
  font-family: "Sofia Pro", Arial, sans-serif;
  color: #2A2A2A;
}
.trends-modal .modal-content {
  border: 0;
  border-radius: 0;
  overflow: hidden;
}
.trends-modal__header {
  background: #F0F1F4;
  border: 0;
  padding: 22px 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.trends-modal__title {
  font-size: 26px;
  font-weight: 700;
  margin: 0;
}
.trends-modal__close {
  border: 0;
  background: transparent;
  color: #8A8A8A;
  font-size: 22px;
  cursor: pointer;
  line-height: 1;
}
.trends-modal__body {
  padding: 0 30px 30px;
}
.trends-modal .trends-tabs {
  display: flex;
  list-style: none;
  padding: 0;
  border: 1px solid #E7E7EC;
  border-radius: 4px;
  overflow: hidden;
  margin: 24px 0 28px;
}
.trends-modal .trends-tabs__item {
  flex: 1;
  display: flex;
  margin-bottom: 0;
}
.trends-modal .trends-tabs__link {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 10px;
  font-size: 16px;
  color: #2A2A2A;
  background: #fff;
  text-decoration: none;
}
.trends-modal .trends-tabs__link + .trends-modal .trends-tabs__link {
  border-left: 1px solid #E7E7EC;
}
.trends-modal .trends-tabs__link.active {
  background: #E4E5F3;
  font-weight: 600;
}
.trends-modal .trends-tabs__link:hover {
  text-decoration: none;
}
.trends-modal .trends-tabs__item + .trends-tabs__item .trends-tabs__link {
  border-left: 1px solid #E7E7EC;
}
.trends-modal .trends-section {
  margin-bottom: 30px;
}
.trends-modal .trends-section__title,
.trends-modal .trends-cmp__title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 16px;
  display: inline-flex;
  align-items: center;
}
.trends-modal .trends-help {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #1B2B79;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  margin-left: 6px;
}
.trends-modal .trends-help[data-tip] {
  position: relative;
  cursor: help;
  outline: none;
}
.trends-modal .trends-help[data-tip]::after {
  content: attr(data-tip);
  position: absolute;
  left: 0;
  bottom: calc(100% + 8px);
  width: 240px;
  max-width: 72vw;
  padding: 9px 11px;
  background: #2A2A2A;
  color: #fff;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.45;
  letter-spacing: 0;
  text-transform: none;
  text-align: left;
  white-space: normal;
  border-radius: 5px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.22);
  opacity: 0;
  visibility: hidden;
  transform: translateY(4px);
  transition: opacity 0.12s ease, transform 0.12s ease;
  pointer-events: none;
  z-index: 30;
}
.trends-modal .trends-help[data-tip]:hover::after, .trends-modal .trends-help[data-tip]:focus::after, .trends-modal .trends-help[data-tip].is-open::after {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.trends-modal .trends-metrics {
  display: flex;
  gap: 40px;
}
.trends-modal .trends-metric {
  display: flex;
  flex-direction: column;
}
.trends-modal .trends-metric__value {
  font-size: 30px;
  font-weight: 700;
  line-height: 1;
}
.trends-modal .trends-metric__unit {
  font-size: 15px;
  font-weight: 400;
  margin-left: 4px;
}
.trends-modal .trends-metric__note {
  color: #8A8A8A;
  font-size: 15px;
  margin-top: 8px;
}
.trends-modal .trends-types {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.trends-modal .trends-type {
  border: 1px solid #E7E7EC;
  border-radius: 4px;
  padding: 9px 14px;
  font-size: 15px;
}
.trends-modal .trends-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 34px;
}
.trends-modal .trends-feature__row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}
.trends-modal .trends-feature__label {
  font-size: 15px;
}
.trends-modal .trends-feature__pct {
  font-size: 15px;
  font-weight: 700;
}
.trends-modal .trends-feature__track {
  display: block;
  width: 100%;
  height: 6px;
  background: #E4E4F0;
  border-radius: 3px;
  overflow: hidden;
}
.trends-modal .trends-feature__fill {
  display: block;
  height: 100%;
  width: 0;
  background: #B60926;
  border-radius: 3px;
}
.trends-modal .trends-cmp {
  margin-bottom: 30px;
}
.trends-modal .trends-cmp__head {
  display: flex;
  align-items: flex-end;
  padding-bottom: 10px;
}
.trends-modal .trends-cmp__title {
  flex: 1;
  margin-bottom: 0;
}
.trends-modal .trends-cmp__col {
  flex: 0 0 22%;
  text-align: right;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: #2A2A2A;
}
.trends-modal .trends-cmp__row {
  display: flex;
  align-items: center;
  padding: 14px 0;
  border-top: 1px solid #E7E7EC;
}
.trends-modal .trends-cmp__label {
  flex: 1;
  font-size: 16px;
}
.trends-modal .trends-cmp__town,
.trends-modal .trends-cmp__county {
  flex: 0 0 22%;
  text-align: right;
  font-size: 16px;
  font-weight: 700;
}
.trends-modal .trends-cmp__arrow {
  display: inline-block;
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  margin-right: 5px;
  vertical-align: middle;
}
.trends-modal .trends-cmp__arrow.is-up {
  border-bottom: 7px solid #1B2B79;
}
.trends-modal .trends-cmp__arrow.is-down {
  border-top: 7px solid #1B2B79;
}
.trends-modal .trends-cmp__bar {
  margin-top: 6px;
  margin-left: auto;
  max-width: 90px;
}
.trends-modal .trends-cmp__pct {
  display: inline-block;
}
@media screen and (max-width: 640px) {
  .trends-modal__body {
    padding: 0 16px 20px;
  }
  .trends-modal__title {
    font-size: 20px;
  }
  .trends-modal .trends-tabs__link {
    font-size: 14px;
  }
  .trends-modal .trends-metrics {
    flex-direction: column;
    gap: 0;
  }
  .trends-modal .trends-metric {
    flex-direction: row-reverse;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid #E7E7EC;
  }
  .trends-modal .trends-metric__note {
    margin-top: 0;
  }
  .trends-modal .trends-features {
    grid-template-columns: 1fr;
  }
  .trends-modal .trends-cmp__col {
    flex-basis: 26%;
  }
  .trends-modal .trends-cmp__town,
.trends-modal .trends-cmp__county {
    flex-basis: 26%;
    font-size: 14px;
  }
  .trends-modal .trends-cmp__label {
    font-size: 14px;
  }
}
