:root {
  --ink: #183b38;
  --muted: #667673;
  --paper: #f6f7f2;
  --line: #dde5dd;
  --green: #21594b;
  --lime: #d5e6b4;
  --orange: #bc603d;
  --white: #fff;
  --shadow: 0 10px 35px #163d3909;
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: var(--ink);
  font-size: 14px;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--paper);
}
[hidden] {
  display: none !important;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
  border: 0;
  border-radius: 9px;
  background: var(--green);
  color: white;
  padding: 11px 17px;
  font-weight: 650;
  min-height: 42px;
  transition: filter 0.15s;
}
button:hover {
  filter: brightness(0.94);
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
button.quiet,
.secondary {
  background: #edf1e9;
  color: var(--ink);
}
button.small {
  padding: 7px 12px;
  min-height: 35px;
  font-size: 12px;
}
button.danger {
  background: #a24436;
}
a {
  color: var(--green);
  text-underline-offset: 3px;
}
input,
select,
textarea {
  width: 100%;
  border: 1px solid #cbd7cb;
  background: #fff;
  border-radius: 8px;
  padding: 11px;
  color: var(--ink);
}
textarea {
  min-height: 105px;
  resize: vertical;
}
input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--green);
}
input:focus,
select:focus,
textarea:focus,
button:focus-visible,
a:focus-visible {
  outline: 3px solid #b5d478;
  outline-offset: 2px;
}
label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 12px;
  font-weight: 650;
  margin-bottom: 16px;
}
label.check {
  flex-direction: row;
  align-items: flex-start;
  font-weight: 500;
  line-height: 1.5;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: 36px;
  letter-spacing: -1.4px;
  line-height: 1.18;
  margin-bottom: 10px;
  font-weight: 650;
}
h2 {
  font-size: 23px;
  letter-spacing: -0.65px;
  margin-bottom: 12px;
}
h3 {
  font-size: 16px;
  letter-spacing: -0.3px;
  margin-bottom: 10px;
}
p {
  line-height: 1.65;
  color: var(--muted);
}
.eyebrow {
  font-size: 10px;
  letter-spacing: 2px;
  font-weight: 750;
  color: #688270;
  margin-bottom: 18px;
}
.small {
  font-size: 12px;
}
.muted {
  color: var(--muted);
}
.wordmark {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 32px;
  font-weight: 750;
  letter-spacing: -2px;
}
.wordmark > span {
  font-size: 23px;
  letter-spacing: -1px;
}
.wordmark small {
  margin-left: 15px;
  font-size: 9px;
  letter-spacing: 2px;
  color: var(--muted);
}
.login-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  align-items: center;
  max-width: 1250px;
  margin: auto;
  padding: 70px;
  gap: 100px;
}
.login-story .wordmark {
  margin-bottom: 100px;
}
.login-story h1 {
  font-size: 58px;
  line-height: 1.08;
  letter-spacing: -2.6px;
}
.login-story > p {
  font-size: 17px;
  line-height: 1.8;
  margin-top: 25px;
}
.story-lines {
  display: grid;
  gap: 15px;
  margin-top: 40px;
  color: var(--green);
  font-size: 12px;
}
.story-lines span {
  border-top: 1px solid var(--line);
  padding-top: 12px;
  max-width: 330px;
}
.login-card {
  background: white;
  padding: 38px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: 18px;
}
.login-card > button {
  width: 100%;
  display: flex;
  justify-content: space-between;
  margin: 8px 0 22px;
}
.login-card h2 {
  font-size: 26px;
}
.login-card > p {
  font-size: 13px;
}
.login-card > label {
  margin-top: 20px;
}
#login-error {
  color: #a24436;
}
aside {
  position: fixed;
  inset: 0 auto 0 0;
  width: 236px;
  background: #143d38;
  color: #f7f9ef;
  display: flex;
  flex-direction: column;
  padding: 26px 18px;
}
.workspace-name {
  color: #b8cbc0;
  font-size: 11px;
  padding: 23px 9px 22px;
  border-bottom: 1px solid #36544d;
  line-height: 1.6;
}
.wordmark {
  padding: 0 8px;
}
nav {
  display: grid;
  gap: 5px;
  margin-top: 20px;
}
nav button {
  background: transparent;
  text-align: left;
  color: #c5d6cb;
  font-size: 13px;
  font-weight: 500;
  padding: 11px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}
