.td-demo {
  --td-line: #373940;
  --td-mute: #b6b8c2;
  overflow: hidden; border: 1px solid #33343b; border-radius: var(--round, 1.18rem);
  color: #efeff3; background: #17181c; font-family: "DM Sans", system-ui, sans-serif; text-align: left;
}
.td-demo *, .td-demo *::before, .td-demo *::after { box-sizing: border-box; }
.td-demo :is(h3,h4,h5,p) { margin: 0; }
.td-demo [hidden] { display: none !important; }
.td-toolbar, .td-review-heading, .td-change-heading, .td-preview-heading { display: flex; align-items: center; }
.td-toolbar {
  justify-content: space-between; gap: .8rem; padding: 1.1rem clamp(1rem,2.4vw,2rem);
  background: linear-gradient(100deg,#202128,#191a1e); border-bottom: 1px solid var(--td-line);
}
.td-toolbar h3 { display: inline-flex; align-items: center; gap: .52rem; font-size: 1.12rem; line-height: 1.2; font-weight: 600; letter-spacing: -.025em; }
.td-toolbar svg { color: #c9d5ed; }
.td-demo .td-toolbar p { margin: .25rem 0 0; color: var(--td-mute); font-size: .9rem; }
.td-progress { flex: none; border: 1px solid #454c5a; border-radius: 999px; padding: .3rem .66rem; color: #c7d8ef; font-size: .8rem; line-height: 1.25; }
.td-workspace { display: grid; grid-template-columns: 1.18fr minmax(0,1fr); gap: clamp(1rem,2.6vw,2.4rem); padding: clamp(1.1rem,2.6vw,2.25rem); }
.td-review { min-width: 0; grid-row: 1; grid-column: 2; }
.td-preview { min-width: 0; grid-row: 1; grid-column: 1; }
.td-review-heading { justify-content: space-between; gap: .5rem; margin-bottom: .75rem; }
.td-review-heading h4, .td-preview-heading { font-size: 1rem; font-weight: 570; }
.td-preview-heading { margin-bottom: .75rem; }
.td-review-heading > span { color: var(--td-mute); font-size: .82rem; font-variant-numeric: tabular-nums; }
.td-change { padding: clamp(1rem,2.15vw,1.65rem); border: 1px solid var(--td-line); border-radius: 1rem; background: #15161a; }
.td-change-heading { gap: .4rem; font-size: .93rem; }
.td-change-heading strong { font-weight: 610; }
.td-change-heading > span { color: var(--td-mute); }
.td-original, .td-suggestion { margin-top: 1rem; }
.td-original h5, .td-suggestion h5 { font-size: .85rem; line-height: 1.3; font-weight: 610; }
.td-original h5 { color: #b7bac3; }
.td-demo .td-change p { margin: .35rem 0 0; color: #c6c6cf; font-size: 1rem; line-height: 1.5; }
.td-suggestion { padding-left: .8rem; border-left: 2px solid #8699b6; }
.td-demo .td-suggestion p { color: #e7e8ef; }
.td-action {
  display: inline-flex; gap: .46rem; align-items: center; justify-content: center;
  min-height: 2.75rem; margin-top: 1.35rem; padding: .55rem 1rem;
  border: 1px solid #c8d9f3; border-radius: 999px; cursor: pointer; background: #c6d7f6;
  color: #192738; font: 620 .93rem/1.3 "DM Sans", system-ui, sans-serif; transition: background 170ms ease, transform 170ms ease;
}
.td-action:hover { background: #dce9ff; }
.td-action:active { transform: scale(.97); }
.td-action:focus-visible { outline: 2px solid #d1e4ff; outline-offset: 4px; }
.td-undo-icon, .td-demo[data-td-accepted] .td-accept-icon { display: none; }
.td-demo[data-td-accepted] .td-undo-icon { display: block; }
.td-demo[data-td-accepted] .td-action { border-color: #52655d; background: #27372e; color: #c2ead0; }
.td-demo[data-td-accepted] .td-progress { border-color: #52655d; color: #b5e5c5; }
.td-paper {
  min-width: 0; padding: clamp(1.45rem, 3.5vw, 2.8rem) clamp(1.2rem, 2.6vw, 2.3rem);
  color: oklch(.25 .013 263); background: oklch(.983 .004 92); border-radius: .25rem;
  box-shadow: 0 0 0 .3rem oklch(1 0 0 / .06), 0 .5rem 1.3rem oklch(0 0 0 / .26);
  font: .92rem/1.44 Georgia, "Times New Roman", serif; font-variant-numeric: lining-nums;
}
.td-letterhead { text-align: center; }
.td-paper .td-paper-title { font-size: clamp(1.65rem, 2.7vw, 2.15rem); font-weight: 700; line-height: 1.1; letter-spacing: -.045em; }
.td-paper .td-profession { margin-top: .16rem; font-size: .98rem; }
.td-paper .td-contact { margin-top: .28rem; font-size: .78rem; color: oklch(.39 .013 263); overflow-wrap: anywhere; }
.td-contact span { padding-inline: .13rem; }
.td-demo .td-paper h4 { margin: 1.05rem 0 .48rem; padding-bottom: .2rem; border-bottom: 1px solid oklch(.25 .013 263 / .38); font-size: .74rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.td-employer { display: flex; align-items: baseline; justify-content: space-between; gap: .4rem .8rem; flex-wrap: wrap; line-height: 1.25; }
.td-employer strong { font-size: .97rem; }
.td-employer span { color: oklch(.38 .015 263); font-size: .78rem; font-variant-numeric: tabular-nums; }
.td-paper .td-position { margin-top: .1rem; color: oklch(.35 .014 263); font-size: .87rem; }
.td-paper-list { margin: .25rem 0 .72rem; padding-inline-start: 1.05rem; }
.td-paper-list li + li { margin-top: .22rem; }
.td-paper [data-td-preview] { padding: .05rem .12rem; border-radius: 2px; box-decoration-break: clone; -webkit-box-decoration-break: clone; background: #fbefcd; }
.td-demo[data-td-accepted] .td-paper [data-td-preview] { background: #d9f2df; }
.td-demo .td-sr { position: absolute; overflow: hidden; width: 1px; height: 1px; margin: -1px; padding: 0; clip-path: inset(50%); border: 0; white-space: nowrap; }
@media (max-width: 760px) {
  .td-workspace { grid-template-columns: 1fr; gap: 1.45rem; }
  .td-review, .td-preview { grid-column: auto; grid-row: auto; }
  .td-review { order: 1; } .td-preview { order: 2; }
  .td-paper { min-height: 0; padding: 1.4rem; }
}
@media (max-width: 470px) {
  .td-toolbar { flex-wrap: wrap; gap: .55rem .75rem; }
  .td-workspace { padding: 1rem .9rem 1.25rem; }
  .td-change { padding: .9rem; border-radius: .75rem; }
}
@media (prefers-reduced-motion: reduce) { .td-action { transition: none; } .td-action:active { transform: none; } }
@media (forced-colors: active) { .td-action, .td-paper, .td-paper [data-td-preview] { border: 1px solid ButtonText; } }
