/* EP16 page-only styles: decision tree, checklist, rate table.
   Muted text uses #5c6563 so meta copy on the sidebar paper clears WCAG AA. */

.episode .meta { color: #5c6563; }
.video-frame--empty .meta,
.site-footer .meta { color: var(--brass-light); }
.crumbs,
.sources li::marker { color: #5c6563; }

.ep16-tree fieldset {
  border: 1px solid var(--paper-line);
  border-radius: var(--radius-sm);
  margin: 0 0 1rem;
  padding: .5rem .9rem .75rem;
  min-width: 0;
  max-width: 100%;
}
.ep16-tree legend {
  font-weight: 600;
  padding: 0 .25rem;
  color: var(--ink);
}
.ep16-choice {
  display: flex;
  align-items: center;
  gap: .75rem;
  min-height: 44px;
  margin: 0;
  cursor: pointer;
  color: var(--ink);
}
.ep16-choice input,
.ep16-list input {
  width: 44px;
  height: 44px;
  margin: 0;
  flex: 0 0 44px;
  accent-color: var(--evergreen);
}
.ep16-choice input:focus-visible,
.ep16-list input:focus-visible,
.ep16-reset:focus-visible {
  outline: 3px solid var(--evergreen);
  outline-offset: 3px;
}
.ep16-result {
  background: var(--paper-raised);
  border: 1px solid var(--paper-line);
  border-left: 4px solid var(--evergreen);
  border-radius: var(--radius-sm);
  padding: .9rem 1rem;
  margin: 0 0 .75rem;
  color: var(--ink);
}
.ep16-result[hidden],
#tree-q4[hidden] { display: none; }
.ep16-state { font-weight: 600; }

.ep16-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
}
.ep16-list li {
  display: flex;
  gap: .75rem;
  align-items: center;
  min-height: 44px;
  padding: .35rem 0;
  border-bottom: 1px solid var(--paper-line);
}
.ep16-list label {
  cursor: pointer;
  color: var(--ink);
  line-height: 1.45;
}
.ep16-reset {
  font: inherit;
  min-height: 44px;
  min-width: 44px;
  padding: .5rem 1rem;
  border: 2px solid var(--evergreen);
  border-radius: var(--radius-sm);
  background: var(--paper-raised);
  color: var(--ink);
  cursor: pointer;
}
.ep16-reset:hover { background: var(--evergreen-tint); }

.ep16-rates {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1rem;
  background: var(--paper-raised);
}
.ep16-rates caption {
  caption-side: top;
  text-align: left;
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 .6rem;
}
.ep16-rates th,
.ep16-rates td {
  text-align: left;
  vertical-align: top;
  padding: .6rem .5rem;
  border-bottom: 1px solid var(--paper-line);
  overflow-wrap: anywhere;
  color: var(--ink);
}
.ep16-rates th {
  font: 600 1rem/1.4 var(--sans);
  background: var(--paper-deep);
}
.ep16-rates th[scope="row"] { width: 11rem; overflow-wrap: normal; }

.episode-main, .prose, .ep16-tree, .link-list a { overflow-wrap: anywhere; }

@media print {
  .ep16-reset { display: none; }
  .ep16-result[hidden],
  #tree-q4[hidden] { display: block; }
}
