.hero-statement {
  max-width: 980px;
  margin: 26px 0 0;
  padding: 16px 20px;
  border: 3px solid #17343e;
  border-radius: 8px;
  background: #fff;
  color: #49646c;
  font-size: clamp(18px, 2vw, 24px);
  line-height: 1.45;
}

.hero-statement strong {
  color: #e86c50;
  font-weight: 700;
}

.hero-statement .bottom-line-label {
  color: #17343e;
}

.hero-statement .real-wage-label {
  color: #008b87;
}

.hero-statement .productivity-label {
  color: #ebc568;
}

.hero-statement .bottom-line-symbol {
  color: #e86c50;
}

.concepts-accordion {
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid #cfe0e2;
  border-radius: 16px;
  background: #fff;
}

.concepts-accordion summary strong {
  font-weight: 400;
}

.hero-statement + .concepts-accordion {
  margin-top: 32px;
}

.hero {
  padding-bottom: 32px;
}

.concepts-accordion summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 22px;
  color: #17343e;
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.35;
  cursor: pointer;
  list-style: none;
}

.concepts-accordion summary::-webkit-details-marker {
  display: none;
}

.concepts-accordion summary span {
  flex: 0 0 auto;
  color: #008b87;
  font-size: 30px;
  line-height: 1;
  transition: transform 0.2s;
}

.concepts-accordion[open] > summary span,
.worked-example-accordion[open] > summary span {
  transform: rotate(45deg);
}

.concepts-copy {
  max-width: 980px;
  padding: 0 22px 22px;
  color: #49646c;
  font-size: 16px;
  line-height: 1.65;
}

.concepts-copy p {
  margin: 0 0 16px;
}

.concepts-copy p:last-child {
  margin-bottom: 0;
}

.concepts-copy strong {
  color: #17343e;
}

.worked-example-accordion {
  margin-top: 24px;
  padding: 0;
  border: 1px solid #c8dfe1;
  border-radius: 8px;
  background: #f8fbfb;
}

.worked-example-accordion > summary {
  padding: 16px 18px;
  font-size: 18px;
}

.concepts-accordion summary:focus-visible {
  outline: 3px solid #008b87;
  outline-offset: -4px;
  border-radius: 8px;
}

.worked-example-copy {
  padding: 0 18px 20px;
}

.worked-example-intro {
  display: flow-root;
}

.worked-example-image {
  float: right;
  display: block;
  width: 30%;
  height: auto;
  margin: 0 0 16px 24px;
  border-radius: 10px;
}

.worked-example-intro > h4:first-of-type {
  margin-top: 0;
}

@media (max-width: 640px) {
  .worked-example-image {
    margin-left: 16px;
  }
}

.worked-example-copy h3 {
  margin: 8px 0 24px;
  color: #17343e;
  font-size: 22px;
  line-height: 1.4;
}

.worked-example-copy h4 {
  margin: 24px 0 12px;
  color: #17343e;
  font-size: 17px;
}

.worked-example-copy ul {
  margin: 0 0 20px;
  padding-left: 24px;
}

.worked-example-copy li + li {
  margin-top: 10px;
}

.worked-example-copy ul:last-child {
  margin-bottom: 0;
}

.measure-title,
.earnings-measure-title {
  margin-top: 4px !important;
}

.housing-section {
  margin: 72px 0 34px;
}

.housing-intro-hero {
  padding: 0 0 34px;
}