nav button.active {
  background: #d9e9bd;
  color: #163d39;
  font-weight: 650;
}
nav button span {
  width: 20px;
  text-align: center;
  font-size: 17px;
}
nav button:hover {
  background: #31524a;
  color: white;
}
.sidebar-bottom {
  margin-top: auto;
  font-size: 12px;
  line-height: 1.8;
  padding: 20px 10px 0;
  color: #d5e3da;
}
.sidebar-bottom small {
  color: #8fb0a1;
  font-size: 10px;
}
.live-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: #c5e49d;
  border-radius: 50%;
  margin-right: 5px;
}
.shell {
  margin-left: 236px;
}
header {
  height: 78px;
  padding: 0 36px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fafbf7;
  font-size: 12px;
  color: var(--muted);
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.header-actions > span {
  font-size: 11px;
}
header button {
  font-size: 11px;
  padding: 7px 10px;
  min-height: 33px;
}
main {
  padding: 34px 36px;
  max-width: 1550px;
  margin: auto;
  min-height: calc(100vh - 130px);
}
.page-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 27px;
}
.page-head .eyebrow {
  margin-bottom: 10px;
}
.page-head p {
  margin-bottom: 0;
  font-size: 13px;
}
.page-head h1 {
  font-size: 33px;
}
.page-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 26px;
}
.stat {
  background: white;
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 22px;
  box-shadow: var(--shadow);
}
.stat label {
  font-size: 11px;
  color: var(--muted);
  font-weight: 500;
  margin-bottom: 14px;
}
.stat strong {
  font-size: 33px;
  font-weight: 620;
  letter-spacing: -1px;
  display: block;
}
.stat small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 7px;
}
.stat.featured {
  background: var(--lime);
  border-color: #cdddac;
}
.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 24px;
  box-shadow: var(--shadow);
  margin-bottom: 18px;
  min-width: 0;
}
.panel .panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}
.panel-head h2 {
  font-size: 18px;
  margin: 0;
}
.panel h3 {
  margin-bottom: 5px;
}
.panel p {
  font-size: 13px;
}
.empty {
  padding: 32px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  background: #fbfcf8;
  border: 1px dashed var(--line);
  border-radius: 9px;
}
.list-row {
  padding: 15px 0;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}
