:root {
  color-scheme: light;
  --paper: #faf4e8;
  --white: #fffcf6;
  --ink: #203e66;
  --red: #cf503b;
  --gold: #dca846;
  --sage: #7f9276;
  --muted: #697476;
  --line: #ddd6c7;
  --tint: #f2e9d8;
  font-family: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background-image: radial-gradient(#b49d7518 0.7px, transparent 0.7px);
  background-size: 5px 5px;
  padding-inline: env(safe-area-inset-left, 0) env(safe-area-inset-right, 0);
}
[hidden] {
  display: none !important;
}
button,
input,
select {
  font: inherit;
}
button {
  cursor: pointer;
}
button,
a,
input,
select,
summary {
  -webkit-tap-highlight-color: transparent;
}
button,
a {
  touch-action: manipulation;
  transition:
    background-color 0.15s,
    color 0.15s;
}
button:disabled {
  cursor: default;
  opacity: 0.45;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 4px;
}
a {
  color: inherit;
  text-decoration: none;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1,
h2 {
  font-family: "KaiTi", "STKaiti", "Songti SC", serif;
}
h1 {
  font-size: 44px;
  line-height: 1.4;
  margin: 10px 0;
}
h2 {
  font-size: 25px;
  margin-bottom: 10px;
}
h3 {
  font-size: 16px;
  line-height: 1.7;
  font-weight: 600;
  margin-bottom: 10px;
}
p {
  line-height: 1.9;
}
input,
select {
  width: 100%;
  min-height: 44px;
  border: 1px solid #d3cebf;
  border-radius: 6px;
  padding: 9px 11px;
  background: #fffdf8;
  color: var(--ink);
}
label {
  display: block;
  font-size: 12px;
  line-height: 1.8;
}
label select,
label input {
  display: block;
  margin-top: 6px;
  font-size: 13px;
}
.muted {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.9;
}
.eyebrow {
  color: var(--red);
  font-size: 11px;
  letter-spacing: 0.12em;
  line-height: 1.8;
  margin-bottom: 8px;
}
.site-header,
main,
footer {
  width: min(1320px, calc(100% - 80px));
  margin: auto;
}
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding-block: 28px 24px;
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font:
    700 27px/1.4 "KaiTi",
    "STKaiti",
    "Songti SC",
    serif;
  letter-spacing: 1px;
  white-space: nowrap;
}
.brand svg {
  width: 32px;
  height: 33px;
  stroke: var(--red);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.brand > span {
  border-left: 1px solid var(--line);
  margin-left: 10px;
  padding-left: 17px;
  font:
    400 12px/1.7 "Microsoft YaHei",
    sans-serif;
  letter-spacing: 0;
  color: var(--muted);
}
.header-actions {
  display: flex;
  gap: 15px;
  align-items: center;
  font-size: 12px;
}
.header-actions > a {
  padding: 9px 0;
}
.header-actions > a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.primary,
.secondary,
.quiet {
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 11px 18px;
  min-height: 44px;
  font-size: 13px;
  line-height: 1.6;
}
.primary {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--white);
}
.primary:hover {
  background: #153153;
}
.secondary {
  background: var(--white);
  border-color: var(--line);
  color: var(--ink);
}
.secondary:hover {
  background: var(--tint);
}
.quiet {
  background: transparent;
  color: var(--ink);
  padding: 9px 11px;
}
.quiet:hover {
  background: var(--tint);
}
.skip-link {
  position: fixed;
  top: -100px;
  left: 20px;
  background: var(--ink);
  color: white;
  z-index: 50;
  padding: 12px 20px;
}
.skip-link:focus {
  top: 12px;
}
.loading {
  padding: 55px 0;
  color: var(--muted);
  font-size: 13px;
}
.panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 26px;
  min-width: 0;
}
.auth {
  max-width: 450px;
  margin: 65px auto 90px;
  padding: 35px;
}
.auth h1 {
  font-size: 37px;
  margin-top: 15px;
}
.auth > p {
  font-size: 13px;
  color: var(--muted);
}
.auth form {
  margin-top: 28px;
}
.auth input {
  margin: 7px 0 19px;
}
.auth .primary {
  width: 100%;
  display: flex;
  justify-content: space-between;
  margin-top: 7px;
  background: var(--red);
  border-color: var(--red);
}
.auth .primary:hover {
  background: #b64130;
}
.auth .auth-note {
  font-size: 11px;
  border-top: 1px solid var(--line);
  padding-top: 19px;
  margin: 8px 0 0;
}
.error {
  font-size: 13px;
  color: #ad3d2b;
  line-height: 1.9;
}
.error:empty {
  display: none;
}
.auth .error {
  color: #ad3d2b;
  margin-top: 17px;
}
.desk-intro {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 28px;
  padding: 36px 0 28px;
}
.desk-intro:after {
  content: "✳";
  font-size: 75px;
  line-height: 1;
  color: var(--gold);
  opacity: 0.35;
  position: absolute;
  left: 44%;
  top: 40px;
  transform: rotate(-10deg);
  pointer-events: none;
}
.desk-intro > div {
  z-index: 1;
}
.desk-intro p:last-child {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 0;
}
.refresh-area {
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  gap: 10px;
}
.refresh-area .muted {
  font-size: 10px;
}
.filter-panel {
  padding: 20px 24px;
}
.filter-primary {
  display: flex;
  gap: 14px;
  align-items: end;
}
.filter-primary > label {
  width: 260px;
}
.filter-primary > .primary {
  margin-left: 5px;
}
.filter-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid #e9e1d2;
  padding-top: 10px;
  margin-top: 12px;
}
.filter-bottom p {
  font-size: 11px;
  color: var(--muted);
  margin: 0;
}
.exports {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}
.exports button {
  font-size: 11px;
}
.filter-extra {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 14px 0 6px;
}
#more-filters {
  margin-top: 16px;
}
#more-filters > summary {
  cursor: pointer;
  font-size: 12px;
  line-height: 1.8;
  width: fit-content;
  padding: 4px 0;
}
#more-filters > summary > span {
  font-size: 10px;
  color: var(--muted);
  margin-left: 10px;
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 17px;
  margin: 22px 0 28px;
}
.stat {
  background: var(--white);
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: 9px;
  position: relative;
}
.stat:before {
  content: "";
  position: absolute;
  width: 24px;
  height: 2px;
  right: 24px;
  top: 26px;
  background: var(--gold);
}
.stat > span {
  display: block;
  font-size: 12px;
  color: var(--muted);
}
.stat strong {
  display: block;
  font:
    400 37px/1.5 Georgia,
    serif;
  margin: 8px 0 3px;
  font-variant-numeric: tabular-nums;
}
.stat small {
  display: block;
  font-size: 10px;
  line-height: 1.9;
  color: var(--muted);
}
.desk-tabs {
  display: flex;
  gap: 29px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}
