:root {
  font-family: Inter, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #1b2926;
  background: #f5f6f1;
  font-size: 15px;
  line-height: 1.6;
  --green: #15634e;
  --line: #dce3da;
  --muted: #63756d;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
textarea,
select {
  font: inherit;
}
button,
a,
input,
textarea,
select {
  touch-action: manipulation;
}
button {
  cursor: pointer;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  padding: 9px 15px;
  color: inherit;
}
button:hover {
  border-color: var(--green);
  background: #edf4ed;
}
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 3px solid #dba748;
  outline-offset: 3px;
}
.primary {
  background: var(--green);
  color: white;
  border-color: var(--green);
}
.primary:hover {
  background: #0e4c3a;
  color: white;
}
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 22px 5vw;
  border-bottom: 1px solid var(--line);
  background: #fff;
}
.brand {
  font-size: 20px;
  text-decoration: none;
  color: inherit;
  font-weight: 700;
}
.brand span {
  font-size: 12px;
  color: var(--muted);
  font-weight: 400;
  margin-left: 12px;
}
.intro {
  max-width: 1200px;
  margin: 36px auto 26px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.eyebrow {
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--green);
  font-weight: 700;
}
h1 {
  font-size: 32px;
  letter-spacing: -1px;
  margin: 5px 0;
}
h2 {
  font-size: 20px;
  margin: 0 0 14px;
}
h3 {
  margin: 0 0 8px;
}
.intro p {
  margin: 5px 0;
  color: var(--muted);
}
#notice {
  max-width: 1152px;
  margin: 12px auto;
  padding: 12px 18px;
  border-radius: 10px;
  background: #e9efe2;
  min-height: 46px;
}
#notice.error {
  background: #fff0eb;
  color: #95351e;
}
nav {
  max-width: 1152px;
  margin: 20px auto;
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}
nav button {
  border: 0;
  background: none;
  min-width: 80px;
}
nav button[aria-selected="true"] {
  background: #dce9dd;
  color: #164d3b;
  font-weight: 700;
}
main {
  max-width: 1200px;
  margin: auto;
  padding: 0 24px;
}
.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 22px;
  min-height: 370px;
}
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.toolbar input {
  max-width: 320px;
}
.toolbar label {
  display: flex;
  align-items: center;
  gap: 10px;
}
.workspace {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 26px;
}
aside {
  border-right: 1px solid var(--line);
  padding-right: 18px;
  max-height: 980px;
  overflow: auto;
}
.post-card {
  display: block;
  width: 100%;
  text-align: left;
  padding: 16px;
  margin-bottom: 10px;
  background: #fafbf7;
}
.post-card.selected {
  border-color: var(--green);
  background: #edf4ed;
}
.post-card strong {
  display: block;
  overflow-wrap: anywhere;
}
.post-card small,
.muted {
  color: var(--muted);
  font-size: 12px;
}
.empty {
  padding: 45px 10px;
  text-align: center;
  color: var(--muted);
}
label {
  display: block;
  margin: 10px 0 6px;
  color: #4b6054;
  font-size: 13px;
  font-weight: 600;
}
input,
textarea,
select {
  border: 1px solid #cbd6cc;
  border-radius: 8px;
  background: #fff;
  color: #213b2b;
  padding: 10px;
  max-width: 100%;
}
input:not([type="checkbox"]),
textarea {
  width: 100%;
}
textarea {
  resize: vertical;
  min-height: 90px;
}
#body {
  min-height: 230px;
}
.checks {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.checks label {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  font-weight: 400;
}
.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 20px;
}
.editor-head {
  display: flex;
  gap: 15px;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}
.media {
  background: #f5f6f1;
  border-radius: 8px;
  padding: 12px;
  color: var(--muted);
  font-size: 13px;
}
.preview {
  border: 1px solid var(--line);
  border-left: 4px solid var(--green);
  border-radius: 9px;
  padding: 16px;
  margin: 18px 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: #f9fbf7;
}
.card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  margin: 12px 0;
}
.button-fields {
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
  margin-bottom: 14px;
}
.button-fields select {
  width: 100%;
}
.card-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: start;
}
.badge {
  display: inline-block;
  font-size: 12px;
  border-radius: 20px;
  padding: 4px 10px;
  background: #edf2e7;
  white-space: nowrap;
}
.badge.uncertain,
.badge.failed {
  background: #ffeae0;
  color: #923c20;
}
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}
.metrics {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
.metric strong {
  display: block;
  font-size: 28px;
}
.metric span {
  font-size: 12px;
  color: var(--muted);
}
dialog {
  width: min(640px, calc(100vw - 28px));
  border: 1px solid var(--line);
  border-radius: 16px;
  max-height: 88vh;
  overflow: auto;
  padding: 26px;
  color: inherit;
}
dialog::backdrop {
  background: #17291e70;
}
dialog .preview {
  max-height: 280px;
  overflow: auto;
}
.danger {
  color: #a33e26;
}
footer {
  max-width: 1200px;
  margin: 24px auto;
  padding: 0 24px 24px;
  font-size: 12px;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
}
.error-text {
  color: #a33e26;
}
.grid-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.grid-table th,
.grid-table td {
  text-align: left;
  padding: 7px;
  border-bottom: 1px solid var(--line);
}
[hidden] {
  display: none !important;
}
@media (max-width: 720px) {
  header {
    padding: 16px;
  }
  .brand span {
    display: none;
  }
  .intro {
    margin: 22px 0;
    padding: 0 16px;
  }
  .intro h1 {
    font-size: 25px;
  }
  .intro p:not(.eyebrow) {
    font-size: 13px;
  }
  .intro .primary {
    white-space: nowrap;
    padding: 9px;
  }
  #notice,
  nav {
    margin: 12px 16px;
  }
  nav {
    justify-content: space-between;
    gap: 0;
  }
  nav button {
    min-width: 0;
    padding: 8px 13px;
  }
  main {
    padding: 0 12px;
  }
  .panel {
    padding: 15px;
  }
  .workspace {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  aside {
    border: 0;
    border-bottom: 1px solid var(--line);
    padding: 0 0 8px;
    max-height: 210px;
  }
  .post-card {
    padding: 10px;
  }
  .row {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .toolbar {
    align-items: stretch;
    flex-direction: column;
    gap: 8px;
  }
  .toolbar input {
    max-width: 100%;
  }
  .actions button {
    flex: 1 1 auto;
  }
  .card-header {
    flex-wrap: wrap;
  }
  footer {
    padding: 0 16px 18px;
    display: block;
  }
  footer span {
    display: block;
  }
}
.article-editor {
  min-width: 0;
}
.article-editor select {
  width: 100%;
}
.article-table-row {
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
}
.cleanup-card {
  border-top: 1px solid var(--line);
  margin-top: 16px;
  padding-top: 12px;
  overflow-wrap: anywhere;
}
.cleanup-card button {
  margin: 6px 6px 0 0;
}
.calendar-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px;
  margin: 16px 0;
}
.calendar-days .weekday {
  text-align: center;
  color: var(--muted);
}
.calendar-days button {
  padding: 6px 2px;
  min-height: 54px;
}
.calendar-days strong,
.calendar-days small {
  display: block;
}
.calendar-days button[aria-pressed="true"] {
  border-color: var(--green);
  background: #edf4ed;
}
.calendar-days .calendar-attention {
  color: #923c20;
}
