.pc-surveys-screen { padding: 20px; color: #283d35; }
.pc-surveys-screen[hidden] { display: none; }
.pc-surveys-screen * { box-sizing: border-box; }
.survey-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.survey-heading h1 { font-size: 24px; margin: 0 0 18px; }
.survey-heading span { font-size: 12px; color: #63746c; }
.survey-tabs { display: flex; gap: 12px; }
.pc-surveys-screen button { cursor: pointer; border: 1px solid #b8c9bd; border-radius: 8px; background: white; color: #294e39; padding: 11px 20px; font: inherit; }
.pc-surveys-screen button:disabled { opacity: .55; cursor: wait; }
.pc-surveys-screen button:focus-visible, .pc-surveys-screen input:focus-visible, .pc-surveys-screen textarea:focus-visible, .pc-surveys-screen select:focus-visible { outline: 3px solid #dfac34; outline-offset: 2px; }
.survey-tabs button[aria-pressed="true"], .pc-surveys-screen .survey-primary { background: #187346; color: white; border-color: #187346; }
.survey-layout { display: grid; grid-template-columns: minmax(220px, 290px) minmax(0, 1fr); gap: 22px; align-items: start; }
.survey-cards { display: flex; flex-direction: column; gap: 12px; }
.pc-surveys-screen .survey-card { display: flex; flex-direction: column; gap: 10px; text-align: left; padding: 16px; width: 100%; overflow-wrap: anywhere; }
.survey-card strong { font-size: 17px; }
.survey-card small { color: #68796f; }
.pc-surveys-screen .survey-card.is-selected { border: 2px solid #187346; background: #f0f7ed; }
.survey-panel { background: white; border: 1px solid #d9e1d9; border-radius: 12px; padding: 24px; min-width: 0; }
.survey-panel h2 { margin-top: 0; font-size: 21px; overflow-wrap: anywhere; }
.survey-panel p { line-height: 1.7; font-size: 14px; }
.survey-panel fieldset { min-width: 0; border: 1px solid #d9e1d9; border-radius: 8px; padding: 18px; margin: 20px 0; }
.survey-panel legend { font-weight: 600; padding: 0 7px; white-space: pre-wrap; overflow-wrap: anywhere; max-width: 100%; }
.survey-field { display: flex; flex-direction: column; gap: 8px; margin: 0 0 16px; font-size: 14px; }
.survey-panel input:not([type="checkbox"]):not([type="radio"]), .survey-panel textarea, .survey-panel select { width: 100%; min-width: 0; border: 1px solid #b8c9bd; border-radius: 6px; padding: 10px; font: inherit; background: white; color: #283d35; }
.survey-panel textarea { resize: vertical; }
.survey-dates { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.survey-checks { display: flex; flex-wrap: wrap; gap: 12px 20px; }
.survey-choice { display: flex; align-items: center; gap: 8px; font-size: 15px; min-height: 36px; overflow-wrap: anywhere; }
.survey-choice input { width: 18px; height: 18px; flex: 0 0 18px; accent-color: #187346; }
.survey-answer-option { margin: 6px 0; }
.survey-actions { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 20px; }
.survey-empty { background: #f5f7f2; padding: 22px; color: #68796f; border-radius: 8px; }
.survey-error { color: #b43232; min-height: 20px; white-space: pre-wrap; }
.survey-state { color: #187346; font-weight: bold; }
.survey-panel .survey-answer-fields { border: 0; padding: 0; margin: 0; }
.survey-result { display: flex; justify-content: space-between; gap: 20px; padding: 12px 0; border-bottom: 1px solid #e9ede6; overflow-wrap: anywhere; }
.survey-result strong { white-space: nowrap; }
.survey-text-answer { white-space: pre-wrap; overflow-wrap: anywhere; border-bottom: 1px solid #e9ede6; padding: 12px 0; }
@media (max-width: 760px) {
  .pc-surveys-screen { padding: 12px; }
  .survey-layout { grid-template-columns: minmax(0, 1fr); }
  .survey-cards { max-height: 250px; overflow-y: auto; }
  .survey-panel { padding: 16px; }
  .survey-panel fieldset { padding: 12px; }
  .survey-dates { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .survey-tabs { gap: 8px; }
  .survey-tabs button { flex: 1; padding: 10px; }
}

.survey-description { white-space: pre-wrap; overflow-wrap: anywhere; }

.survey-response-review { border-top: 1px solid #d9e1d9; border-bottom: 1px solid #d9e1d9; padding: 18px 0; margin: 20px 0; }
.survey-review-heading { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.survey-review-heading h3 { margin: 0; }
.survey-recipients { display: grid; gap: 10px; }
.survey-recipient, .survey-recipient-response { border: 1px solid #d9e1d9; border-radius: 8px; background: #fafcf9; }
.survey-recipient, .survey-recipient-response summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px; }
.survey-recipient-response summary { cursor: pointer; }
.survey-recipient-response summary:focus-visible { outline: 3px solid #dfac34; outline-offset: 2px; }
.survey-recipient-response summary::before { content: '▸'; color: #187346; }
.survey-recipient-response[open] summary::before { content: '▾'; }
.survey-recipient-name { display: grid; gap: 5px; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.survey-recipient-name small { color: #63746c; }
.survey-response-status { font-size: 13px; white-space: nowrap; padding: 5px 10px; border-radius: 20px; background: #f3ecde; color: #795d20; }
.survey-response-status.is-answered { background: #e1f1e5; color: #187346; }
.survey-person-answers { border-top: 1px solid #d9e1d9; padding: 0 14px 14px; }
.survey-person-answers dt { font-weight: 600; white-space: pre-wrap; overflow-wrap: anywhere; margin: 14px 0 8px; }
.survey-person-answers dd { margin: 0; padding: 10px; background: white; border-radius: 6px; white-space: pre-wrap; overflow-wrap: anywhere; }

.survey-required { display: inline-block; font-size: 12px; color: #a43434; font-weight: normal; white-space: nowrap; }
.survey-required.is-optional { color: #63746c; }

/* Result charts: values remain visible as text, including zero counts. */
.survey-results-title { margin: 28px 0 16px; font-size: 22px; }
.survey-results-overview { display: flex; align-items: center; gap: 28px; padding: 24px; background: #f3f8f3; border: 1px solid #dce8dd; border-radius: 12px; }
.survey-rate { flex: 0 0 104px; width: 104px; height: 104px; box-sizing: border-box; padding: 12px; border-radius: 50%; background: conic-gradient(#187346 var(--survey-rate), #dce7dd 0); }
.survey-rate > div { height: 100%; background: #f3f8f3; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.survey-rate strong { font-size: 26px; color: #155a39; font-variant-numeric: tabular-nums; }
.survey-rate small { font-size: 14px; margin-left: 2px; }
.survey-rate span { font-size: 12px; color: #54685b; }
.survey-result-totals { flex: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0; text-align: center; }
.survey-result-totals dt { font-size: 13px; color: #54685b; }
.survey-result-totals dd { font-size: 30px; font-weight: 700; margin: 6px 0 0; color: #155a39; font-variant-numeric: tabular-nums; }
.survey-result-totals dd span { font-size: 13px; font-weight: 400; margin-left: 4px; }
.survey-result-question { margin-top: 22px; padding: 24px; border: 1px solid #dce5dd; border-radius: 12px; min-width: 0; }
.survey-result-kicker { display: flex; gap: 10px; align-items: center; font-size: 12px; color: #54685b; }
.survey-result-kicker span:first-child { color: #187346; font-weight: 700; }
.survey-result-kicker span:last-child { background: #eef4ed; border-radius: 4px; padding: 3px 8px; }
.survey-result-question h4 { margin: 12px 0; font-size: 17px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
.survey-panel .survey-result-base { font-size: 12px; margin: 0 0 20px; color: #54685b; }
.survey-result-base > span { margin: 0 8px; color: #a2afa6; }
.survey-distribution { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 32px; align-items: center; }
.survey-distribution-ring { position: relative; width: 160px; height: 160px; border-radius: 50%; padding: 18px; box-sizing: border-box; }
.survey-distribution-ring > div { position: absolute; inset: 18px; border-radius: 50%; background: white; display: flex; align-items: center; justify-content: center; flex-direction: column; }
.survey-distribution-ring span { font-size: 12px; color: #63746c; }
.survey-distribution-ring strong { font-size: 28px; color: #254b40; }
.survey-distribution-ring small { font-size: 14px; margin-left: 4px; }
.survey-chart-legend { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.survey-chart-legend li { display: flex; gap: 12px; align-items: baseline; padding-bottom: 12px; border-bottom: 1px solid #edf1ee; }
.survey-chart-legend li > div { min-width: 0; flex: 1; }
.survey-option-number { background: var(--option-color); color: white; flex: 0 0 24px; width: 24px; height: 24px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }
.survey-legend-label { font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.survey-top-choice { display: inline-block; background: #edf5ef; color: #246349; padding: 2px 6px; border-radius: 4px; font-size: 10px; margin-left: 6px; }
.survey-legend-value { display: flex; align-items: baseline; gap: 14px; margin-top: 4px; font-variant-numeric: tabular-nums; }
.survey-legend-value strong { font-size: 24px; color: #254b40; }
.survey-legend-value small { font-size: 12px; margin-left: 2px; }
.survey-legend-value > span { font-size: 13px; color: #63746c; }
.survey-orbits { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 14px; padding: 0; margin: 0; list-style: none; }
.survey-orbits li { background: #f7f9f7; border-radius: 14px; padding: 18px 12px; text-align: center; min-width: 0; }
.survey-option-ring { position: relative; width: 88px; height: 88px; padding: 7px; box-sizing: border-box; border-radius: 50%; margin: 0 auto 16px; background: conic-gradient(var(--option-color) var(--option-rate), #e4eae6 0); }
.survey-option-ring > div { position: absolute; inset: 7px; border-radius: 50%; background: #f7f9f7; display: flex; align-items: center; justify-content: center; }
.survey-option-ring strong { font-size: 21px; color: #254b40; }
.survey-option-ring small { font-size: 12px; }
.survey-orbit-caption { display: flex; align-items: baseline; justify-content: center; gap: 7px; text-align: left; font-size: 13px; line-height: 1.6; }
.survey-orbit-caption > span:last-child { overflow-wrap: anywhere; white-space: pre-wrap; }
.survey-panel .survey-orbit-count { margin: 10px 0 0; font-size: 22px; font-weight: 700; color: #254b40; }
.survey-orbit-count small { font-size: 12px; margin-left: 3px; font-weight: 400; }
.survey-orbit-count > span { display: block; font-size: 11px; font-weight: 400; color: #63746c; }
.survey-panel .survey-chart-note { font-size: 12px; color: #63746c; margin: 20px 0 0; }
.survey-written-results { padding: 0; margin: 0; list-style-position: inside; display: grid; gap: 12px; }
.survey-written-results li { background: #f6f8f4; border-left: 3px solid #9cbaa4; padding: 14px; border-radius: 4px; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.8; font-size: 14px; }
@media (max-width: 1000px) {
  .survey-results-overview { flex-direction: column; gap: 20px; padding: 18px; }
  .survey-result-totals { width: 100%; gap: 8px; }
  .survey-result-totals dd { font-size: 25px; }
}
@media (max-width: 760px) {
  .survey-result-question { padding: 16px; }
 .survey-distribution { grid-template-columns: 1fr; gap: 24px; }
  .survey-distribution-ring { width: 144px; height: 144px; justify-self: center; }
  .survey-orbits { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}