.housing-intro-hero h2 {
  max-width: 1120px;
  margin: 12px 0 20px;
  color: #17343e;
  font-size: clamp(38px, 5.4vw, 70px);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.housing-intro-hero p {
  max-width: 1050px;
  margin: 0;
  color: #49646c;
  font-size: 18px;
  line-height: 1.55;
}

.housing-hero {
  display: grid;
  grid-template-columns: minmax(250px, 0.8fr) minmax(0, 1.4fr);
  margin-top: 22px;
  overflow: hidden;
  border-radius: 16px;
  background: #1d3843;
  color: #fff;
}

.housing-hero-heading {
  padding: 30px 32px;
  background: #317d78;
}

.housing-hero-heading .kicker {
  color: #d8f1ef;
}

.housing-hero-heading h2 {
  margin: 8px 0 12px;
  color: #fff;
  font-size: clamp(25px, 3vw, 36px);
  line-height: 1.12;
}

.housing-hero-heading p,
.housing-hero-result p {
  margin: 0;
  color: #fff;
  font-size: 17px;
  line-height: 1.58;
}

.housing-hero-result {
  padding: 30px 36px;
}

.housing-hero-result h3 {
  margin: 0 0 12px;
  color: #fff;
  font-size: 21px;
}

.housing-hero-result strong {
  color: #efc567;
}

.accordion-chart-heading {
  margin: 24px 0 8px;
  color: #17343e;
  font-size: 17px;
  line-height: 1.35;
}

.jurisdiction-housing-section {
  padding-top: 72px;
}

.jurisdiction-intro-hero {
  padding: 0 0 30px;
}

.jurisdiction-intro-hero h2 {
  max-width: 1200px;
  margin: 12px 0 18px;
  color: #17343e;
  font-size: clamp(38px, 5vw, 66px);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.jurisdiction-intro-hero p {
  max-width: 1080px;
  margin: 0;
  color: #49646c;
  font-size: 18px;
  line-height: 1.55;
}

.jurisdiction-selector {
  margin: 8px 0 16px;
}

.jurisdiction-selector-label,
.jurisdiction-measure-title {
  margin-bottom: 12px;
  color: #17343e;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.jurisdiction-tabs {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 6px;
}

.jurisdiction-tabs button {
  min-height: 44px;
  border: 1px solid #b8d0d3;
  border-radius: 8px;
  background: #fff;
  color: #294c59;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.jurisdiction-tabs button[aria-selected='true'] {
  border-color: #008b87;
  background: #008b87;
  color: #fff;
}

.jurisdiction-tabs button:focus-visible {
  outline: 3px solid #008b8755;
  outline-offset: 2px;
}

.jurisdiction-mobile-select {
  display: none;
}

.jurisdiction-snapshot {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 18px 0 22px;
}

.jurisdiction-snapshot-card {
  padding: 20px 22px;
  border: 1px solid #cfe0e2;
  border-top: 4px solid #e86c50;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 30px #17343e12;
}

.jurisdiction-snapshot-year {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 12px;
  align-items: center;
  margin-bottom: 18px;
}

.jurisdiction-snapshot-year b {
  color: #008b87;
  font-size: 17px;
  letter-spacing: 0.08em;
}

.jurisdiction-snapshot-year em {
  padding: 4px 8px;
  border-radius: 999px;
  background: #eaf4f5;
  color: #294c59;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.jurisdiction-snapshot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  gap: 18px;
}

.jurisdiction-snapshot-metric,
.jurisdiction-snapshot-share {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.jurisdiction-snapshot-metric small,
.jurisdiction-snapshot-share small {
  color: #607980;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.jurisdiction-snapshot-metric strong,
.jurisdiction-snapshot-share strong {
  margin-top: 5px;
  color: #17343e;
  font-size: clamp(20px, 2.2vw, 25px);
  line-height: 1.2;
  white-space: nowrap;
}

.jurisdiction-snapshot-share strong {
  color: #008b87;
}

.jurisdiction-snapshot-share strong + small {
  margin-top: 2px;
}

.jurisdiction-explorer {
  display: grid;
  grid-template-columns: 290px minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid #cfe0e2;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 55px #17343e16;
}

.jurisdiction-controls {
  padding: 26px;
  background: #eaf4f5;
}

.jurisdiction-check {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 11px;
  align-items: center;
  margin: 15px 0;
  color: var(--jurisdiction-colour);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.28;
}

.jurisdiction-check input {
  width: 27px;
  height: 27px;
  margin: 0;
  border: 2px solid var(--jurisdiction-colour);
  border-radius: 7px;
  appearance: none;
  background: #fff;
}

.jurisdiction-check input:checked {
  background: var(--jurisdiction-colour);
}

.jurisdiction-check input:checked::after {
  display: block;
  color: #fff;
  font-size: 19px;
  line-height: 23px;
  text-align: center;
  content: '\2713';
}

.jurisdiction-check input:focus-visible,
.jurisdiction-start select:focus-visible,
.jurisdiction-mobile-select select:focus-visible {
  outline: 3px solid #008b8755;
  outline-offset: 2px;
}

.jurisdiction-start {
  display: block;
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid #c8dfe1;
  color: #17343e;
  font-weight: 800;
}

.jurisdiction-start select,
.jurisdiction-mobile-select select {
  display: block;
  width: 100%;
  margin: 8px 0 6px;
  padding: 10px;
  border: 2px solid #294c59;
  border-radius: 8px;
  background: #fff;
  color: #17343e;
  font-weight: 700;
}

.jurisdiction-start small {
  display: block;
  color: #49646c;
  font-weight: 400;
  line-height: 1.35;
}

.jurisdiction-panel {
  min-width: 0;
  padding: 30px 32px;
}

.jurisdiction-chart-title {
  display: flex;
  gap: 18px;
  align-items: end;
  justify-content: space-between;
}

.jurisdiction-chart-title h2 {
  margin: 8px 0 0;
  color: #17343e;
  font-size: clamp(23px, 3vw, 34px);
  line-height: 1.15;
}

.jurisdiction-chart-title span {
  flex: 0 0 auto;
  color: #607980;
  font-size: 13px;
  font-weight: 700;
}

.jurisdiction-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  margin: 18px 0 4px;
  color: #49646c;
  font-size: 12px;
  font-weight: 700;
}

.jurisdiction-legend i {
  display: inline-block;
  width: 20px;
  height: 4px;
  margin-right: 6px;
  border-radius: 4px;
  vertical-align: middle;
}

.jurisdiction-legend i.dashed {
  height: 0;
  border-top: 3px dashed currentColor;
  background: transparent !important;
}

#jurisdiction-chart {
  display: block;
  width: 100%;
  height: 400px;
}

.jurisdiction-source {
  margin: 8px 0 0;
  padding-top: 12px;
  border-top: 1px solid #dce8ea;
  color: #607980;
  font-size: 12px;
  line-height: 1.5;
}

.jurisdiction-summary-card {
  display: grid;
  grid-template-columns: minmax(260px, 0.7fr) minmax(0, 1.5fr);
  margin-top: 22px;
  overflow: hidden;
  border-radius: 16px;
  background: #1d3843;
  color: #fff;
}

.jurisdiction-summary-card > div {
  padding: 28px 32px;
  background: #317d78;
}

.jurisdiction-summary-card h3 {
  margin: 0;
  color: #fff;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.15;
}

.jurisdiction-summary-card p {
  margin: 0;
  padding: 28px 36px;
  color: #fff;
  font-size: 16px;
  line-height: 1.65;
}

.jurisdiction-summary-card strong {
  color: #efc567;
}

.housing-snapshot {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 18px 0 0;
}

.housing-snapshot-card {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 18px;
  padding: 18px 20px;
  border: 1px solid #cfe0e2;
  border-top: 4px solid #e86c50;
  border-radius: 12px;
  background: #fff;
  color: #17343e;
  box-shadow: 0 10px 30px #17343e12;
}

.housing-snapshot-card > span {
  grid-column: 1 / -1;
  color: #008b87;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.housing-snapshot-card div {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.housing-snapshot-card small {
  min-height: 31px;
  color: #607980;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
}

.housing-snapshot-card strong {
  color: #17343e;
  font-size: clamp(19px, 2.3vw, 25px);
  line-height: 1.2;
  white-space: nowrap;
}

.housing-snapshot-card .housing-share strong {
  color: #008b87;
}

.housing-snapshot-card .housing-share > small:first-child {
  min-height: auto;
  margin-bottom: 2px;
}

.housing-snapshot-card .housing-share-caption {
  min-height: auto;
  margin-top: 2px;
}

.housing-explorer {
  display: grid;
  grid-template-columns: 290px minmax(0, 1fr);
  margin: 22px 0 0;
  overflow: hidden;
  border: 1px solid #cfe0e2;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 55px #17343e16;
}

.housing-controls {
  padding: 26px;
  background: #eaf4f5;
}

.housing-measure-title {
  margin: 4px 0 14px;
  color: #17343e;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.housing-check {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 11px;
  align-items: center;
  margin: 15px 0;
  color: var(--housing-colour);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.28;
}

.housing-check input {
  width: 27px;
  height: 27px;
  margin: 0;
  border: 2px solid var(--housing-colour);
  border-radius: 7px;
  appearance: none;
  background: #fff;
}

.housing-check input:checked {
  background: var(--housing-colour);
}

.housing-check input:checked::after {
  display: block;
  color: #fff;
  font-size: 19px;
  line-height: 23px;
  text-align: center;
  content: '\2713';
}

.housing-check input:focus-visible,
.housing-start select:focus-visible {
  outline: 3px solid #ebc568;
  outline-offset: 2px;
}

.housing-start {
  display: block;
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid #c8dfe1;
  color: #17343e;
  font-weight: 800;
}

.housing-start select {
  display: block;
  width: 100%;
  margin: 8px 0 6px;
  padding: 10px;
  border: 2px solid #294c59;
  border-radius: 7px;
  background: #fff;
  color: #17343e;
  font: inherit;
}

.housing-start small {
  color: #607980;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
}

.housing-panel {
  min-width: 0;
  padding: 26px 32px 20px;
}

.housing-chart-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin: 14px 0 4px;
}

.housing-chart-title h2 {
  max-width: 680px;
  margin: 0;
  color: #17343e;
  font-size: clamp(22px, 2.6vw, 30px);
  line-height: 1.18;
}

.housing-chart-title > span {
  flex: 0 0 auto;
  color: #607980;
  font-size: 13px;
  font-weight: 800;
}

.housing-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  min-height: 29px;
  margin: 14px 0 0;
  color: #49646c;
  font-size: 13px;
  font-weight: 700;
}

