main {max-width: 1220px;}
.impact-heading, .impact-section-head, .trace-heading {display: flex; align-items: center; justify-content: space-between; gap: 16px;}
.impact-heading {margin: 8px 0 22px;}
.impact-heading h1 {font-size: clamp(30px, 4vw, 43px); margin: 4px 0;}
.impact-heading p, .scope {color: var(--muted);}
.impact-heading p:not(.eyebrow) {max-width: 620px;}
.exports {display: flex; flex-wrap: wrap; gap: 8px;}
.exports button {font-weight: 600; background: white;}
.exports button:first-child {background: var(--lavender);}
button:disabled {opacity: .55; cursor: default;}
button, select, nav a, summary {min-height: 44px;}
nav a {display: inline-flex; align-items: center;}
.impact-top, .impact-lower {display: grid; grid-template-columns: minmax(250px, .85fr) minmax(0, 1.75fr); gap: 14px; margin-bottom: 14px;}
.impact-lower {grid-template-columns: 1.15fr 1fr; margin: 14px 0;}
.impact-panel {min-width: 0; padding: 20px; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; overflow-wrap: anywhere;}
.impact-panel h3 {margin: 16px 0 5px;}
fieldset {border: 0; padding: 0; margin: 0; min-width: 0;}
legend {font-size: 20px; font-weight: 700; letter-spacing: -.025em; padding: 0;}
.choice {padding: 9px 10px; margin-top: 8px; display: grid; grid-template-columns: 20px 1fr; column-gap: 9px; align-items: start; border: 1px solid var(--line); border-radius: 8px; cursor: pointer;}
.choice:has(:checked) {background: var(--soft); border-color: #a393b9;}
.choice input {min-height: 18px; height: 18px; width: 18px; margin: 3px 0; accent-color: #645373;}
.choice strong {font-size: 14px;}
.choice small {grid-column: 2; font-size: 13px; color: var(--muted);}
.scope {font-size: 13px; margin-top: 12px;}
.trace {background: linear-gradient(135deg, #fff 10%, #f7f5fb);}
.trace-heading {flex-wrap: wrap; justify-content: flex-start; gap: 8px;}
.trace-heading h2 {flex: 1;}
.trace-heading label, .filter {font-size: 13px; font-weight: 600;}
.trace-heading select {max-width: 100%; width: auto; min-width: 0;}
.path-steps {display: flex; flex-wrap: wrap; align-items: stretch; gap: 7px; list-style: none; margin: 16px 0; padding: 0;}
.path-steps li {flex: 1 1 100px; display: flex; flex-direction: column; gap: 3px; padding: 9px 10px; border: 1px solid var(--line); border-left: 3px solid #9984ae; border-radius: 7px; background: white; font-size: 14px;}
.path-steps .inferred {border-style: dashed; border-left-style: solid;}
.path-steps small, .type, .meta {color: var(--muted); font-size: 12px;}
.path-detail {font-size: 14px;}
details {margin-top: 12px; border-top: 1px solid var(--line);}
summary {display: list-item; padding: 11px 2px; font-size: 14px; cursor: pointer; font-weight: 600;}
summary:focus-visible {outline: 3px solid var(--outline); outline-offset: 2px;}
.impact-panel ul {margin: 4px 0 8px; padding-left: 21px;}
.impact-panel ul li {margin-bottom: 7px; font-size: 14px;}
.impact-section-head {margin-bottom: 10px;}
.filter {display: flex; align-items: center; gap: 8px;}
.filter select, .trace-heading select {font-size: 14px;}
.inventory {width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 14px;}
.inventory th, .inventory td {text-align: left; padding: 6px 10px; border-bottom: 1px solid #e5e1eb; vertical-align: middle;}
.inventory thead th {font-size: 12px; font-weight: 650; color: var(--muted); background: var(--bg);}
.inventory thead th:first-child {width: 50%;}
.inventory thead th:last-child {width: 15%;}
.inventory button {background: transparent; border: 0; text-decoration: underline; text-underline-offset: 3px; text-align: left; font-weight: 650; padding: 2px 0; display: block;}
.inventory .type {display: block; font-weight: 400;}
.status {border: 1px solid var(--line); padding: 3px 7px; border-radius: 4px; display: inline-block; font-size: 12px; background: var(--soft);}
.status[data-state="fixture-inferred"] {border-style: dashed; background: white;}
.status[data-state="not-observed"] {background: var(--bg); border-color: #c1bec5;}
.test-row {border-top: 1px solid #e5e1eb; padding-top: 11px; margin-top: 12px;}
.test-row h3 {font-size: 15px; margin: 2px 0;}
.test-row p, .requirement p {font-size: 14px; margin-top: 5px;}
#path > p:first-child {margin-top: 16px;}
@media (max-width: 850px) {
  .impact-heading {align-items: flex-start; flex-direction: column;}
  .impact-top, .impact-lower {grid-template-columns: 1fr;}
}
@media (max-width: 560px) {
  main {padding: 14px;}
  .impact-panel {padding: 14px;}
  .topbar-inner {flex-wrap: wrap; gap: 6px;}
  .impact-section-head, .trace-heading {align-items: flex-start; flex-direction: column;}
  .trace-heading select {width: 100%;}
  .path-steps {flex-direction: column;}
  .path-steps li {flex: auto;}
  .filter {flex-wrap: wrap;}
  .inventory th, .inventory td {padding: 6px 3px;}
  .inventory thead th:first-child {width: 46%;}
  .inventory thead th:last-child {width: 19%;}
}

.related-tests {display: flex; align-items: center; flex-wrap: wrap; column-gap: 9px; margin-top: 8px; font-size: 13px;}
.related-tests a {display: inline-flex; align-items: center; min-height: 44px; font-weight: 600;}
.test-row h3:target {background: var(--soft); outline: 2px solid var(--line); outline-offset: 2px;}

.comparison {margin: 0 0 14px; padding-top: 6px; padding-bottom: 6px;}
.comparison > summary {font-size: 18px; font-weight: 700;}
.comparison[open] {padding-bottom: 16px;}
.compare-head {display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 5px 0 12px;}
.compare-head p, .compare-card p, .compare-card li {font-size: 14px;}
.compare-cards {display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px;}
.compare-card {display: flex; flex-direction: column; align-items: flex-start; gap: 7px; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg);}
.compare-card h3 {margin: 0;}
.compare-card ul {margin: 0 0 4px;}
.compare-card button {margin-top: auto;}
.role-filter {margin: 10px 0 5px;}
#copy-fallback {display: block; margin-bottom: 10px;}
#copy-fallback[hidden] {display: none;}
#view-url {display: block; width: min(100%, 46em);}
#share-status:not(:empty) {margin-bottom: 14px;}
@media (max-width: 760px) {
  .compare-head {align-items: stretch; flex-direction: column;}
  .compare-cards {grid-template-columns: 1fr;}
  .exports {max-width: 100%;}
}

#plan-proposal:not([hidden]), .investigation-link {display: inline-flex; min-height: 44px; align-items: center;}
#plan-proposal {margin-top: 12px;}
.investigation-link {display: flex; width: fit-content;}