.desk-tabs button {
  position: relative;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 14px;
  padding: 12px 1px 16px;
  white-space: nowrap;
}
.desk-tabs button[aria-selected="true"] {
  color: var(--ink);
  font-weight: 600;
}
.desk-tabs button[aria-selected="true"]:after {
  content: "";
  position: absolute;
  bottom: -1px;
  height: 3px;
  background: var(--red);
  left: 0;
  right: 0;
  border-radius: 2px;
}
.overview-heading {
  margin: 27px 0 18px;
}
.overview-heading h2 {
  font-size: 28px;
  margin-bottom: 8px;
}
.overview-heading p {
  margin: 0;
}
.theme-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.theme-card {
  --theme-accent: #bc6955;
  display: flex;
  flex-direction: column;
  padding: 25px;
  border-top: 3px solid var(--theme-accent);
}
.theme-card:nth-child(2) {
  --theme-accent: #ad8b4b;
}
.theme-card:nth-child(3) {
  --theme-accent: #74876b;
}
.theme-head {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 18px;
}
.theme-head h3 {
  font:
    600 25px/1.5 "KaiTi",
    "STKaiti",
    "Songti SC",
    serif;
  margin: 0;
}
.theme-number {
  color: var(--theme-accent);
  font:
    16px/1.5 Georgia,
    serif;
}
.theme-summary {
  text-align: left;
  border: 0;
  border-radius: 6px;
  background: #f5eee2;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.9;
  padding: 14px;
  width: 100%;
  min-height: 140px;
}
.theme-summary:hover {
  background: #eee4d3;
}
.theme-summary small {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-top: 10px;
}
.theme-metrics {
  margin-top: 13px;
  flex: 1;
}
.theme-metric {
  display: block;
  text-align: left;
  width: 100%;
  padding: 16px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: none;
  color: var(--ink);
}
.theme-metric:hover {
  background: #f7f2e9;
}
.metric-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 12px;
  line-height: 1.9;
}
.metric-heading > span {
  min-width: 0;
}
.metric-heading strong {
  font:
    27px/1.5 Georgia,
    serif;
  white-space: nowrap;
}
.theme-metric small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.9;
  margin-top: 5px;
}
.metric-choice {
  display: block;
  font-size: 12px;
  line-height: 1.8;
  margin-top: 5px;
}
.theme-note {
  font-size: 10px;
  color: var(--muted);
  line-height: 1.9;
  margin: 17px 0 0;
}
.collection-card {
  margin-top: 25px;
  padding: 28px;
}
.collection-card .section-heading > label {
  width: 200px;
  flex-shrink: 0;
}
.collection-card h2 {
  font-size: 28px;
}
.collection-range {
  font-size: 11px;
  color: var(--muted);
  margin: 0 0 15px;
}
.collection-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  padding: 18px 0;
  border-radius: 7px;
  background: #f5eee2;
  margin-bottom: 27px;
}
.collection-metrics > div {
  min-width: 0;
  padding: 0 20px;
  border-right: 1px solid var(--line);
}
.collection-metrics > div:last-child {
  border: 0;
}
.collection-metrics span {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 6px;
}
.collection-metrics strong {
  font:
    29px/1.5 Georgia,
    serif;
}
.collection-metrics small {
  font-size: 10px;
  color: var(--muted);
  margin-left: 8px;
  white-space: nowrap;
}
.collection-plots {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 25px;
}
.collection-chart {
  min-width: 0;
}
.collection-chart + .collection-chart {
  padding-left: 25px;
  border-left: 1px solid var(--line);
}
.collection-chart h3 {
  font-size: 14px;
  margin-bottom: 3px;
}
.collection-chart > p {
  margin-bottom: 0;
  font-size: 10px;
}
.collection-chart .daily-trend {
  height: 210px;
  margin-top: 0;
  padding-top: 18px;
}
.daily-trend .unlabelled-day {
  visibility: hidden;
}
.dense-trend .trend-count {
  visibility: hidden;
}
.collection-chart svg {
  display: block;
  width: 100%;
  height: 210px;
}
.collection-chart svg text {
  fill: var(--muted);
  font-size: 12px;
}
.collection-gridline {
  stroke: #e9e1d2;
  stroke-width: 1;
}
.cumulative-area {
  fill: #cc786318;
}
.cumulative-line {
  fill: none;
  stroke: #bc6955;
  stroke-width: 2.5;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.cumulative-point {
  fill: #bc6955;
}
.collection-note {
  font-size: 11px;
  color: var(--muted);
  margin: 20px 0 0;
}
.collection-details {
  border-top: 1px solid var(--line);
  margin-top: 20px;
}
.collection-details > summary {
  font-size: 12px;
  line-height: 1.9;
  padding: 16px 0 0;
  cursor: pointer;
}
.collection-details table {
  margin-top: 12px;
}
.collection-details td {
  vertical-align: middle;
}
.collection-details td .quiet {
  min-height: 44px;
  white-space: nowrap;
}
.chart-card {
  padding: 25px 27px;
  min-width: 0;
}
.chart-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 15px;
}
.chart-head h2 {
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.7;
  margin: 0;
}
.chart-head .quiet {
  font-size: 11px;
  min-height: 32px;
  padding: 5px 2px;
  white-space: nowrap;
  color: var(--muted);
}
.chart-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.8;
  margin: 10px 0 20px;
}
.type-tag {
  font-size: 9px;
  color: #ad4938;
  background: #f7e9df;
  padding: 2px 6px;
  border-radius: 3px;
}
.chart-subtitle {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.9;
  margin: 9px 0 15px;
}
.bar-row {
  margin: 16px 0;
}
.bar-label {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 15px;
  font-size: 12px;
  line-height: 1.8;
  margin-bottom: 7px;
}
.bar-label > span:first-child {
  min-width: 0;
  overflow-wrap: anywhere;
}
.bar-count {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: var(--muted);
  font-size: 11px;
  flex-shrink: 0;
}
.bar-track {
  height: 8px;
  background: #f0eadf;
  border-radius: 4px;
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  background: #cc7863;
  border-radius: 4px;
  min-width: 0;
}
.bar-row:nth-child(3n + 1) .bar-fill {
  background: #8e9d80;
}
.bar-row:nth-child(3n + 2) .bar-fill {
  background: #d4ad6a;
}
.chart-states {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 13px;
  border-top: 1px solid #e9e1d2;
  padding-top: 13px;
  margin-top: 19px;
  font-size: 10px;
  line-height: 1.9;
  color: var(--muted);
}
.chart-footnote {
  font-size: 10px;
  line-height: 1.9;
  color: var(--muted);
  margin: 13px 0 0;
}
.no-values {
  font-size: 12px;
  color: var(--muted);
  padding: 17px 0;
  margin: 0;
}
.chart-wide {
  grid-column: 1/-1;
}
.trend {
  display: flex;
  align-items: stretch;
  gap: 7px;
  height: 180px;
  margin-top: 23px;
}
.trend-day {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  flex-direction: column;
  border: 0;
  background: none;
  padding: 0;
  color: var(--muted);
  font-size: 9px;
  gap: 7px;
}
.trend-count {
  height: 18px;
  font-variant-numeric: tabular-nums;
}
.trend-track {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  width: 100%;
  flex: 1;
  background: #f7f2e9;
  border-radius: 4px;
  overflow: hidden;
}
.trend-column {
  display: block;
  width: 100%;
  background: #8e9d80;
  border-radius: 4px 4px 0 0;
  min-height: 0;
}
.trend-day:hover .trend-column {
  background: #60785b;
}
.trend-day:hover .trend-track {
  background: #eee5d4;
}
.trend-day:focus-visible {
  outline-offset: 2px;
}
.trend-label {
  white-space: nowrap;
}
.section-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 20px;
}
.section-heading p {
  margin: 0;
}
.record-count {
  font:
    24px/1.4 Georgia,
    serif;
  white-space: nowrap;
}
.table-scroll {
  max-width: 100%;
  overflow: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}
