.trade-complex {
  --complex-sale: #4a5fc1;
  --complex-lease: #237d73;
  display: grid;
  gap: 14px;
  min-width: 0;
  padding-top: 28px;
}

.complex-header { padding: 0 0 5px; }
.complex-back {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 38px;
  gap: 7px;
  color: var(--indigo);
  font-size: 13px;
  font-weight: 750;
  text-decoration: none;
}
.complex-back:hover { text-decoration: underline; }
.complex-title {
  color: var(--navy);
  margin: 4px 0;
  font-size: clamp(27px, 4vw, 46px);
  letter-spacing: -.045em;
  line-height: 1.27;
  overflow-wrap: anywhere;
}
.complex-header p { margin: 3px 0; color: var(--muted); }
.complex-header .complex-period { margin-top: 5px; font-size: 12px; }
.complex-quotes,
.complex-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 245px), 1fr));
  gap: 14px;
}
.complex-quote {
  display: grid;
  align-content: start;
  gap: 4px;
  min-width: 0;
  padding: 17px 18px;
  border-inline-start: 4px solid var(--complex-sale);
}
.complex-quote--lease { border-inline-start-color: var(--complex-lease); }
.complex-quote h2 { margin: 0; color: var(--muted); font-size: 13px; }
.complex-quote strong {
  color: var(--navy);
  font-size: clamp(22px, 3vw, 33px);
  letter-spacing: -.045em;
  line-height: 1.25;
  overflow-wrap: anywhere;
}
.complex-quote time { color: var(--muted); font-size: 12px; }
.complex-panel { min-width: 0; padding: 17px 18px; }
.complex-panel h2 { margin: 0; color: var(--navy); font-size: 19px; letter-spacing: -.025em; }
.complex-panel-title {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 15px;
}
.complex-panel-title > span,
.complex-panel-note { color: var(--muted); font-size: 12px; }
.complex-panel-note { margin: 4px 0 11px; }
.complex-info-list { margin: 9px 0 0; }
.complex-info-list > div {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px 14px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
}
.complex-info-list > div:last-child { border-bottom: 0; }
.complex-info-list dt { color: var(--muted); font-size: 13px; }
.complex-info-list dd {
  margin: 0;
  font-weight: 680;
  text-align: right;
  overflow-wrap: anywhere;
}
.complex-map-link { width: fit-content; margin-top: 10px; }

.complex-filter-panel { display: grid; gap: 12px; }
.complex-filter-group { display: grid; gap: 6px; min-width: 0; }
.complex-filter-group > span { color: var(--muted); font-size: 13px; font-weight: 730; }
.complex-filter-options { display: flex; flex-wrap: wrap; gap: 5px; }
.complex-filter-options a {
  padding: 7px 11px;
  border: 1px solid #dbe3f2;
  border-radius: 8px;
  color: #344665;
  font-size: 13px;
  font-weight: 680;
  text-decoration: none;
}
.complex-filter-options a:hover { border-color: #98a9d9; }
.complex-filter-options a small { display: block; margin-top: 1px; color: var(--muted); font-size: 11px; font-weight: 550; }
.complex-filter-options a[aria-current="true"] small { color: inherit; }
.complex-filter-options a[aria-current="true"] { border-color: #b9c6ed; background: #e9edfc; color: #263d91; }
.complex-filter-options a:focus-visible { outline: 2px solid #4157ac; outline-offset: 2px; }
.complex-history { overflow-x: auto; margin-top: 12px; }
.complex-chart-values { margin-top: 9px; }
.complex-chart-values summary { width: fit-content; color: var(--indigo); font-size: 12px; font-weight: 720; cursor: pointer; }
.complex-chart-values table { margin-top: 8px; }

.complex-ranks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 114px), 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.complex-ranks li { display: grid; gap: 1px; padding: 10px 11px; border: 1px solid #e1e7f2; border-radius: 8px; background: #f5f7fc; }
.complex-ranks span { color: var(--muted); font-size: 12px; font-weight: 750; overflow-wrap: anywhere; }
.complex-ranks strong { color: var(--indigo); font-size: 23px; line-height: 1.3; }
.complex-ranks small { color: var(--muted); font-size: 11px; }

.complex-history table { min-width: 450px; }
.complex-panel table { width: 100%; border-collapse: collapse; font-size: 13px; }
.complex-panel table :is(th, td) { padding: 8px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.complex-panel table :is(th, td):last-child { text-align: right; }
.complex-panel table thead th { background: #edf1fa; color: var(--navy); }
.complex-panel table tbody th { color: inherit; font-weight: 550; }
.complex-panel table tbody tr:last-child :is(th, td) { border-bottom: 0; }
.complex-panel > .empty { margin: 10px 0 0; }
.trade-complex > .data-note { margin: 0; }

@media (max-width: 680px) {
  .trade-complex { padding-top: 15px; }
  .complex-panel { padding: 14px 15px; }
  .complex-info-list > div { font-size: 13px; gap: 6px 10px; }
}