.list-row:first-child {
  border-top: 0;
}
.list-row p {
  margin: 5px 0 0;
  font-size: 12px;
}
.list-row h3 {
  font-size: 13px;
  margin: 0;
}
.badge {
  display: inline-block;
  background: #eaf2e6;
  color: #316047;
  border-radius: 5px;
  padding: 5px 8px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.35px;
  white-space: nowrap;
}
.badge.amber {
  background: #fbefd9;
  color: #8b6025;
}
.badge.red {
  background: #fae6e1;
  color: #a14b39;
}
.badge.gray {
  background: #eef0ed;
  color: #687871;
}
.notice {
  padding: 14px 17px;
  background: #eaf1e2;
  border-radius: 8px;
  color: #496446;
  font-size: 12px;
  line-height: 1.65;
  margin-bottom: 20px;
  border: 1px solid #dbe6d1;
}
.notice.warning {
  background: #fff4e6;
  color: #87602d;
  border-color: #eee0c6;
}
.notice.danger {
  background: #fae6e1;
  color: #914533;
  border-color: #efcec2;
}
.table-wrap {
  overflow-x: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 12px;
}
th {
  text-align: left;
  font-size: 9px;
  letter-spacing: 1px;
  color: var(--muted);
  font-weight: 700;
  padding: 12px 12px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
td {
  padding: 15px 12px;
  border-bottom: 1px solid #eef1eb;
  line-height: 1.6;
}
td:last-child {
  white-space: nowrap;
}
td strong {
  font-size: 12px;
}
td .muted {
  font-size: 11px;
}
.table-wrap.panel {
  padding: 8px 12px;
}
.toolbar {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
  align-items: center;
}
.toolbar input {
  max-width: 320px;
}
.toolbar select {
  max-width: 210px;
}
.module-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.module-grid label {
  padding: 12px;
  background: #f5f7f0;
  border: 1px solid #e1e8da;
  border-radius: 8px;
  font-size: 12px;
  margin: 0;
  align-items: center;
}
.metrics-line {
  display: flex;
  gap: 25px;
  margin: 15px 0;
  color: var(--muted);
  font-size: 11px;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 18px;
}
.form-grid .wide {
  grid-column: 1/-1;
}
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
  margin-top: 15px;
}
.form-error {
  color: #a24436;
  font-size: 12px;
  margin: 10px 0;
}
.detail-text {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  line-height: 1.75;
  font-size: 13px;
  color: #49615a;
}
.detail-section {
  margin: 20px 0;
}
.detail-section h3 {
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}
.actions {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
}
.search-result {
  border-top: 1px solid var(--line);
  padding: 16px 0;
}
.search-result h3 {
  font-size: 14px;
}
.search-result p {
  white-space: pre-wrap;
}
.progress {
  height: 6px;
  border-radius: 6px;
  background: #ebf0e7;
  margin: 12px 0;
}
.progress span {
  display: block;
  height: 100%;
  background: #719e61;
  border-radius: 6px;
}
.tenant-card {
  border-top: 3px solid #a8c283;
}
.tenant-card .module-grid {
  margin-top: 15px;
}
.tenant-card .badge {
  margin: 3px;
}
.ai-config {
  margin: 5px 0 22px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f8faf5;
}
.ai-config > .form-grid {
  gap: 0 14px;
}
.agent-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(280px, 0.75fr);
  gap: 18px;
  align-items: start;
}
.agent-chat {
  padding: 0;
  overflow: hidden;
}
.agent-messages {
  min-height: 330px;
  max-height: 58vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 24px;
  background: #fbfcf8;
}
.agent-message {
  max-width: min(82%, 680px);
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: 4px 13px 13px;
  background: white;
}
.agent-message.user {
  align-self: flex-end;
  border-radius: 13px 4px 13px 13px;
  border-color: #c7dab0;
  background: #e9f1da;
}
.agent-message span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
}
.agent-message p {
  margin: 0;
  color: var(--ink);
  white-space: pre-wrap;
}
.agent-proposal {
  margin: 0 24px 14px;
  padding: 17px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  border: 1px solid #ead8b9;
  border-radius: 10px;
  background: #fff7e9;
}
.agent-proposal h3,
.agent-proposal p {
  margin-bottom: 4px;
}
.agent-proposal .eyebrow {
  display: block;
  margin-bottom: 7px;
  color: #8b6025;
}
.agent-composer {
  padding: 18px 24px 24px;
  border-top: 1px solid var(--line);
}
.agent-composer textarea {
  min-height: 86px;
}
.agent-composer-foot {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
}
.agent-composer-foot small {
  line-height: 1.5;
}
.agent-guide {
  position: sticky;
  top: 96px;
}
.agent-guide ul {
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.8;
}
.agent-prompts {
  display: grid;
  gap: 8px;
}
.agent-prompts button {
  height: auto;
  text-align: left;
  line-height: 1.5;
}
.switches {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.meeting-block {
  margin: 28px 0;
}
.meeting-block > .panel-head {
  margin-bottom: 12px;
}
.meeting-block > .panel-head h2 {
  margin: 3px 0 0;
}
.agenda-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 12px;
}
.agenda-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 170px;
  border-top: 3px solid var(--green);
}
.agenda-card h3 {
  margin: 14px 0 6px;
}
.agenda-card p {
  color: var(--muted);
}
.agenda-builder-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 15px;
  margin-top: 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}