.housing-legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.housing-legend i {
  display: inline-block;
  width: 24px;
  height: 3px;
  border-radius: 2px;
}

.housing-legend i.dashed {
  height: 0;
  border-top: 3px dashed currentColor;
  background: transparent !important;
}

#housing-chart {
  display: block;
  width: 100%;
  height: 420px;
}

.housing-source {
  margin: 10px 0 0;
  color: #607980;
  font-size: 12px;
  line-height: 1.5;
}

.housing-source a {
  color: #008b87;
  font-weight: 700;
}

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

@media (max-width: 820px) {
  .housing-hero,
  .housing-explorer,
  .jurisdiction-explorer,
  .jurisdiction-summary-card {
    grid-template-columns: 1fr;
  }

  .jurisdiction-tabs {
    display: none;
  }

  .jurisdiction-mobile-select {
    display: block;
    color: #17343e;
    font-weight: 800;
  }

  .jurisdiction-mobile-select select {
    max-width: 420px;
  }

  .jurisdiction-snapshot {
    grid-template-columns: 1fr;
  }

  .housing-snapshot {
    grid-template-columns: 1fr;
  }

  .housing-panel {
    padding: 24px 18px 18px;
  }
}

@media (max-width: 520px) {
  main,
  .hero > div,
  .controls,
  .earnings-controls,
  .housing-controls,
  .jurisdiction-controls {
    min-width: 0;
  }

  main select {
    min-height: 44px;
    max-width: 100%;
    font-size: 16px;
  }

  .check,
  .earnings-check,
  .housing-check,
  .jurisdiction-check {
    min-height: 44px;
    align-items: center;
  }

  .legend > span,
  .earnings-legend > span,
  .housing-legend > span,
  .jurisdiction-legend > span {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .source,
  .earnings-source,
  .housing-source,
  .jurisdiction-source {
    overflow-wrap: anywhere;
  }

  .earnings-snapshot,
  .jurisdiction-snapshot-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .housing-intro-hero h2 {
    font-size: clamp(36px, 11vw, 52px);
  }

  .housing-hero-heading,
  .housing-hero-result {
    padding: 24px 22px;
  }

  .housing-snapshot-card {
    grid-template-columns: 1fr;
  }

  .housing-snapshot-card small {
    min-height: auto;
  }

  .housing-chart-title {
    display: block;
  }

  .jurisdiction-chart-title {
    display: block;
  }

  .jurisdiction-chart-title span {
    display: block;
    margin-top: 8px;
  }

  .jurisdiction-panel {
    padding: 24px 20px;
  }

  .jurisdiction-summary-card p,
  .jurisdiction-summary-card > div {
    padding: 24px 22px;
  }

  .housing-chart-title > span {
    display: block;
    margin-top: 8px;
  }

  #housing-chart {
    height: 360px;
  }
}