th,
td {
  padding: 14px 10px;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  line-height: 1.8;
  vertical-align: top;
}
th {
  font-weight: 500;
  color: var(--muted);
  font-size: 11px;
}
td .quiet {
  min-height: 32px;
  padding: 3px 8px;
  font-size: 12px;
}
#records td:first-child {
  white-space: nowrap;
}
#records td:nth-child(2) {
  min-width: 125px;
}
.pager {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 22px;
  font-size: 12px;
}
.empty {
  text-align: center;
  color: var(--muted);
  padding: 40px 20px;
  font-size: 13px;
  line-height: 1.9;
}
.empty > span {
  display: block;
  color: var(--red);
  font:
    40px/1.5 Georgia,
    serif;
}
.empty h2 {
  font-size: 27px;
  color: var(--ink);
  margin: 13px 0;
}
.empty p {
  margin-bottom: 0;
}
.analysis-controls {
  display: flex;
  align-items: flex-end;
  gap: 22px;
  margin-bottom: 20px;
  padding: 20px 24px;
}
.analysis-controls > label:first-child {
  flex: 1;
  min-width: 0;
}
.analysis-controls > #variant-wrap {
  width: 300px;
  max-width: 40%;
}
.question-navigation {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  flex-shrink: 0;
}
.question-navigation .muted {
  font-size: 10px;
  white-space: nowrap;
}
.question-navigation button {
  white-space: nowrap;
}
#question-chart > .panel {
  margin-bottom: 22px;
}
.comparison > .section-heading > label {
  width: 160px;
  flex-shrink: 0;
}
.comparison h2 {
  font-size: 24px;
}
.comparison th:first-child,
.comparison td:first-child {
  min-width: 110px;
}
.comparison th:not(:first-child) {
  min-width: 110px;
}
.comparison td:not(:first-child) {
  font-variant-numeric: tabular-nums;
}
.comparison td small {
  display: block;
  color: var(--muted);
  font-size: 10px;
}
.reading-note {
  margin-top: 25px;
  padding: 18px 24px;
}
.reading-note summary {
  font-size: 12px;
  cursor: pointer;
  padding: 3px 0;
  line-height: 1.9;
}
.reading-note p {
  font-size: 12px;
  color: var(--muted);
  margin: 13px 0 0;
}
.detail-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 20px;
}
.detail-head h2 {
  margin-bottom: 9px;
}
.detail-head .eyebrow {
  margin-bottom: 5px;
}
dialog {
  background: var(--white);
  color: var(--ink);
  width: min(900px, calc(100% - 32px));
  max-height: 85dvh;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 29px;
}
dialog::backdrop {
  background: #1d355e88;
}
#detail-meta {
  overflow-wrap: anywhere;
  border-bottom: 1px solid var(--line);
  padding-bottom: 18px;
}
.detail-section {
  border-bottom: 1px solid var(--line);
  margin-top: 10px;
}
.detail-section > summary {
  font-size: 15px;
  line-height: 1.8;
  padding: 12px 0;
  cursor: pointer;
}
.detail-answer {
  padding: 15px 0;
  border-top: 1px solid #ebe3d5;
}
.detail-answer h3 {
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 7px;
}
.detail-answer p {
  font-size: 13px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  margin: 6px 0;
  color: #9d4838;
}
.detail-answer .muted {
  font-size: 10px;
  color: var(--muted);
}
footer {
  padding: 28px 0 30px;
  font-size: 10px;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
@media (max-width: 1050px) {
  .theme-grid {
    grid-template-columns: 1fr;
  }
  .theme-card {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    column-gap: 30px;
  }
  .theme-head,
  .theme-summary,
  .theme-note {
    grid-column: 1;
  }
  .theme-metrics {
    grid-column: 2;
    grid-row: 1 / span 3;
    margin-top: 0;
  }
  .theme-summary {
    min-height: 120px;
  }
  .filter-primary > label {
    width: 230px;
  }
  .site-header,
  main,
  footer {
    width: calc(100% - 48px);
  }
  .stats {
    gap: 12px;
  }
  .stat {
    padding: 20px;
  }
  .stat:before {
    right: 18px;
  }
  .desk-intro:after {
    left: 57%;
    font-size: 60px;
  }
  .chart-card {
    padding: 23px;
  }
  .filter-panel {
    padding: 20px;
  }
  .refresh-area .muted {
    max-width: 170px;
    text-align: right;
  }
}
@media (max-width: 760px) {
  .overview-heading {
    margin-top: 23px;
  }
  .overview-heading h2,
  .collection-card h2 {
    font-size: 26px;
  }
  .overview-heading p {
    font-size: 11px;
  }
  .theme-grid {
    gap: 17px;
  }
  .theme-card {
    display: flex;
    padding: 22px;
  }
  .theme-head h3 {
    font-size: 24px;
  }
  .theme-summary {
    min-height: 0;
  }
  .theme-metrics {
    margin-top: 9px;
  }
  .metric-heading strong {
    font-size: 26px;
  }
  .collection-card {
    padding: 21px;
  }
  .collection-card .section-heading {
    flex-wrap: wrap;
    gap: 16px;
  }
  .collection-card .section-heading > label {
    width: 100%;
  }
  .collection-metrics > div {
    padding: 0 11px;
  }
  .collection-metrics span {
    font-size: 10px;
  }
  .collection-metrics strong {
    font-size: 27px;
  }
  .collection-metrics small {
    display: block;
    margin-left: 0;
  }
  .collection-plots {
    grid-template-columns: 1fr;
    gap: 22px;
  }
  .collection-chart + .collection-chart {
    padding: 19px 0 0;
    border-left: 0;
    border-top: 1px solid var(--line);
  }
  .collection-chart svg text {
    font-size: 21px;
  }
  .collection-chart .daily-trend {
    height: 190px;
    gap: 4px;
  }
  .collection-note {
    font-size: 10px;
  }
  .site-header,
  main,
  footer {
    width: calc(100% - 36px);
  }
  .site-header {
    padding-block: 21px 18px;
    gap: 10px;
  }
  .brand {
    font-size: 23px;
    gap: 7px;
  }
  .brand svg {
    width: 25px;
    height: 27px;
  }
  .brand > span {
    font-size: 10px;
    margin-left: 3px;
    padding-left: 10px;
  }
  .header-actions {
    gap: 5px;
    font-size: 10px;
  }
  .header-actions .quiet {
    font-size: 10px;
    padding: 7px;
    min-height: 36px;
  }
  .desk-intro {
    padding-block: 26px 22px;
    align-items: start;
    gap: 16px;
  }
  .desk-intro h1 {
    font-size: 35px;
  }
  .desk-intro:after {
    display: none;
  }
  .desk-intro .eyebrow {
    font-size: 9px;
  }
  .desk-intro p:last-child {
    font-size: 11px;
  }
  .refresh-area .muted {
    font-size: 9px;
  }
  .refresh-area .secondary {
    font-size: 11px;
    padding: 9px 12px;
    min-height: 40px;
  }
  .filter-panel {
    padding: 17px;
  }
  .filter-primary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .filter-primary > label {
    width: auto;
  }
  .filter-primary > .primary {
    margin-left: 0;
  }
  .filter-primary > .quiet {
    justify-self: start;
  }
  .filter-extra {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .filter-bottom {
    flex-wrap: wrap;
    gap: 4px;
  }
  .filter-bottom p {
    width: 100%;
    font-size: 10px;
  }
  .exports {
    margin-left: auto;
  }
  .exports button {
    padding-inline: 8px;
  }
  .stats {
    grid-template-columns: 1fr 1fr;
    gap: 11px;
    margin: 18px 0 22px;
  }
  .stat {
    padding: 16px;
  }
  .stat > span {
    font-size: 11px;
  }
  .stat strong {
    font-size: 31px;
  }
  .stat:before {
    width: 17px;
    right: 16px;
    top: 22px;
  }
  .stat small {
    font-size: 9px;
  }
  .desk-tabs {
    gap: 25px;
    margin-bottom: 18px;
  }
  .desk-tabs button {
    font-size: 13px;
    padding-block: 10px 14px;
  }
  .chart-grid {
    grid-template-columns: 1fr;
    gap: 17px;
  }
  .chart-card {
    padding: 21px;
  }
  .chart-head h2 {
    font-size: 15px;
  }
  .bar-label {
    font-size: 12px;
    gap: 12px;
  }
  .bar-count {
    font-size: 10px;
  }
  .trend {
    gap: 5px;
    height: 160px;
  }
  .trend-day {
    font-size: 8px;
    gap: 5px;
  }
  .trend-label {
    font-size: 8px;
  }
  .analysis-controls {
    flex-wrap: wrap;
    padding: 18px;
    gap: 13px;
  }
  .analysis-controls > label:first-child,
  .analysis-controls > #variant-wrap {
    width: 100%;
    max-width: none;
    flex: auto;
  }
  .analysis-controls select {
    font-size: 12px;
  }
  .question-navigation {
    width: 100%;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
  }
  .comparison {
    padding: 20px;
  }
  .comparison .section-heading {
    flex-wrap: wrap;
    gap: 15px;
  }
  .comparison h2 {
    font-size: 24px;
  }
  .comparison th:not(:first-child) {
    min-width: 90px;
  }
  #panel-records > .panel {
    padding: 20px;
  }
  .section-heading h2 {
    font-size: 24px;
  }
  .section-heading .muted {
    font-size: 11px;
  }
  .record-count {
    font-size: 21px;
  }
  .reading-note {
    padding: 16px 19px;
  }
  .reading-note p {
    font-size: 11px;
  }
  dialog {
    padding: 22px;
  }
  .auth {
    padding: 27px;
    margin-top: 35px;
  }
  .auth h1 {
    font-size: 33px;
  }
  .auth > p {
    font-size: 12px;
  }
  footer {
    font-size: 9px;
    padding-bottom: calc(26px + env(safe-area-inset-bottom, 0px));
  }
}
@media (max-width: 380px) {
  .brand > span {
    display: none;
  }
  .site-header,
  main,
  footer {
    width: calc(100% - 28px);
  }
  .filter-primary {
    grid-template-columns: 1fr;
  }
  .filter-primary > .quiet {
    justify-self: stretch;
  }
  .filter-extra {
    grid-template-columns: 1fr;
  }
  .desk-tabs {
    gap: 22px;
  }
  .refresh-area .muted {
    max-width: 115px;
  }
  .trend {
    gap: 3px;
  }
  .stat small {
    min-height: 33px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
