:root {
  color-scheme: only light;
  --paper: #fff9ee;
  --ink: #101d38;
  --muted: #485269;
  --line: #d4cdbf;
  --wash: #e1e8ff;
  --accent: #083abf;
  --accent2: #855400;
  --sans: Inter, system-ui, sans-serif;
  --serif: var(--sans);
  --gold: #fbe3a8;
}
body { min-width: 0; }
.app-shell { max-width: 1040px; padding: 0 clamp(16px, 4vw, 38px); }
.mast { position: relative; padding-top: 6px; }
.mast-top { border: 0; padding: 0 84px 2px 0; }
.wordmark { font: 750 25px/1 Georgia, serif; gap: 8px; min-height: 54px; }
.brand-mark { object-fit: contain; flex: none; mix-blend-mode: multiply; }
.mast nav { display: flex; gap: clamp(8px, 4vw, 28px); width: auto; justify-content: flex-start; border-bottom: 1px solid var(--ink); }
.mast .nav-link { font-size: 14px; padding: 8px 7px; min-height: 44px; border-bottom: 3px solid transparent; }
.mast .nav-link[aria-current="page"] { color: var(--accent); border-color: var(--accent); }
.app-menu { position: absolute; z-index: 5; right: 0; top: 12px; }
.app-menu summary { cursor: pointer; font-weight: 750; min-height: 44px; padding: 9px 4px 8px 9px; }
.app-menu .menu-panel { position: absolute; right: 0; top: 48px; width: min(290px, 85vw); padding: 16px; background: var(--paper); border: 1px solid var(--line); border-radius: 9px; box-shadow: 0 8px 24px #101d3820; }
.menu-panel > * { display: block; margin-bottom: 10px; }
.demo-actor select { margin-top: 6px; }
#main { min-width: 0; }
.primary-action { background: var(--accent); color: #fff; border: 1px solid var(--accent); border-radius: 9px; min-height: 48px; }
.primary-action:hover:not(:disabled) { background: #062b8f; color: #fff; }
.new-hero { padding: 29px 0 26px; }
.new-hero h1 { font-size: clamp(64px, 18vw, 102px); line-height: .86; font-weight: 900; letter-spacing: -.085em; margin-bottom: 20px; }
.new-hero p { font-size: clamp(17px, 4.5vw, 23px); line-height: 1.3; max-width: 34ch; margin: 0 0 26px; }
.hero-action { display: flex; justify-content: center; gap: 22px; align-items: center; width: min(100%, 400px); padding: 10px 14px; font-size: clamp(21px, 6vw, 29px); font-weight: 850; min-height: 58px; }
.hero-create { display: block; margin-top: 12px; }
.current-meetings { border-top: 1px solid var(--ink); max-width: 560px; }
.current-meetings h2 { font-size: 26px; letter-spacing: -.045em; font-weight: 850; margin: 12px 0 10px; }
.current-meeting { display: block; border-top: 1px solid var(--line); text-align: left; width: 100%; padding: 11px 0 9px 10px; border-left: 5px solid #d89b20; }
.current-heading { display: flex; justify-content: space-between; gap: 8px; align-items: center; font-size: 22px; letter-spacing: -.04em; line-height: 1.13; }
.current-meta { display: flex; align-items: center; gap: 8px; font-size: 15px; margin-top: 5px; }
.state-chip { display: inline-block; width: max-content; max-width: 100%; border-radius: 99px; color: #422d0e; background: var(--gold); padding: 3px 10px; font-weight: 750; font-size: 13px; }
.date-strip { margin-top: 12px; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 7px; }
.date-strip > span { text-align: center; background: #f6eddd; padding: 8px 0; border-radius: 8px; color: var(--ink); }
.date-strip small { display: block; font-weight: 750; line-height: 1.2; }
.date-strip strong { display: block; font-size: 42px; font-weight: 900; line-height: 1.08; letter-spacing: -.09em; }
.page-lead { padding: 26px 0 18px; }
.page-lead h1, .poll-title h1 { font-weight: 850; letter-spacing: -.065em; }
.page-lead h1 { font-size: clamp(41px, 11vw, 64px); margin-bottom: 9px; }
.page-lead p { margin-bottom: 0; max-width: 56ch; }
.my-toolbar { margin: 10px 0 30px; }
.view-switch { border-radius: 7px; overflow: hidden; border: 1px solid var(--line); padding: 0; }
.view-switch button { min-height: 44px; min-width: 76px; font-size: 14px; padding: 5px 11px; }
.view-switch button.selected { background: var(--accent); color: #fff; }
.timeline { max-width: 620px; }
.timeline-item { position: relative; display: grid; grid-template-columns: minmax(57px, .22fr) 1fr 16px; align-items: center; gap: 10px; text-align: left; width: calc(100% - 9px); margin-left: 9px; padding: 17px 0 19px 14px; border-top: 1px solid var(--line); border-left: 2px solid var(--ink); }
.timeline-item::before { content: ""; position: absolute; left: -10px; top: -2px; width: 14px; height: 14px; border: 3px solid #b57900; background: var(--paper); border-radius: 50%; }
.timeline-item.is-fixed::before { border-color: var(--accent); }
.timeline-date strong { display: block; font-size: 45px; line-height: .96; font-weight: 900; letter-spacing: -.085em; }
.timeline-date small { display: block; font-size: 11px; overflow-wrap: anywhere; margin-top: 4px; }
.timeline-text { display: grid; gap: 3px; min-width: 0; }
.timeline-text strong { font-size: clamp(18px,5.1vw,24px); line-height: 1.12; letter-spacing: -.04em; overflow-wrap: anywhere; }
.timeline-text small { font-size: 15px; }
.is-fixed .state-chip { background: var(--wash); color: #10244f; }
.foot-note { max-width: 66ch; font-size: 13px; }
.event-back { min-height: 49px; display: flex; align-items: center; padding-right: 75px; }
.back-link { min-height: 44px; padding-left: 0; font-weight: 700; }
.poll-intro { display: block; padding: 5px 0 0; border: 0; }
.poll-title h1 { font-size: clamp(27px, 8vw, 50px); margin: 0 0 4px; overflow-wrap: anywhere; }
.poll-title p { font-size: 15px; margin: 0 0 5px; }
.poll-tools { min-height: 0; padding: 2px 0; border: 0; font-size: 13px; gap: 6px; }
.poll-tools button { min-height: 40px; }
.screen-tabs { border-bottom: 1px solid var(--ink); margin: 0 0 12px; justify-content: stretch; gap: 6px; }
.screen-tabs button { flex: 1; min-height: 44px; padding: 5px 6px; font-size: 14px; }
.screen-tabs button.active { color: var(--accent); border-color: var(--accent); }
.answer-layout { display: block; max-width: 620px; padding: 0; }
.answer-progress { font-size: 13px; color: var(--muted); margin: 0 0 7px; }
.date-toolbar { margin: 0 0 5px; }
.date-toolbar .view-switch { flex-shrink: 0; }
.date-toolbar .text-toggle { min-height: 44px; }
.calendar-top { margin: 3px 0 0; }
.calendar-top button { min-width: 44px; min-height: 44px; }
.calendar-top strong { text-transform: capitalize; }
.cal-grid { gap: 0; border-left: 1px solid var(--line); grid-template-columns: repeat(7,minmax(0,1fr)); }
.cal-grid .weekday { padding: 6px 0; font-size: 12px; font-weight: 750; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.cal-grid .cal-date, .cal-grid .cal-blank { display: grid; place-items: center; min-height: 44px; min-width: 0; border: 0; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); border-radius: 0; }
.cal-grid .cal-date { position: relative; background: transparent; color: var(--ink); font-weight: 750; }
.cal-grid .cal-date:disabled { opacity: .64; }
.cal-grid .cal-date.proposed, .cal-grid .cal-date.proposed:hover { background: var(--wash); color: var(--ink); }
.cal-grid .cal-date.vote-yes { background: #d9e9dd; }
.cal-grid .cal-date.vote-maybe { background: #f4e6bd; }
.cal-grid .cal-date.vote-no { background: #eed9d3; }
.cal-grid .cal-date.is-selected, .cal-grid .cal-date.is-selected:hover { background: var(--accent); color: #fff; box-shadow: inset 0 0 0 2px var(--accent), inset 0 0 0 4px #fff; border-radius: 7px; z-index: 1; }
.cal-grid .cal-date.is-today span { text-decoration: underline; }
.picked-date { margin: 11px 0; padding: 10px 0 0; border-top: 1px solid var(--line); }
.picked-date h3 { margin: 0 0 9px; font-size: clamp(19px, 5.4vw, 26px); text-transform: capitalize; letter-spacing: -.04em; }
.vote-controls { gap: 6px; }
.vote-controls .vote-pick { border-radius: 7px; min-height: 44px; padding-inline: 3px; }
.vote-controls .vote-pick.current { background: var(--accent); color: #fff; border-color: var(--accent); }
.answer-save { display: grid; gap: 6px; margin: 15px 0; }
.answer-save label { font-size: 14px; font-weight: 750; }
.answer-save input { width: 100%; }
.answer-save .primary-action { margin-top: 3px; }
.answer-save .destructive-link { justify-self: start; min-height: 42px; }
.period-area { padding: 11px 0; margin: 17px 0; }
.period-area summary { cursor: pointer; font-weight: 750; min-height: 38px; }
.matrix-section { border: 0; margin: 0; padding: 0; }
.matrix-section h2 { font-size: clamp(30px, 8.5vw, 43px); font-weight: 850; letter-spacing: -.065em; margin: 6px 0 0; }
.matrix-section > p { margin: 0; }
.matrix-legend { display: flex; flex-wrap: wrap; column-gap: 14px; row-gap: 4px; list-style: none; margin: 7px 0 14px; padding: 0; font-size: 14px; }
.matrix-legend b { display: inline-block; min-width: 18px; font-size: 17px; background: none; text-align: center; }
.matrix-viewport { border: 1px solid var(--line); border-radius: 8px; }
.matrix-viewport table.matrix-compact { min-width: 0; table-layout: fixed; }
.matrix-viewport .matrix-compact th:first-child { min-width: 0; width: 32%; overflow-wrap: anywhere; }
.matrix-viewport td, .matrix-viewport th { padding: 8px 4px; }
.matrix-viewport tbody td { background: transparent; font-size: 17px; font-weight: 850; }
.matrix-viewport tfoot { background: #f4eee3; }
.best-summary { background: var(--wash); max-width: 620px; padding: 12px 15px; margin: 14px 0 22px; border-radius: 8px; }
.best-summary p { margin: 0; font-weight: 850; font-size: 20px; }
.results-layout { margin-top: 25px; }
.bottom { margin-top: 36px; }
@media (min-width: 730px) {
  .new-hero { padding: 38px 0; }
  .view-home main { display: grid; grid-template-columns: 1fr minmax(300px, .85fr); gap: 38px; align-items: start; }
  .current-meetings { margin-top: 49px; }
}
@media (max-width: 360px) {
  .app-shell { padding-inline: 12px; }
  .mast .nav-link { padding-inline: 4px; font-size: 13px; }
  .wordmark { font-size: 22px; }
  .date-toolbar .text-toggle { max-width: 115px; text-align: right; }
  .view-switch button { min-width: 66px; padding-inline: 7px; }
  .cal-grid .cal-date, .cal-grid .cal-blank { min-height: 41px; }
}

/* Keep the approved light surfaces readable in dark browser environments. */
#app { color: var(--ink); }
#app :is(h1, h2, h3, p, label, table) { color: var(--ink); }
#app :is(.quiet, .subtle, .foot-note, .answer-progress) { color: var(--muted); }
#app :is(.best-summary, .best-summary strong, .best-summary p, .best-summary small,
  .result-date strong, .result-line .score, .matrix-viewport th, .matrix-viewport tfoot td) {
  color: var(--ink);
}
#app .result-line .score::after { color: inherit; }

.share-dialog { min-width: 0; width: min(480px, 76vw); }
.share-dialog textarea { min-height: 0; }
.share-dialog .dialog-actions { flex-wrap: wrap; }

.editable-dates { list-style: none; padding: 0; margin: 12px 0; }
.editable-dates li { display: flex; gap: 8px; align-items: center; justify-content: space-between; padding: 5px 0; border-bottom: 1px solid var(--line); }
.editable-dates button { flex: none; }
.date-editor-add { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.date-editor-add input { min-width: 0; max-width: 100%; }

.response-intro { max-width: 460px; padding: 12px 0 24px; }
.response-intro h2 { margin-bottom: 14px; }
.response-intro p { margin: 14px 0 9px; }
.response-intro .primary-action { display: block; width: 100%; margin-top: 14px; }
