:root {
  --ink: #253552;
  --text: #283b4d;
  --muted: #6d7c8e;
  --paper: #f2f5f8;
  --white: #fff;
  --line: #dfe6ed;
  --teal: #177a70;
  --teal-soft: #e8f4f0;
  --amber: #956320;
  --amber-soft: #fff3de;
  --red: #a64040;
  --body:
    "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
  --display: "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --mono: "SFMono-Regular", Consolas, monospace;
}
* {
  box-sizing: border-box;
}
html {
  color-scheme: light;
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--body);
  font-size: 14px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
button,
input,
textarea,
select {
  font: inherit;
}
button,
a,
input,
textarea {
  touch-action: manipulation;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: wait;
  opacity: 0.55;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid #4c8da5;
  outline-offset: 4px;
}
a {
  color: var(--teal);
  text-underline-offset: 4px;
}
[hidden] {
  display: none !important;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1,
h2,
h3 {
  font-family: var(--display);
  color: var(--ink);
  line-height: 1.45;
}
h1 {
  font-size: 27px;
  font-weight: 650;
}
h2 {
  font-size: 22px;
  font-weight: 650;
}
h3 {
  font-size: 15px;
  font-weight: 650;
}
textarea,
input {
  min-width: 0;
}
input,
textarea {
  border: 1px solid #ccd6e0;
  background: var(--white);
  color: var(--text);
  border-radius: 7px;
  padding: 10px 12px;
}
textarea {
  resize: vertical;
}
input::placeholder,
textarea::placeholder {
  color: #83909c;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: 7px;
  padding: 8px 15px;
  text-decoration: none;
  font-weight: 550;
  line-height: 1.5;
  white-space: nowrap;
}
.button.primary {
  background: var(--ink);
  color: var(--white);
}
.button.primary:hover {
  background: #364b6c;
}
.button.secondary {
  background: var(--white);
  border-color: #ccd6e0;
  color: var(--ink);
}
.button.secondary:hover {
  background: #f5f8fa;
}
.button.quiet {
  background: transparent;
  color: var(--muted);
}
.button.quiet:hover {
  background: #e9eff4;
  color: var(--ink);
}
.button.icon-button {
  width: 42px;
  padding: 6px;
  background: transparent;
  border-color: var(--line);
  color: var(--muted);
  font-size: 23px;
}
.eyebrow {
  color: var(--muted);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.13em;
}
.muted {
  color: var(--muted);
}
.skip-link {
  position: fixed;
  top: -100px;
  left: 16px;
  background: var(--white);
  z-index: 100;
  padding: 10px;
}
.skip-link:focus {
  top: 10px;
}
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 78px;
  padding: 0 max(28px, calc((100vw - 1440px) / 2));
  background: var(--white);
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--ink);
  text-decoration: none;
  font-size: 15px;
  font-weight: 650;
}
.brand-symbol,
.brand-mark {
  font-family: var(--display);
  letter-spacing: -0.09em;
  font-weight: 800;
  color: var(--ink);
}
.brand-symbol {
  font-size: 26px;
  padding-right: 18px;
  border-right: 1px solid var(--line);
}
.brand-symbol span,
.brand-mark span {
  color: var(--teal);
  padding: 0 3px;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.notification-dot {
  width: 6px;
  height: 6px;
  background: var(--amber);
  border-radius: 100%;
}
.workspace {
  display: grid;
  grid-template-columns: 350px minmax(0, 1fr);
  max-width: 1440px;
  margin: 30px auto 0;
  min-height: calc(100vh - 178px);
  padding: 0 28px;
  gap: 26px;
}
.task-sidebar {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.sidebar-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1px 2px 21px;
}
.sidebar-heading h1 {
  margin-top: 4px;
}
.count {
  font-size: 15px;
  font-family: var(--mono);
  font-weight: 400;
  color: var(--muted);
  padding-left: 8px;
}
.search-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
}
.search-wrap span {
  font-size: 25px;
  color: var(--muted);
  line-height: 1;
}
.search-wrap input {
  border: 0;
  background: transparent;
  width: 100%;
  padding: 11px 3px;
  font-size: 13px;
}
.filters {
  display: flex;
  gap: 4px;
  margin: 16px 0 20px;
  flex-wrap: wrap;
}
.filter {
  border: 0;
  background: transparent;
  border-radius: 6px;
  font-size: 12px;
  color: var(--muted);
  padding: 7px 11px;
  min-height: 36px;
}
.filter.active {
  background: #e0e8f1;
  color: var(--ink);
  font-weight: 650;
}
.filter span {
  margin-left: 5px;
  font-family: var(--mono);
  font-size: 11px;
}
.task-list {
  display: grid;
  align-content: start;
  gap: 10px;
}
.task-item {
  position: relative;
  text-align: left;
  width: 100%;
  border: 1px solid var(--line);
  background: var(--white);
  padding: 17px 19px 16px;
  border-radius: 9px;
  color: var(--text);
}
.task-item:hover {
  border-color: #b3c6d6;
}
.task-item.selected {
  border-color: #66859d;
  box-shadow: 0 3px 12px #243b5310;
}
.task-item.selected::before {
  position: absolute;
  content: "";
  left: -1px;
  top: 20px;
  bottom: 20px;
  width: 3px;
  border-radius: 4px;
  background: var(--teal);
}
.task-item-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 9px;
}
.project-label {
  font-size: 11px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  border-radius: 4px;
  padding: 2px 7px;
  background: #eaf0f7;
  color: #537088;
  white-space: nowrap;
  font-weight: 550;
}
.badge::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
}
.badge.attention {
  background: var(--amber-soft);
  color: var(--amber);
}
.badge.review,
.badge.done {
  background: var(--teal-soft);
  color: var(--teal);
}
.badge.failed {
  background: #fbe9e8;
  color: var(--red);
}
.badge.paused {
  background: #eef0f3;
  color: var(--muted);
}
.task-item h2 {
  font-size: 15px;
  line-height: 1.65;
  margin-bottom: 7px;
}
.task-item-summary {
  font-size: 12px;
  line-height: 1.75;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.task-item-footer {
  margin-top: 14px;
  display: flex;
  justify-content: space-between;
  color: #84909d;
  font-size: 10px;
}
.task-item-arrow {
  font-size: 16px;
  color: var(--teal);
}
.runtime {
  margin-top: auto;
  padding: 26px 4px 8px;
  font-size: 11px;
  line-height: 1.8;
  color: var(--muted);
}
.runtime-title {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: #5c7184;
  margin-bottom: 4px;
}
.runtime-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #9ca9b4;
}
.runtime-dot.online {
  background: var(--teal);
}
.runtime-dot.warning {
  background: var(--amber);
}
.runtime-error {
  color: var(--red);
  overflow-wrap: anywhere;
}
.task-detail {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 11px;
  min-height: 650px;
  overflow: hidden;
  align-self: start;
}
.detail-header {
  padding: 27px 32px 25px;
  border-bottom: 1px solid var(--line);
}
.detail-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 15px;
}
.detail-meta .project-label {
  font-size: 12px;
}
.detail-header h2 {
  font-size: 25px;
  line-height: 1.55;
  letter-spacing: -0.02em;
  overflow-wrap: anywhere;
}
.detail-summary {
  margin-top: 12px;
  color: #697b8b;
  font-size: 14px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.detail-subline {
  font-size: 11px;
  color: #8a98a5;
  margin-top: 16px;
}
.detail-body {
  padding: 28px 32px;
}
.decision-box {
  border-left: 3px solid #c49b58;
  background: #fffaf0;
  padding: 17px 20px;
  margin-bottom: 26px;
  border-radius: 0 7px 7px 0;
}
.decision-box h3 {
  color: #8e632c;
  margin-bottom: 9px;
}
.decision-box p,
.decision-box li {
  color: #66513a;
}
.detail-section + .detail-section {
  margin-top: 26px;
}
.detail-section h3 {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 11px;
}
.section-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #edf3f7;
  color: #6d879b;
  font-family: var(--mono);
  font-size: 11px;
  border-radius: 4px;
  width: 21px;
  height: 21px;
}
.section-mark.done {
  background: var(--teal-soft);
  color: var(--teal);
}
.content-text {
  font-size: 14px;
  line-height: 1.95;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.detail-section ul,
.decision-box ul {
  padding-left: 18px;
  margin: 0;
}
.detail-section li,
.decision-box li {
  padding: 3px 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.preview-row {
  margin-top: 22px;
  display: flex;
  align-items: center;
  gap: 13px;
  flex-wrap: wrap;
}
.preview-note {
  font-size: 11px;
  color: var(--muted);
}
.chat-details {
  margin-top: 29px;
  border-top: 1px solid var(--line);
  padding-top: 21px;
}
.chat-details summary,
.technical-details summary {
  cursor: pointer;
  list-style: none;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 34px;
}
.chat-details summary::-webkit-details-marker,
.technical-details summary::-webkit-details-marker {
  display: none;
}
.chat-details summary::after,
.technical-details summary::after {
  content: "＋";
  color: var(--muted);
  font-size: 17px;
}
.chat-details[open] summary::after,
.technical-details[open] summary::after {
  content: "−";
}
.chat-count {
  font-size: 11px;
  font-weight: 400;
  color: var(--muted);
  margin-left: 8px;
}
.chat-timeline {
  margin-top: 21px;
  padding-left: 18px;
  border-left: 1px solid #d7e2ea;
}
.chat-message {
  position: relative;
  padding-bottom: 23px;
}
.chat-message:last-child {
  padding-bottom: 3px;
}
.chat-message::before {
  position: absolute;
  content: "";
  width: 7px;
  height: 7px;
  left: -22px;
  top: 8px;
  border: 2px solid var(--white);
  background: #9eb3c1;
  border-radius: 50%;
  box-sizing: content-box;
}
.chat-meta {
  display: flex;
  gap: 12px;
  align-items: center;
  color: #8a97a3;
  font-size: 11px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}
.chat-sender {
  font-weight: 600;
  color: #526b80;
}
.chat-text {
  font-size: 13px;
  line-height: 1.95;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.reply-draft {
  background: #f5f8fb;
  border-radius: 7px;
  padding: 15px 18px;
}
.draft-note {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 6px;
}
.technical-details {
  border-top: 1px solid var(--line);
  margin-top: 22px;
  padding-top: 14px;
}
.technical-body {
  font-family: var(--mono);
  font-size: 11px;
  margin-top: 10px;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.feedback-composer {
  background: #f8fafc;
  border-top: 1px solid var(--line);
  padding: 24px 32px 27px;
}
.composer-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 11px;
}
.composer-heading h3 {
  font-size: 14px;
}
.quick-actions {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.quick-actions .button {
  font-size: 11px;
  min-height: 30px;
  padding: 4px 9px;
}
.feedback-composer textarea {
  display: block;
  width: 100%;
  min-height: 106px;
  line-height: 1.85;
  font-size: 13px;
  background: var(--white);
  border-color: #d6e0e8;
}
.composer-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-top: 12px;
}
.form-note {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.8;
}
.feedback-history {
  margin-top: 18px;
  display: grid;
  gap: 10px;
}
.feedback-entry {
  border-left: 2px solid #c5d6df;
  padding-left: 12px;
  font-size: 12px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.feedback-entry small {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-top: 4px;
}
.error-text {
  font-size: 12px;
  color: var(--red);
  min-height: 20px;
}
.page-footer {
  max-width: 1440px;
  display: flex;
  justify-content: space-between;
  margin: 18px auto;
  padding: 0 29px;
  font-size: 10px;
  color: #8a98a5;
  gap: 12px;
}
.empty-state {
  padding: 85px 35px;
  text-align: center;
  max-width: 520px;
  margin: auto;
}
.empty-symbol {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border: 1px dashed #bacbd7;
  border-radius: 16px;
  color: #7d97ac;
  font-size: 29px;
  margin: 0 auto 23px;
}
.empty-state h2 {
  font-size: 21px;
  margin-bottom: 13px;
}
.empty-state p {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.9;
}
.list-empty {
  padding: 25px 12px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.9;
}
.list-empty .button {
  display: block;
  margin: 12px auto 0;
}
.connection-alert {
  background: var(--amber-soft);
  color: #795620;
  text-align: center;
  font-size: 12px;
  padding: 9px 16px;
}
.toast {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  max-width: min(540px, 90vw);
  background: var(--ink);
  color: var(--white);
  padding: 13px 20px;
  border-radius: 9px;
  box-shadow: 0 7px 28px #172c4230;
  font-size: 13px;
  z-index: 50;
}
.login-screen {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 28px;
  background: linear-gradient(135deg, #edf3f8 0%, #f6f8fa 60%, #ecf5f1 100%);
}
.login-card {
  width: 100%;
  max-width: 420px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 38px 36px 30px;
  box-shadow: 0 20px 65px #233d4d08;
}
.brand-mark {
  font-size: 36px;
  margin-bottom: 30px;
}
.login-card h1 {
  font-size: 27px;
  margin: 10px 0 13px;
  letter-spacing: -0.03em;
}
.login-intro {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.85;
  margin-bottom: 29px;
}
.login-card label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 8px;
}
.login-card input {
  width: 100%;
  height: 46px;
}
.login-card .error-text {
  margin-top: 8px;
}
.login-button {
  width: 100%;
  justify-content: space-between;
  margin-top: 7px;
  min-height: 45px;
}
.private-note {
  font-size: 10px;
  color: #91a0ac;
  margin-top: 25px;
}
.private-note span {
  color: var(--teal);
  font-size: 7px;
  margin-right: 5px;
}
.notification-dialog {
  border: 1px solid var(--line);
  border-radius: 14px;
  max-width: 490px;
  width: calc(100% - 32px);
  padding: 27px;
  color: var(--text);
  background: var(--white);
  max-height: 90dvh;
  overflow: auto;
}
.notification-dialog::backdrop {
  background: #17263875;
}
.dialog-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.dialog-heading h2 {
  font-size: 20px;
}
.notification-dialog .muted {
  font-size: 13px;
}
.push-state {
  margin: 20px 0 14px;
  background: var(--paper);
  border-radius: 7px;
  padding: 15px;
  font-size: 13px;
  white-space: pre-wrap;
}
.push-help {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.9;
}
.notification-actions {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin: 21px 0 12px;
}
.mobile-back {
  display: none;
}
@media (min-width: 1450px) {
  .workspace {
    gap: 34px;
    grid-template-columns: 370px minmax(0, 1fr);
  }
}
@media (max-width: 1000px) {
  .workspace {
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 18px;
    padding: 0 20px;
  }
  .detail-header,
  .detail-body {
    padding: 23px;
  }
  .feedback-composer {
    padding: 22px;
  }
  .detail-header h2 {
    font-size: 22px;
  }
  .composer-footer {
    align-items: flex-end;
  }
  .composer-heading {
    flex-wrap: wrap;
  }
}
@media (max-width: 760px) {
  .topbar {
    min-height: 65px;
    padding: 0 18px;
  }
  .brand {
    gap: 10px;
    font-size: 13px;
  }
  .brand-symbol {
    font-size: 23px;
    padding-right: 10px;
  }
  .header-actions {
    gap: 0;
  }
  .header-actions .button {
    font-size: 11px;
    padding: 6px 9px;
  }
  .workspace {
    display: block;
    margin: 22px auto 0;
    padding: 0 15px;
    min-height: calc(100dvh - 156px);
  }
  .sidebar-heading {
    padding: 0 4px 15px;
  }
  .sidebar-heading .eyebrow {
    font-size: 10px;
  }
  .sidebar-heading h1 {
    font-size: 25px;
    margin-top: 1px;
  }
  .filters {
    margin: 13px 0 15px;
  }
  .task-list {
    gap: 10px;
  }
  .task-item {
    padding: 15px 17px;
  }
  .task-item h2 {
    font-size: 15px;
  }
  .runtime {
    margin-top: 7px;
    padding: 20px 5px;
  }
  .task-detail {
    min-height: 470px;
    margin-top: 4px;
  }
  .workspace.mobile-detail .task-sidebar {
    display: none;
  }
  .workspace:not(.mobile-detail) .task-detail {
    display: none;
  }
  .mobile-back {
    display: inline-flex;
    margin: -6px 0 17px -8px;
    padding: 4px 8px;
    font-size: 12px;
    min-height: 36px;
  }
  .detail-header {
    padding: 19px 22px 22px;
  }
  .detail-meta {
    margin-bottom: 11px;
  }
  .detail-header h2 {
    font-size: 23px;
    line-height: 1.6;
  }
  .detail-summary {
    font-size: 13px;
  }
  .detail-body {
    padding: 24px 22px;
  }
  .detail-section + .detail-section {
    margin-top: 24px;
  }
  .content-text {
    font-size: 13px;
  }
  .feedback-composer {
    padding: 22px;
  }
  .composer-heading {
    gap: 8px;
    align-items: center;
  }
  .composer-footer {
    align-items: flex-start;
    gap: 14px;
  }
  .composer-footer .button {
    font-size: 12px;
    padding: 10px 14px;
  }
  .form-note {
    font-size: 10px;
  }
  .page-footer {
    padding: 0 20px;
    font-size: 9px;
    flex-wrap: wrap;
  }
  .login-card {
    padding: 32px 27px;
  }
  .login-card h1 {
    font-size: 25px;
  }
  .decision-box {
    padding: 15px 16px;
  }
  .notification-dialog {
    padding: 23px;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    transition: none !important;
    animation: none !important;
  }
}

.evidence-entry {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.evidence-entry h4 {
  margin: 0 0 7px;
  font-size: 12px;
  font-weight: 550;
  color: var(--muted);
}
.evidence-entry .content-text {
  font-size: 12px;
  color: var(--muted);
}
.technical-body {
  white-space: pre-wrap;
}

.technical-details > .detail-section {
  margin-top: 20px;
}
.technical-details > .reply-draft {
  margin-top: 12px;
}

.message-blocks {
  display: grid;
  gap: 11px;
  min-width: 0;
}
.chat-media {
  display: grid;
  justify-items: start;
  gap: 6px;
  margin: 0;
  min-width: 0;
}
.media-preview {
  display: block;
  max-width: 100%;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  cursor: zoom-in;
}
.media-preview img {
  display: block;
  width: auto;
  height: auto;
  max-width: min(100%, 360px);
  max-height: 280px;
  object-fit: contain;
}
.chat-emoji .media-preview img {
  max-width: min(100%, 144px);
  max-height: 144px;
}
.media-loading,
.media-caption {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.7;
  overflow-wrap: anywhere;
}
.media-unavailable {
  padding: 11px 13px;
  border: 1px dashed #c8d5df;
  border-radius: 7px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.85;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.media-unavailable-title {
  display: block;
  color: #597184;
  font-weight: 550;
  margin-bottom: 3px;
}
.forward-message {
  max-width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
  overflow: hidden;
}
.forward-message > summary {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 9px;
  min-height: 45px;
  padding: 10px 13px;
  cursor: pointer;
  color: #526b80;
  font-size: 12px;
  line-height: 1.75;
  font-weight: 550;
  overflow-wrap: anywhere;
}
.forward-message > summary::after {
  margin-left: auto;
  font-size: 16px;
}
.forward-count {
  flex-shrink: 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 400;
}
.forward-entries {
  padding: 5px 14px 14px;
  min-width: 0;
}
.forward-entry + .forward-entry {
  margin-top: 13px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}
.forward-note {
  margin: 0 0 12px;
  font-size: 12px;
  color: var(--muted);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.forward-flat {
  border-inline: 0;
  border-radius: 0;
}
.forward-flat > summary,
.forward-flat > .forward-entries {
  padding-inline: 0;
}
.media-dialog {
  width: min(1100px, calc(100vw - 32px));
  max-height: 92dvh;
  padding: 20px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  color: var(--text);
}
.media-dialog::backdrop {
  background: #172638bb;
}
.media-dialog .dialog-heading h2 {
  font-size: 18px;
}
.media-viewer {
  display: grid;
  place-items: center;
  min-height: 130px;
}
.media-full-image {
  display: block;
  max-width: 100%;
  max-height: calc(88dvh - 130px);
  object-fit: contain;
}
.media-dialog > .media-caption {
  margin-top: 12px;
}
@media (max-width: 760px) {
  .media-preview img {
    max-width: 100%;
    max-height: 260px;
  }
  .media-dialog {
    padding: 15px;
  }
}