.agenda-builder-head h3 {
  margin: 3px 0 0;
}
.agenda-items {
  display: grid;
  gap: 10px;
}
.agenda-item-row {
  display: grid;
  grid-template-columns: 22px minmax(150px, 1fr) minmax(180px, 1.6fr) minmax(120px, .8fr) minmax(150px, 1fr) auto;
  gap: 10px;
  align-items: end;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fafbf8;
}
.agenda-item-row label {
  margin: 0;
  font-size: 11px;
}
.agenda-item-row textarea {
  min-height: 42px;
  height: 42px;
}
.agenda-drag {
  align-self: center;
  color: var(--muted);
}
.attendee-checks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 7px;
  margin-top: 6px;
}
.attendee-checks .check {
  margin: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fafbf8;
}
.agenda-detail-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 18px;
}
.agenda-detail-meta > div {
  display: grid;
  gap: 5px;
  padding: 12px;
  border-left: 3px solid var(--green);
  background: #f5f7f1;
}
.agenda-detail-meta span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .6px;
  text-transform: uppercase;
}
.agenda-preview {
  margin: 20px 0;
  border-top: 1px solid var(--line);
}
.agenda-preview article {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.agenda-preview article > span {
  color: var(--green);
  font-weight: 700;
}
.agenda-preview h3,
.agenda-preview p {
  margin: 0 0 5px;
}
.meeting-detail-head,
.minute-topic-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}
.modal-section-title {
  margin: 27px 0 12px;
  font-size: 18px;
}
.minute-topics {
  display: grid;
  gap: 10px;
}
.minute-topic {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfcf9;
}
.minute-topic h3 {
  margin: 0;
  font-size: 15px;
}
.minute-topic .detail-section {
  margin: 14px 0 0;
}
.signoff-panel {
  margin: 24px 0;
  padding: 18px;
  border: 1px solid #cfddc6;
  border-radius: 12px;
  background: #f2f7ec;
}
.signoff-panel h2 {
  margin-top: 0;
  font-size: 18px;
}
.ack-list {
  margin: 10px 0;
  padding: 10px 12px;
  background: #fff;
  border-radius: 8px;
}
.ack-list p {
  margin: 4px 0 0;
  white-space: pre-line;
}
.success-text {
  color: var(--green);
  font-weight: 700;
}
.transcript-details {
  margin: 20px 0;
  border-top: 1px solid var(--line);
  padding-top: 15px;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 28px;
  max-width: min(780px, 94vw);
  width: 730px;
  max-height: 90vh;
  box-shadow: 0 30px 100px #143d3830;
}
dialog::backdrop {
  background: #122a2666;
  backdrop-filter: blur(3px);
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: -28px;
  z-index: 3;
  margin: -12px 0 22px;
  padding: 12px 0;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.modal-head h2 {
  margin: 0;
}
#close-dialog {
  flex: 0 0 auto;
  min-width: 44px;
  min-height: 44px;
  margin-left: 16px;
  font-size: 17px;
}
dialog .notice {
  margin-top: 0;
}
.source-list {
  display: grid;
  gap: 12px;
}
.source-list article {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
}
#toast {
  position: fixed;
  inset: auto 24px 22px auto;
  margin: 0;
  max-width: 470px;
  border: 0;
  background: #173e38;
  color: #fff;
  padding: 17px 22px;
  border-radius: 10px;
  box-shadow: 0 8px 30px #0002;
  z-index: 20;
  line-height: 1.6;
  font-size: 13px;
}
footer {
  border-top: 1px solid var(--line);
  padding: 18px 36px;
  color: #89998f;
  font-size: 10px;
  display: flex;
  justify-content: space-between;
}
.skip {
  position: fixed;
  top: -100px;
  left: 10px;
  background: white;
  padding: 12px;
  z-index: 100;
}
.skip:focus {
  top: 10px;
}
.pill {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  background: #e5edda;
  color: #48603e;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}
.person-row {
  display: flex;
  gap: 12px;
  align-items: center;
}
.inline {
  display: flex;
  gap: 10px;
  align-items: center;
}
.module-hint {
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
  margin: 15px 0;
}
.recording {
  color: #a24436;
  font-weight: 650;
}
.loading {
  padding: 70px;
  text-align: center;
  color: var(--muted);
}
@media (max-width: 1150px) {
  .agent-layout {
    grid-template-columns: 1fr;
  }
  .agent-guide {
    position: static;
  }
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid.three {
    grid-template-columns: repeat(2, 1fr);
  }
  .login-page {
    gap: 45px;
    padding: 40px;
  }
  .login-story h1 {
    font-size: 46px;
  }
  aside {
    width: 210px;
  }
  .shell {
    margin-left: 210px;
  }
  main {
    padding: 25px;
  }
  header {
    padding: 0 25px;
  }
  .header-actions > span {
    display: none;
  }
}
@media (max-width: 760px) {
  .agent-messages {
    min-height: 260px;
    max-height: 50vh;
    padding: 18px;
  }
  .agent-message {
    max-width: 94%;
  }
  .agent-proposal {
    margin: 0 18px 14px;
    align-items: stretch;
    flex-direction: column;
  }
  .agent-proposal .actions button {
    flex: 1;
  }
  .agent-composer {
    padding: 17px 18px 20px;
  }
  .agent-composer-foot {
    align-items: stretch;
    flex-direction: column;
  }
  .login-page {
    display: block;
    padding: 25px;
  }
  .login-story .wordmark {
    margin-bottom: 35px;
  }
  .login-story h1 {
    font-size: 39px;
  }
  .story-lines {
    display: none;
  }
  .login-story {
    margin-bottom: 30px;
  }
  .login-card {
    padding: 25px;
  }
  aside {
    position: static;
    width: 100%;
    padding: 15px 18px;
  }
  .workspace-name {
    display: none;
  }
  .sidebar-bottom {
    display: none;
  }
  aside > .wordmark {
    font-size: 25px;
  }
  aside > .wordmark > span {
    font-size: 20px;
  }
  nav {
    display: flex;
    overflow: auto;
    scrollbar-width: thin;
    scrollbar-color: #8aab9a transparent;
    gap: 5px;
    margin-top: 12px;
    padding-bottom: 3px;
  }
  nav::-webkit-scrollbar { height: 4px; }
  nav::-webkit-scrollbar-thumb { background: #8aab9a; border-radius: 4px; }
  nav button {
    white-space: nowrap;
    flex-shrink: 0;
    padding: 8px 11px;
    font-size: 12px;
  }
  nav button span {
    display: none;
  }
  .shell {
    margin-left: 0;
  }
  header {
    height: 57px;
    padding: 0 18px;
    font-size: 11px;
  }
  main {
    padding: 25px 18px;
  }
  .page-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 15px;
  }
  .page-head h1 {
    font-size: 29px;
  }
  .stats {
    gap: 10px;
  }
  .stat {
    padding: 17px;
  }
  .stat strong {
    font-size: 27px;
  }
  .stat label {
    font-size: 10px;
  }
  .grid,
  .grid.three {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .panel {
    padding: 19px;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .module-grid {
    grid-template-columns: 1fr;
  }
  footer {
    padding: 17px 18px;
  }
  footer span {
    display: none;
  }
  dialog {
    padding: 20px;
  }
  #toast {
    left: 15px;
    right: 15px;
    bottom: 15px;
    max-width: none;
  }
  .header-actions {
    gap: 5px;
  }
  .toolbar {
    flex-wrap: wrap;
  }
  .toolbar input,
  .toolbar select {
    max-width: none;
  }
  .page-actions {
    width: 100%;
  }
  .page-actions button {
    flex: 1;
  }
  .list-row {
    align-items: flex-start;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* Scheduling: shared defaults first, exceptions revealed on demand. */
.schedule-intro {
  color: var(--muted);
  margin: 0 0 20px;
}
.schedule-section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 18px 0 14px;
}
.schedule-section-title h3 {
  margin: 0;
  font-size: 16px;
}
.schedule-section-title > span {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--green);
  color: white;
  font-size: 12px;
}
.schedule-pattern {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0;
  margin: 0 0 18px;
  border: 0;
}
.schedule-pattern legend {
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 600;
}
.schedule-pattern label {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 16px;
  margin: 0;
  cursor: pointer;
}
.schedule-pattern label:has(input:checked) {
  background: #e8f0e0;
  border-color: #275b4e;
}
.schedule-pattern input,
.schedule-days input {
  width: 16px;
  height: 16px;
  padding: 0;
  margin: 0;
  accent-color: #205b4d;
}
.schedule-slot {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px;
  margin-bottom: 14px;
  background: #fafcf8;
}
.slot-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}
.slot-heading h3 {
  margin: 0;
}
.day-picker {
  border: 0;
  padding: 0;
  margin: 0 0 16px;
  min-width: 0;
}
.day-picker legend {
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 8px;
}
.schedule-days {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.schedule-days label {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 8px 9px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: white;
  font-size: 12px;
  margin: 0;
  cursor: pointer;
}
.schedule-days label:has(input:checked) {
  background: #e2edda;
  border-color: #275b4e;
}
.schedule-days label:focus-within,
.schedule-pattern label:focus-within {
  outline: 2px solid #397c68;
  outline-offset: 2px;
}
.schedule-details {
  border-top: 1px solid var(--line);
  padding-top: 12px;
  margin: 8px 0 14px;
}
.schedule-details summary {
  cursor: pointer;
  color: #205b4d;
  font-size: 13px;
  font-weight: 600;
  padding: 4px 0;
}
.schedule-details[open] summary {
  margin-bottom: 14px;
}
.schedule-repeat {
  margin-top: 20px;
}
.schedule-preview {
  border-top: 1px solid var(--line);
  margin-top: 8px;
}
.schedule-totals {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: #eef3e8;
  border-radius: 12px;
  font-size: 13px;
}
.schedule-preview-list {
  padding: 0;
  list-style: none;
  margin: 12px 0;
}
.schedule-preview-list li {
  padding: 11px 4px;
  border-bottom: 1px solid var(--line);
}
.schedule-preview-list strong,
.schedule-preview-list span,
.schedule-preview-list small {
  display: block;
}
.schedule-preview-list span {
  margin-top: 3px;
  font-size: 13px;
}
.schedule-preview-list small {
  color: var(--muted);
  margin-top: 4px;
}
.schedule-preview-list .schedule-conflict {
  border-left: 3px solid #bd4232;
  padding-left: 12px;
  background: #fff8f4;
}
@media (max-width: 520px) {
  .schedule-slot {
    padding: 12px;
  }
  .schedule-days {
    gap: 5px;
  }
  .schedule-days label {
    padding: 9px 7px;
  }
}
.schedule-pattern label,
.schedule-days label {
  flex-direction: row;
}
body:has(dialog[open]) {
  overflow: hidden;
}
.schedule-days label {
  min-height: 44px;
}
@media (max-width: 700px) {
  .modal-head {
    top: -20px;
  }
  .agenda-detail-meta {
    grid-template-columns: 1fr;
  }
  .agenda-item-row {
    grid-template-columns: 1fr;
  }
  .agenda-drag {
    display: none;
  }
}

/* Visit evidence: clear completion criteria and an explicit review handoff. */
.visit-summary {
  display: grid;
  gap: 7px;
  padding: 18px;
  margin-bottom: 20px;
  background: #f3f6ef;
  border-radius: 12px;
  overflow-wrap: anywhere;
}
.visit-summary > span {
  font-size: 13px;
  color: var(--muted);
}
.review-readiness {
  border: 1px solid #d9dfd1;
  background: #fafbf7;
  border-radius: 12px;
  padding: 18px;
  margin: 18px 0;
}
.review-readiness.ready {
  background: #eef6ef;
  border-color: #b6d0ba;
}
.review-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.review-heading h3 {
  margin: 0;
  font-size: 15px;
}
.review-heading > span {
  font-size: 12px;
  white-space: nowrap;
  color: var(--muted);
}
.review-readiness ul {
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
  display: grid;
  gap: 14px;
}
.review-readiness li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.review-mark {
  display: grid;
  place-items: center;
  flex: 0 0 24px;
  height: 24px;
  border-radius: 50%;
  background: #f4ead9;
  color: #77541f;
}
.complete .review-mark {
  background: #d8eadc;
  color: #205b4d;
}
.review-readiness li strong,
.review-readiness li div > span {
  display: block;
  font-size: 13px;
}
.review-readiness li div > span {
  margin-top: 3px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
}
.note-section {
  padding: 4px 0 18px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.note-section h3 {
  font-size: 16px;
  margin: 10px 0;
}
.field-help {
  margin: -7px 0 18px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}
.attendance-help {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: space-between;
}
.attendance-help button {
  flex-shrink: 0;
}
.visit-note-form textarea[name="note"] {
  min-height: 150px;
}
.note-actions {
  position: sticky;
  bottom: -28px;
  padding: 14px 0;
  background: white;
  z-index: 1;
}
.visit-primary-actions {
  margin: 20px 0;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
@media (max-width: 700px) {
  .note-actions {
    bottom: -20px;
    flex-wrap: wrap;
  }
  .note-actions button {
    flex: 1 1 160px;
    min-height: 44px;
  }
  .review-readiness {
    padding: 14px;
  }
  .attendance-help {
    align-items: flex-start;
  }
}
.review-readiness li > div {
  min-width: 0;
  overflow-wrap: anywhere;
}
.signal-preview {
  margin-bottom: 22px;
  border-left: 4px solid var(--orange);
}
.signal-preview .eyebrow,
.briefing-panel .eyebrow {
  display: block;
  margin-bottom: 7px;
}
.signal-preview-list {
  display: grid;
  gap: 8px;
}
.signal-preview-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  border-top: 1px solid var(--line);
}
.signal-preview-item > span:nth-child(2) {
  flex: 1;
  font-weight: 650;
}
.signal-dot {
  flex: 0 0 10px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #8ba69b;
}
.signal-dot.urgent { background: #b64e3a; }
.signal-dot.soon { background: #d99b45; }
.signal-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(260px, 1fr);
  gap: 20px;
  align-items: start;
}
.signal-filter-label {
  margin: 0;
  min-width: 155px;
}
.signal-filter-label select { margin-top: 3px; }
.signal-item {
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr) auto;
  align-items: center;
  gap: 17px;
  border-top: 1px solid var(--line);
  padding: 18px 0;
}
.signal-item h3 { margin: 8px 0 3px; }
.signal-item p { margin: 0; }
.briefing-panel { position: sticky; top: 20px; }
.briefing-result {
  margin: 20px 0;
  padding: 18px;
  border-radius: 10px;
  background: #edf3e6;
}
.briefing-result ol { padding-left: 20px; line-height: 1.55; }
@media (max-width: 900px) {
  .signal-layout { grid-template-columns: 1fr; }
  .briefing-panel { position: static; }
}
@media (max-width: 540px) {
  .signal-item { grid-template-columns: 10px minmax(0, 1fr); }
  .signal-item button { grid-column: 2; justify-self: start; }
  .signal-preview-item { flex-wrap: wrap; }
}
