/* The 작업 tab's canvas (js/workcanvas.js): the slide deck (filmstrip and stage) and the
   document (outline and pages). The app's own parts (bars, tags, buttons) use the colour
   tokens of styles.css. What the work itself looks like does not follow the app's theme: a
   slide has the colours of its theme (the same as in the PowerPoint file, set on .wc-slide
   by the script), and a document is a white sheet of paper. */

.wc {
  container: wc / inline-size;
  height: 100%;
  min-height: 0;
  color: var(--ink);
}
.wc [hidden] {
  display: none !important;
}

/* ---------- a slide: 960 × 540 pt, drawn the same at any width ---------- */

.wc-slide {
  container-type: inline-size;
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--wc-bg, #fff);
  overflow: hidden;
}
.wc-s-in {
  --u: calc(100cqw / 960); /* one point of the slide */
  position: absolute;
  inset: 0;
  color: var(--wc-text);
  font-family: var(--font);
  line-height: 1.25;
  letter-spacing: -0.01em;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.wc-s-in > * {
  position: absolute;
  margin: 0;
}
.wc-s-accent {
  left: calc(var(--u) * 43.2);
  top: calc(var(--u) * 32.4);
  width: calc(var(--u) * 86.4);
  height: calc(var(--u) * 5.76);
  background: var(--wc-accent);
  border-radius: calc(var(--u) * 2);
}
.wc-s-title {
  left: calc(var(--u) * 43.2);
  top: calc(var(--u) * 43.2);
  width: calc(var(--u) * 871.2);
  padding-top: calc(var(--u) * 14); /* (one line sits in the middle of the 79.2 pt box; a second still clears the body) */
  color: var(--wc-title);
  font-size: calc(var(--u) * 32);
  font-weight: 700;
  line-height: 1.2;
}
/* (the middle layouts: the title's last line ends where its box does, 4 in down, above the subtitle) */
.wc-s-title.wc-s-big {
  top: auto;
  bottom: calc(var(--u) * 252);
  padding-top: 0;
  text-align: center;
  font-size: calc(var(--u) * 44);
}
.wc-s-sub {
  left: calc(var(--u) * 43.2);
  top: calc(var(--u) * 295.2);
  width: calc(var(--u) * 871.2);
  text-align: center;
  font-size: calc(var(--u) * 22);
}
.wc-s-under {
  left: calc(var(--u) * 120);
  top: calc(var(--u) * 360);
  width: calc(var(--u) * 720);
  font-size: calc(var(--u) * 18);
}
.wc-s-body {
  left: calc(var(--u) * 43.2);
  top: calc(var(--u) * 136.8);
  width: calc(var(--u) * 871.2);
  height: calc(var(--u) * 360);
  font-size: calc(var(--u) * var(--wc-size, 20));
  overflow: hidden;
}
.wc-s-body.wc-s-narrow {
  width: calc(var(--u) * 504);
}
.wc-s-list {
  margin: 0;
  padding: 0 0 0 1.15em;
  list-style: disc;
}
.wc-s-list li {
  margin: 0 0 0.45em;
  padding-left: 0.1em;
}
.wc-s-list li::marker {
  color: var(--wc-accent);
}
.wc-s-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--u) * 21.6);
}
.wc-s-table {
  width: 100%;
  border-collapse: collapse;
  font-size: calc(var(--u) * (var(--wc-size, 20) - 4));
}
.wc-s-table th,
.wc-s-table td {
  border: max(1px, calc(var(--u) * 0.5)) solid var(--wc-accent);
  padding: calc(var(--u) * 4) calc(var(--u) * 8);
  text-align: left;
  vertical-align: top;
}
.wc-s-table th {
  color: var(--wc-title);
  font-weight: 700;
}
.wc-s-quote {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: calc(var(--u) * 14);
}
.wc-s-qtext {
  color: var(--wc-title);
  font-size: calc(var(--u) * 28);
  font-style: italic;
  line-height: 1.35;
}
.wc-s-by {
  font-size: calc(var(--u) * 18);
}
.wc-s-by::before {
  content: "— ";
}
.wc-s-image {
  left: calc(var(--u) * 568.8);
  top: calc(var(--u) * 136.8);
  width: calc(var(--u) * 345.6);
  height: calc(var(--u) * 331.2);
  display: grid;
  place-items: center;
  padding: calc(var(--u) * 14);
  border: max(1px, calc(var(--u) * 1.5)) dashed var(--wc-accent);
  border-radius: calc(var(--u) * 12);
  font-size: calc(var(--u) * 14);
  text-align: center;
  opacity: 0.85;
}
.wc-s-num {
  right: calc(var(--u) * 28.8);
  bottom: calc(var(--u) * 18);
  font-size: calc(var(--u) * 12);
  opacity: 0.65;
}
.wc-s-in .wc-tail {
  position: static;
  margin-top: 0.2em;
  opacity: 0.75;
}

/* typing into a slide in place */
.wc-slide [contenteditable="true"] {
  outline: none;
  border-radius: calc(var(--u) * 4);
  cursor: text;
  transition: box-shadow 0.15s;
}
.wc-slide [contenteditable="true"]:hover {
  box-shadow: 0 0 0 max(1px, calc(var(--u) * 1)) color-mix(in srgb, var(--wc-accent) 35%, transparent);
}
.wc-slide [contenteditable="true"]:focus {
  box-shadow: 0 0 0 max(2px, calc(var(--u) * 2)) color-mix(in srgb, var(--wc-accent) 70%, transparent);
}
.wc-blank[data-ph]::before {
  content: attr(data-ph);
  opacity: 0.4;
  pointer-events: none;
}

/* the line the AI is writing: a blinking caret at its end */
.wc-caret {
  display: inline-block;
  width: 0.09em;
  min-width: 2px;
  height: 1em;
  margin-left: 0.08em;
  vertical-align: -0.12em;
  background: currentColor;
  animation: wc-blink 1s steps(1) infinite;
}
@keyframes wc-blink {
  50% {
    opacity: 0;
  }
}

/* ---------- the deck: filmstrip and stage ---------- */

.wc-deck-grid {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  height: 100%;
  min-height: 0;
}
.wc-strip {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 12px 10px 28px 8px;
  border-right: 1px solid var(--line);
  background: var(--surface-2);
}
.wc-item {
  position: relative;
  display: flex;
  flex-direction: column;
}
.wc-thumb {
  position: relative;
  padding-left: 22px;
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  outline: none;
}
.wc-thumb .wc-num {
  position: absolute;
  left: 0;
  top: 2px;
  width: 17px;
  text-align: right;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.wc-thumb-box {
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 0 0 1px var(--line-strong);
  background: var(--surface);
  transition: box-shadow 0.15s;
}
.wc-thumb-box .wc-slide {
  pointer-events: none;
}
.wc-thumb:hover .wc-thumb-box {
  box-shadow: 0 0 0 1px var(--accent);
}
.wc-thumb[aria-selected="true"] .wc-thumb-box {
  box-shadow: 0 0 0 2px var(--accent);
}
.wc-thumb[aria-selected="true"] .wc-num {
  color: var(--accent-text);
}
.wc-thumb:focus-visible .wc-thumb-box {
  box-shadow: 0 0 0 2px var(--accent), var(--ring);
}
.wc-thumb .wc-marks {
  position: absolute;
  left: 26px;
  right: 4px;
  bottom: 4px;
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  pointer-events: none;
}
.wc-thumb .wc-marks .retry {
  pointer-events: auto;
}
.wc-thumb-x,
.wc-thumb-more {
  appearance: none;
  position: absolute;
  top: 4px;
  width: 22px;
  height: 22px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  color: var(--ink-2);
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.12s;
}
.wc-thumb-x {
  right: 4px;
}
.wc-thumb-more {
  right: 30px;
}
.wc-thumb-x:hover {
  color: var(--bad);
  background: var(--bad-soft);
}
.wc-thumb-more:hover {
  color: var(--ink);
}
.wc-thumb:hover :is(.wc-thumb-x, .wc-thumb-more),
.wc-thumb:focus-within :is(.wc-thumb-x, .wc-thumb-more),
.wc-thumb[aria-selected="true"] .wc-thumb-more {
  opacity: 1;
}
.wc-thumb.wc-ghost {
  cursor: default;
  margin-bottom: 18px;
}

/* the "+" between two parts */
.wc-insert {
  appearance: none;
  align-self: center;
  width: 26px;
  height: 16px;
  margin: 1px 0;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-text);
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.12s;
}
.wc-item:hover > .wc-insert,
.wc-insert:focus-visible {
  opacity: 1;
}
.wc-strip > .wc-insert,
.wc-outline > .wc-insert {
  opacity: 1;
  width: 100%;
  height: 36px;
  border-radius: 8px;
}
@media (hover: none) {
  .wc-insert {
    opacity: 0.6;
  }
  .wc-thumb[aria-selected="true"] .wc-thumb-x {
    opacity: 1;
  }
}
.wc-strip.wc-sorting .wc-insert {
  opacity: 0 !important;
}

/* dragging a part to another place */
.wc-drop-line {
  position: absolute;
  left: 26px;
  right: 8px;
  height: 3px;
  border-radius: 2px;
  background: var(--accent);
  pointer-events: none;
  z-index: 3;
}
.wc-drop-line.across {
  top: 10px;
  bottom: 10px;
  right: auto;
  width: 3px;
  height: auto;
}
.wc-dragging {
  opacity: 0.45;
}
.wc-sorting {
  cursor: grabbing;
}

/* a part not written yet */
.wc-skel {
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  padding: 6px;
  border: 1.5px dashed var(--line-strong);
  border-radius: 6px;
  background: var(--surface);
}
.wc-skel .wc-skel-title {
  font-size: 11px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--muted);
  text-align: center;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
/* (a label the AI's hands are about to type into: it has a place on the screen before its first letter) */
.wc-skel-title:empty {
  min-width: 2px;
  min-height: 1.3em;
}
.wc-skel.live,
.wc-skel-lines.live span {
  background: linear-gradient(100deg, var(--surface) 30%, var(--accent-soft) 50%, var(--surface) 70%) 0 0 / 300% 100%;
  animation: wc-shimmer 1.6s linear infinite;
}
@keyframes wc-shimmer {
  to {
    background-position: -150% 0;
  }
}

.wc-main {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
  overflow-y: auto;
  padding: 16px 20px 32px;
}
.wc-main > * {
  width: 100%;
  max-width: 1100px;
  margin-inline: auto;
}
/* (the bars around the slide keep their height: a tall slide makes the column scroll rather than
   squeeze the pace banner, whose buttons it hides with overflow, or the tools and feedback) */
.wc-main > .wc-tools,
.wc-main > .wc-pace,
.wc-main > .wc-follow,
.wc-main > .wc-fb-slot {
  flex-shrink: 0;
}
.wc-edit {
  position: relative;
}
.wc-stage {
  position: relative;
}
.wc-stage > .wc-slide {
  border-radius: 10px;
  box-shadow: 0 0 0 1px var(--line), var(--shadow);
}
.wc-stage-tag {
  position: absolute;
  left: 10px;
  top: 10px;
  display: flex;
  gap: 4px;
}
.wc-stage-tag .wc-tag {
  font-size: 12px;
  padding: 3px 9px;
}
.wc-stop-edit {
  box-shadow: var(--shadow);
}
.wc-stage > .wc-stop-edit {
  position: absolute;
  right: 10px;
  top: 10px;
}
.wc-skel-slide,
.wc-empty {
  background: var(--surface);
  box-shadow: none !important;
  border: 1.5px dashed var(--line-strong);
}
.wc-skel-in,
.wc-empty-in {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
  color: var(--muted);
}
.wc-empty-in {
  flex-direction: row;
}
.wc-skel-slide .wc-skel-title {
  font-size: clamp(16px, 3.2cqw, 30px);
  font-weight: 700;
  line-height: 1.3;
}
.wc-skel-brief {
  max-width: 60ch;
  font-size: 13.5px;
}
.wc-skel-slide.st-failed {
  border-color: color-mix(in srgb, var(--bad) 45%, transparent);
}

/* (what is under the large slide: the "saved" mark, on the right; a slide has no speaker notes, spec 26.11) */
.wc-under {
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 10px;
}
.wc-saved {
  flex: none;
  padding-top: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--good);
  opacity: 0;
  transition: opacity 0.25s;
}
.wc-saved.on {
  opacity: 1;
}

/* "슬라이드 3 작성 중 · 보기": back to following the AI */
.wc-follow {
  appearance: none;
  align-self: center;
  width: auto !important;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-text);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.wc-follow:hover {
  border-color: var(--accent);
}
/* (out of the flow, over a corner of the slide or the grid: the stage never moves as it comes and goes) */
.wc-edit > .wc-follow,
.ws-edit > .wc-follow {
  position: absolute;
  z-index: 5;
  box-shadow: var(--shadow);
}
.wc-edit > .wc-follow {
  top: 10px;
  right: 10px;
}
.ws-edit > .wc-follow {
  right: 22px;
  bottom: 22px;
}

/* ---------- state marks ---------- */

.wc-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-2);
  font: inherit;
  font-size: 10.5px;
  font-weight: 650;
  line-height: 1.3;
  white-space: nowrap;
}
.wc-tag.live {
  border-color: transparent;
  background: var(--accent);
  color: var(--accent-ink);
}
.wc-tag.wait {
  border-color: transparent;
  background: var(--warn-soft);
  color: var(--warn);
}
.wc-tag.retry {
  appearance: none;
  border-color: transparent;
  background: var(--bad-soft);
  color: var(--bad);
  cursor: pointer;
}
.wc-tag.retry:hover {
  filter: brightness(0.97);
  text-decoration: underline;
}
.wc-mark {
  display: inline-grid;
  place-items: center;
  width: 17px;
  height: 17px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink-2);
}
.wc-mark.pin {
  color: var(--accent-text);
}
.wc-bubble {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 1px 5px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-text);
  font-size: 10.5px;
  font-weight: 700;
}
.wc-pulse {
  flex: none;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  animation: wc-pulse 1.2s ease-in-out infinite;
}
@keyframes wc-pulse {
  50% {
    opacity: 0.3;
    transform: scale(0.75);
  }
}

/* ---------- the pause before the next part, the plan's hold, fast pace ---------- */

.wc-pace {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 8px 12px 10px;
  overflow: hidden;
  border-radius: var(--r);
  background: var(--accent-soft);
  color: var(--accent-text);
  font-size: 13.5px;
  font-weight: 600;
}
.wc-pace-text {
  min-width: 0;
}
.wc-pace-acts {
  display: flex;
  gap: 6px;
  margin-left: auto;
}
/* (what making the plan is likely to cost, after its words: spec 23.9) */
.wc-pace-cost {
  flex: none;
  white-space: nowrap;
}
.wc-drain {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 3px;
  background: var(--accent);
  transform-origin: left center;
  animation: wc-drain linear forwards;
}
@keyframes wc-drain {
  from {
    transform: scaleX(1);
  }
  to {
    transform: scaleX(0);
  }
}
.wc-pace.fast {
  padding: 7px 12px;
  background: var(--surface-2);
  color: var(--ink-2);
  font-weight: 550;
}
.wc-pace.fast .wc-pulse {
  color: var(--accent);
}

/* ---------- the bar under the chosen part ---------- */

.wc-fb {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font);
}
.wc-fb-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.wc-fb-input {
  flex: 1;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 14px;
}
.wc-fb-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: var(--ring);
}
.wc-fb-send {
  display: grid;
  place-items: center;
}
.wc-fb.locked {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

/* "이 부분만 고치기" over selected text */
.wc-fix {
  position: fixed;
  z-index: 250;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 11px;
  border: 0;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font: inherit;
  font-family: var(--font);
  font-size: 12.5px;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  cursor: pointer;
  animation: pop-in 0.14s ease-out;
}

/* "슬라이드를 지웠습니다 · 되돌리기" */
.wc-toast {
  display: flex;
  align-items: center;
  gap: 14px;
}
.wc-toast-btn {
  appearance: none;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  font-weight: 750;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

/* ---------- the document: outline and pages ---------- */

.wc-doc-grid {
  position: relative;
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  height: 100%;
  min-height: 0;
}
.wc-outline-pane {
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 12px 8px 28px;
  border-right: 1px solid var(--line);
  background: var(--surface-2);
}
.wc-outline {
  position: relative;
  display: flex;
  flex-direction: column;
}
.wc-oitem {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 5px 4px 5px 8px;
  border-radius: 8px;
  font-size: 13.5px;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  outline: none;
}
.wc-oitem:hover {
  background: var(--surface-3);
}
.wc-oitem[aria-selected="true"] {
  background: var(--accent-soft);
  color: var(--accent-text);
}
.wc-oitem:focus-visible {
  box-shadow: var(--ring);
}
.wc-oitem .wc-num {
  flex: none;
  width: 18px;
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 600;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.wc-otitle {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.wc-oitem:is(.st-planned, .st-queued) .wc-otitle {
  color: var(--muted);
}
.wc-oitem .wc-marks {
  display: flex;
  flex: none;
  gap: 3px;
}
.wc-omore {
  width: 26px;
  height: 26px;
  opacity: 0;
}
.wc-oitem:hover .wc-omore,
.wc-oitem:focus-within .wc-omore,
.wc-oitem[aria-selected="true"] .wc-omore {
  opacity: 1;
}
.wc-oitem.wc-ghost {
  cursor: default;
}
.wc-skel-line {
  display: block;
  flex: 1;
  height: 10px;
  border-radius: 5px;
  background: var(--surface-3);
}
.wc-toc-btn,
.wc-toc-shade {
  display: none;
}

.wc-pages {
  position: relative;
  overflow-y: auto;
  padding: 0 24px 48px;
  background: var(--pdf-bg);
}
.wc-pages-top {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  max-width: 794px;
  min-height: 14px;
  margin: 0 auto;
  padding: 6px 0;
}
.wc-pages-top .wc-saved {
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--surface);
}
.wc-pace-top {
  max-width: 794px;
  margin: 0 auto 12px;
}
.wc-pace-top:empty {
  display: none;
}
.wc-paper {
  max-width: 794px;
  margin: 0 auto;
}

/* the sheet: always white paper with dark ink, as it prints */
.wc-sheet {
  position: relative;
  min-height: 1123px;
  padding: 64px 76px 96px;
  border-radius: 4px;
  background: #ffffff;
  color: #1f2937;
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.12), 0 8px 28px rgb(0 0 0 / 0.1);
  font-family: var(--font);
  color-scheme: light;
}
.wc-secs {
  display: flex;
  flex-direction: column;
}
.wc-sec {
  position: relative;
  margin: 0 -18px;
  padding: 6px 18px 2px;
  border-radius: 8px;
  transition: box-shadow 0.15s, background 0.15s;
}
.wc-sec:hover {
  background: rgb(79 70 229 / 0.03);
}
.wc-sec.wc-sel {
  box-shadow: 0 0 0 2px rgb(79 70 229 / 0.35);
}
.wc-sec-tools {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 6px;
}
.wc-sec-num {
  display: none;
}
.wc-sec-tools .wc-marks {
  display: flex;
  gap: 3px;
}
.wc-sec-more {
  opacity: 0;
  background: #fff;
  color: #4b5563;
}
.wc-sec:hover .wc-sec-more,
.wc-sec.wc-sel .wc-sec-more,
.wc-sec-more:focus-visible {
  opacity: 1;
}
.wc-sec-more:hover {
  background: #f3f4f6;
  color: #111827;
}
.wc-sec-pace:empty,
.wc-sec-fb:empty {
  display: none;
}
.wc-sec-pace {
  margin: 4px 0 8px;
}
.wc-sec-fb {
  margin: 4px 0 14px;
}

.wc-d {
  font-size: 15px;
  line-height: 1.75;
}
.wc-d-h {
  margin: 14px 96px 10px 0;
  color: #111827;
  font-size: 22px;
  font-weight: 750;
  line-height: 1.35;
}
/* (a subheading; a list one step in has the same class name, wc-d-list wc-d-sub, and is not bold) */
h3.wc-d-sub {
  margin: 18px 0 6px;
  color: #111827;
  font-size: 16.5px;
  font-weight: 700;
}
.wc-d-p {
  margin: 0 0 10px;
  white-space: pre-wrap;
}
.wc-d-list {
  margin: 0 0 12px;
  padding-left: 1.4em;
}
.wc-d-list li {
  margin: 0 0 3px;
}
.wc-d-table {
  margin: 4px 0 14px;
  overflow-x: auto;
}
.wc-d-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.5;
}
.wc-d-table th,
.wc-d-table td {
  padding: 6px 10px;
  border: 1px solid #e5e7eb;
  text-align: left;
  vertical-align: top;
}
.wc-d-table th {
  background: #f3f4f6;
  font-weight: 700;
}
.wc-d-quote {
  margin: 6px 0 14px;
  padding: 2px 0 2px 14px;
  border-left: 3px solid #d1d5db;
  color: #4b5563;
}
.wc-d-quote p {
  margin: 0;
  font-style: italic;
}
.wc-d-quote .wc-d-by {
  margin-top: 2px;
  font-size: 13.5px;
  font-style: normal;
}
.wc-d-by::before {
  content: "— ";
}
.wc-d .wc-tail {
  color: #6b7280;
}
.wc-sheet [contenteditable="true"] {
  outline: none;
  border-radius: 3px;
  cursor: text;
  transition: box-shadow 0.15s;
}
.wc-sheet [contenteditable="true"]:hover {
  box-shadow: 0 0 0 1px #e5e7eb;
}
.wc-sheet [contenteditable="true"]:focus {
  box-shadow: 0 0 0 2px #c7d2fe;
}
.wc-sheet .wc-blank[data-ph]::before {
  color: #9ca3af;
  opacity: 1;
}
.wc-sheet .wc-caret {
  background: #4f46e5;
}
.wc-skel-sec .wc-skel-title {
  color: #9ca3af;
}
.wc-skel-sec .wc-skel-brief {
  margin: 0 0 6px;
  color: #9ca3af;
}
.wc-skel-lines {
  margin: 4px 0 18px;
}
.wc-skel-lines span {
  display: block;
  height: 10px;
  margin: 10px 0;
  border-radius: 5px;
  background: #eef0f3;
}
.wc-skel-lines span:nth-child(2) {
  width: 92%;
}
.wc-skel-lines span:nth-child(3) {
  width: 70%;
}
.wc-skel-lines.live span {
  background: linear-gradient(100deg, #eef0f3 30%, #e0e7ff 50%, #eef0f3 70%) 0 0 / 300% 100%;
}
.wc-doc-empty {
  display: grid;
  place-items: center;
  min-height: 240px;
}
.wc-doc-wait {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #6b7280;
}

/* PDF works: where each A4 page would end (a guide only) */
.wc-rules {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.wc-rule {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px dashed #cbd5e1;
}
.wc-rule span {
  position: absolute;
  top: -9px;
  right: 10px;
  padding: 0 5px;
  background: #ffffff;
  color: #94a3b8;
  font-size: 10.5px;
  line-height: 16px;
}

/* ---------- narrow canvases: the filmstrip on top, the outline as a sheet ---------- */

@container wc (max-width: 640px) {
  .wc-deck-grid {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
  }
  .wc-strip {
    flex-direction: row;
    align-items: flex-start;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 10px 12px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .wc-item {
    flex-direction: row;
    align-items: center;
  }
  .wc-thumb {
    width: 136px;
    flex: none;
  }
  .wc-insert {
    width: 16px;
    height: 26px;
    margin: 0 1px;
  }
  .wc-strip > .wc-insert {
    width: 136px;
    height: 76px;
  }
  .wc-drop-line {
    left: auto;
  }
  .wc-main {
    padding: 12px 12px 24px;
  }
  .wc-under {
    flex-direction: column;
    gap: 4px;
  }
  .wc-saved {
    padding-top: 0;
  }
}

@container wc (max-width: 700px) {
  .wc-doc-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .wc-outline-pane {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 5;
    width: min(300px, 86%);
    border-right: 1px solid var(--line);
    background: var(--surface);
    box-shadow: var(--shadow-lg);
    transform: translateX(-104%);
    transition: transform 0.2s ease;
  }
  .wc.toc-open .wc-outline-pane {
    transform: none;
  }
  .wc.toc-open .wc-toc-shade {
    display: block;
    position: absolute;
    inset: 0;
    z-index: 4;
    background: rgb(0 0 0 / 0.28);
  }
  .wc-toc-btn {
    display: inline-flex;
    margin-right: auto;
  }
  .wc-pages {
    padding: 0 8px 28px;
  }
  .wc-sheet {
    min-height: 0;
    padding: 28px 22px 48px;
  }
  .wc-sec {
    margin: 0 -10px;
    padding: 6px 10px 2px;
  }
  .wc-d-h {
    margin-right: 64px;
    font-size: 19px;
  }
}

@media (prefers-reduced-motion: reduce) {
  /* (the caret stays, still: the AI's hands type at it, word by word) */
  .wc-caret {
    animation: none;
  }
  .wc-drain {
    display: none;
  }
  .wc-pulse,
  .wc-skel.live,
  .wc-skel-lines.live span {
    animation: none;
  }
  .wc-outline-pane {
    transition: none;
  }
}

/* ---------- where a slide's title and body stand: boxes that can be moved and resized ---------- */

/* (each box is placed by the script in fractions of the slide, LAYOUT_BOXES or the slide's own) */
.wc-box {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  box-sizing: border-box;
}
.wc-box-title {
  justify-content: center;
}
/* (the middle layouts: the title's last line ends where its box does, above the subtitle) */
.wc-l-title .wc-box-title,
.wc-l-section .wc-box-title,
.wc-l-closing .wc-box-title {
  justify-content: flex-end;
}
.wc-s-in .wc-box > .wc-s-title {
  position: static;
  width: auto;
  padding-top: 0;
}
.wc-s-in .wc-box > .wc-s-body {
  position: static;
  width: 100%;
  height: 100%;
}
.wc-s-in .wc-s-mid > .wc-s-sub {
  width: auto;
}
.wc-s-in .wc-s-mid > .wc-s-under {
  width: 82%;
  margin: calc(var(--u) * 22) auto 0;
}

/* the edges a box is moved by and the corners it is resized by (on the large slide, when it can be changed);
   a finger dragging them moves the box, not the page */
.wc-edge,
.wc-handle {
  position: absolute;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.12s;
  touch-action: none;
}
.wc-edge-n,
.wc-edge-s {
  left: 0;
  right: 0;
  height: 8px;
  cursor: move;
}
.wc-edge-n {
  top: -4px;
}
.wc-edge-s {
  bottom: -4px;
}
.wc-edge-e,
.wc-edge-w {
  top: 0;
  bottom: 0;
  width: 8px;
  cursor: move;
}
.wc-edge-e {
  right: -4px;
}
.wc-edge-w {
  left: -4px;
}
.wc-handle {
  width: 10px;
  height: 10px;
  box-sizing: border-box;
  border: 1.5px solid var(--wc-accent);
  border-radius: 2px;
  background: var(--wc-bg);
}
.wc-handle-nw {
  left: -5px;
  top: -5px;
  cursor: nwse-resize;
}
.wc-handle-ne {
  right: -5px;
  top: -5px;
  cursor: nesw-resize;
}
.wc-handle-sw {
  left: -5px;
  bottom: -5px;
  cursor: nesw-resize;
}
.wc-handle-se {
  right: -5px;
  bottom: -5px;
  cursor: nwse-resize;
}
.wc-box:has(> .wc-edge):is(:hover, :focus-within),
.wc-box.wc-box-active {
  outline: 1px dashed color-mix(in srgb, var(--wc-accent) 60%, transparent);
  outline-offset: 2px;
}
.wc-box:hover > :is(.wc-edge, .wc-handle),
.wc-box:focus-within > :is(.wc-edge, .wc-handle),
.wc-box-active > :is(.wc-edge, .wc-handle) {
  opacity: 1;
}
/* a touch screen has no hover: the grips show whenever the slide can be changed, and are large enough for a finger */
@media (pointer: coarse) {
  .wc-box:has(> .wc-edge) {
    outline: 1px dashed color-mix(in srgb, var(--wc-accent) 45%, transparent);
    outline-offset: 2px;
  }
  .wc-box > :is(.wc-edge, .wc-handle) {
    opacity: 1;
  }
  .wc-edge-n,
  .wc-edge-s {
    height: 24px;
  }
  .wc-edge-n {
    top: -12px;
  }
  .wc-edge-s {
    bottom: -12px;
  }
  .wc-edge-e,
  .wc-edge-w {
    width: 24px;
  }
  .wc-edge-e {
    right: -12px;
  }
  .wc-edge-w {
    left: -12px;
  }
  .wc-handle {
    width: 14px;
    height: 14px;
    z-index: 3;
  }
  .wc-handle::after {
    content: "";
    position: absolute;
    inset: -6px;
  }
  .wc-handle-nw {
    left: -7px;
    top: -7px;
  }
  .wc-handle-ne {
    right: -7px;
    top: -7px;
  }
  .wc-handle-sw {
    left: -7px;
    bottom: -7px;
  }
  .wc-handle-se {
    right: -7px;
    bottom: -7px;
  }
}

/* ---------- 테마 and "+" (슬라이드 추가, + 단원) ---------- */

.wc-tools {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-bottom: -4px;
}
.wc-theme-btn {
  gap: 6px;
}
.wc-theme-sw {
  width: 14px;
  height: 14px;
  flex: none;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  background: linear-gradient(135deg, var(--sw-bg) 55%, var(--sw-accent) 55%);
}
.wc-add {
  appearance: none;
  flex: none;
  display: grid;
  place-items: center;
  height: 40px;
  margin: 6px 0 0 22px;
  padding: 0;
  border: 1.5px dashed var(--line-strong);
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
}
.wc-add:hover,
.wc-add:focus-visible {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent-text);
}
.wc-add[aria-disabled="true"] {
  cursor: default;
}
.wc-outline > .wc-add {
  align-self: flex-start;
  height: auto;
  margin: 8px 0 0 8px;
  padding: 4px 12px;
  font-size: 13px;
}
@container wc (max-width: 640px) {
  .wc-strip > .wc-add {
    width: 56px;
    height: 76px;
    margin: 0 0 0 6px;
  }
}

/* ---------- a part the AI has taken out, until the hands have deleted it in sight ---------- */

.wc-leaving {
  pointer-events: none;
}
.wc-fading {
  opacity: 0;
  transform: scale(0.96);
  transition:
    opacity 0.3s,
    transform 0.3s;
}
@media (prefers-reduced-motion: reduce) {
  .wc-fading,
  .wc-edge,
  .wc-handle {
    transition: none;
  }
  .wc-fading {
    transform: none;
  }
}

/* ---------- found in the audit: a point under a quotation, lists under an item, Esc, a held pause ---------- */

/* A quotation with a point on why it matters: the quotation in the top 65% of the body box,
   the point under it (the PowerPoint file splits the box the same way, workexport.js QUOTE_SHARE). */
.wc-s-body.wc-s-quoted {
  display: flex;
  flex-direction: column;
}
.wc-s-body.wc-s-quoted > .wc-s-quote {
  flex: none;
  height: 65%;
}
.wc-s-qnote {
  flex: 1 1 auto;
  min-height: 0;
  font-size: calc(var(--u) * min(var(--wc-size, 20), 18));
}
/* A list under an item of the list before it (the choices under a question): one step in. */
.wc-d-list.wc-d-sub {
  margin-top: -8px;
  padding-left: 2.8em;
  list-style-type: circle;
}
ol.wc-d-list.wc-d-sub {
  list-style-type: decimal;
}
/* (Esc leaves a field and keeps the focus on the canvas, so a second Esc can pause: no ring for that) */
.wc:focus {
  outline: none;
}
/* The pause held (the hands still showing the last part, or the student at work): it says what it waits for. */
.wc-pace.held .wc-pace-text {
  font-weight: 550;
}

/* A subtitle on a slide of another layout (over a table, say): one line over the body, as the
   PowerPoint file draws it (workexport.js CAPTION_H). */
.wc-s-cap {
  flex: none;
  margin: 0 0 calc(var(--u) * 10);
  font-size: calc(var(--u) * 18);
  font-weight: 600;
  color: var(--wc-accent);
  line-height: 1.3;
}

/* ---------- the AI stopped at a part (spec 24): its bar, and where the AI waits ---------- */

/* Under the slide (above its notes), after the paragraph it stopped in, or above the sheet's grid. */
.wc-partbar-slot:empty {
  display: none;
}
.wc-partbar-slot {
  margin-top: 10px;
}
/* (a sheet's bar stands over its toolbar and formula bar, not in the flow above the grid: the
   grid never moves down under the press that stopped it, a double-click's second press say) */
.ws-main {
  position: relative;
}
.ws-partbar-slot {
  position: absolute;
  top: 12px;
  left: 16px;
  right: 16px;
  z-index: 6;
  margin: 0;
}
.ws-partbar-slot > .wc-partbar {
  box-shadow: var(--shadow);
}
@container wc (max-width: 640px) {
  .ws-partbar-slot {
    top: 10px;
    left: 10px;
    right: 10px;
  }
}
.wc-partbar {
  display: grid;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid color-mix(in srgb, var(--warn) 40%, transparent);
  border-radius: var(--r);
  background: var(--warn-soft);
  color: var(--ink);
  font-family: var(--font);
  font-size: 13.5px;
  /* (in a document's flow it stands as a paragraph would, not as text that can be typed into) */
  user-select: none;
}
.wc-blocks > .wc-partbar,
.wc-d > .wc-partbar,
.wc-sec-body > .wc-partbar {
  margin: 4px 0 14px;
}
.wc-partbar-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
}
.wc-partbar-text {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 650;
  color: var(--warn);
}
.wc-partbar-hint {
  color: var(--ink-2);
  font-size: 12.5px;
}
.wc-partbar-acts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-left: auto;
}
.wc-partbar-acts .btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.wc-partbar-redo {
  display: flex;
  align-items: center;
  gap: 8px;
}
.wc-partbar-redo[hidden] {
  display: none;
}
.wc-partbar-input {
  flex: 1;
  min-width: 0;
  padding: 8px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  user-select: text;
}
.wc-partbar-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: var(--ring);
}
.wc-partbar-send {
  display: grid;
  place-items: center;
}
.wc-partbar-send:disabled {
  opacity: 0.45;
  cursor: default;
}
/* (the pace bar while a part is stopped and not on the screen: where the AI waits, and 돌아가기) */
.wc-pace.frozen {
  background: var(--warn-soft);
  color: var(--warn);
}
.wc-pace.frozen .btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

@media (max-width: 560px) {
  .wc-partbar-acts {
    margin-left: 0;
  }
}

/* ---------- nothing moves under the student as a bar comes (spec 25.6) ---------- */

/* The pause's bar of a deck shares the row of 테마, which keeps its height whether the bar is
   shown or not; in a document it comes into the room after the section just shown. Either way
   it is one line high (its words cut short, all of them in its title) and never wraps taller. */
.wc-tools {
  align-items: center;
  min-height: 40px;
}
.wc-tools > .wc-pace,
.wc-partbar-room > .wc-pace {
  flex: 1;
  min-width: 0;
  height: 40px;
  flex-wrap: nowrap;
  gap: 10px;
  padding: 0 6px 0 12px;
}
.wc-partbar-room > .wc-pace {
  align-self: center;
}
.wc-tools > .wc-pace .wc-pace-text,
.wc-partbar-room > .wc-pace .wc-pace-text,
.wc-pace-top > .wc-pace .wc-pace-text {
  flex: 1 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.wc-tools > .wc-pace .wc-pace-acts,
.wc-partbar-room > .wc-pace .wc-pace-acts {
  flex: none;
}
.wc-pace-acts .btn {
  white-space: nowrap;
}
.wc-tools > .wc-theme-btn {
  flex: none;
  margin-left: auto;
}
/* A document's pause bar that is not in a room floats under the pages' top row, over the paper. */
.wc-pages-top > .wc-pace-top {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 3;
  max-width: none;
  margin: 4px 0 0;
}
.wc-pace-top > .wc-pace {
  box-shadow: var(--shadow);
}

/* The room kept for the bar of the part stopped: as tall as the bar (an unseen copy of it), the
   bar laid over the copy; while the hands type the part, a quiet line says a press stops them. */
.wc-partbar-room {
  display: grid;
}
.wc-partbar-room:not(.on) {
  display: none;
}
.wc-partbar-room > * {
  grid-area: 1 / 1;
  min-width: 0;
}
.wc-partbar-room.on {
  margin-top: 10px;
}
.wc-partbar-room > .wc-partbar-slot {
  margin: 0;
}
.wc-partbar-ghost {
  visibility: hidden;
  pointer-events: none;
}
.wc-partbar-wait {
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px dashed var(--line);
  border-radius: var(--r);
  color: var(--muted);
  font-size: 12.5px;
  text-align: center;
}
.wc-partbar-room.hint > .wc-partbar-wait {
  display: flex;
}
.wc-sec-room.on {
  margin: 4px 0 12px;
}
.wc-sec-room > .wc-partbar-wait {
  border-color: #e5e7eb;
  color: #6b7280;
}
/* (the column's scrollbar, coming as the notes or the bars make it taller than the window, takes
   no width from the slide: the slide, and the notes under it, never shrink up under the hand) */
.wc-main,
.wc-pages {
  scrollbar-gutter: stable;
}
/* (the line that tells a screen reader what a suggestion is, put at the end of the page: out of
   the page's flow, or it stood a pixel below the window, the page got a scrollbar and the whole
   canvas, the slide with it, went 10 px narrower and up under the student's hand) */
.ws-sug-live {
  position: fixed;
  top: 0;
  left: 0;
}
/* (the pause's bar in the room: the quiet line under it goes) */
.wc-partbar-room:has(> .wc-pace:not([hidden])) > .wc-partbar-wait {
  display: none;
}
/* (원래대로 is offered only on a rewrite: the room is not kept taller for it otherwise) */
.wc-partbar-room:not(.revise) .wc-ghost-old {
  display: none;
}

/* ---------- a slide designed by hand (spec 26.4): looks, formatted words, elements, backgrounds ---------- */

/* (the deck's own fonts, when its theme or design names them; else the page's, as always) */
.wc-s-in {
  isolation: isolate;
  font-family: var(--wc-bfont, var(--font));
}
.wc-box-title {
  font-family: var(--wc-tfont, inherit);
}
/* (a size of the box's own: the title's in --wc-ts, the body's in --wc-size with --wc-bs its share
   of 20 pt, by which the body's other words grow with it; none given: the sizes they always had) */
.wc-s-in .wc-box-title > .wc-s-title {
  font-size: calc(var(--u) * var(--wc-ts, 32));
  font-weight: var(--wc-tw, 700);
  font-family: inherit;
}
.wc-s-in .wc-box-title > .wc-s-title.wc-s-big {
  font-size: calc(var(--u) * var(--wc-ts, 44));
}
.wc-s-in .wc-s-sub {
  font-size: calc(var(--u) * 22 * var(--wc-bs, 1));
}
.wc-s-in .wc-s-under {
  font-size: calc(var(--u) * 18 * var(--wc-bs, 1));
}
.wc-s-in .wc-s-qtext {
  font-size: calc(var(--u) * 28 * var(--wc-bs, 1));
}
.wc-s-in .wc-s-by,
.wc-s-in .wc-s-cap {
  font-size: calc(var(--u) * 18 * var(--wc-bs, 1));
}
.wc-s-in .wc-s-qnote {
  font-size: calc(var(--u) * min(var(--wc-size, 20), 18 * var(--wc-bs, 1)));
}
.wc-s-in .wc-own-align,
.wc-s-in .wc-own-align * {
  text-align: var(--wc-ta);
}
.wc-s-in .wc-own-ls,
.wc-s-in .wc-own-ls * {
  line-height: var(--wc-lh);
}
.wc-s-in .wc-box.wc-filled {
  padding: calc(var(--u) * 7.2);
  border-radius: calc(var(--u) * 3);
}
.wc-s-in .wc-list-none .wc-s-list {
  list-style: none;
  padding-left: 0;
}
.wc-s-in .wc-list-number .wc-s-list {
  list-style: decimal;
}
.wc-s-in .wc-indented .wc-s-list {
  margin-left: calc(var(--u) * 36 * var(--wc-indent, 0));
}
.wc-s-in .wc-box-title.wc-indented > .wc-s-title {
  padding-left: calc(var(--u) * 36 * var(--wc-indent, 0));
}

/* formatted words: a span's size in points of the slide (of the page in a document) */
.wc-slide .rt[data-size] {
  font-size: calc(var(--u) * var(--rs));
}
.wc-d .rt[data-size] {
  font-size: calc(var(--rs) * 1pt);
}

/* the elements: text boxes, shapes and pictures, anywhere on the slide */
.wc-s-in > .wc-el {
  box-sizing: border-box;
  transform-origin: 50% 50%;
}
.wc-el-text {
  padding: calc(var(--u) * 7.2);
  color: var(--wc-text);
  line-height: 1.25;
}
.wc-el-txt {
  min-height: 1.25em;
  white-space: pre-wrap;
}
.wc-el-shape {
  display: flex;
  align-items: center;
}
.wc-el-shape > .wc-el-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}
.wc-el-shape > .wc-el-in {
  position: relative;
  width: 100%;
  max-height: 100%;
  padding: calc(var(--u) * 7.2);
  box-sizing: border-box;
  line-height: 1.25;
}
.wc-el-picture {
  overflow: hidden;
}
.wc-el-picture > img {
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
  user-select: none;
}
.wc-el-missing {
  border: max(1px, calc(var(--u) * 1.5)) dashed var(--wc-accent);
  background: color-mix(in srgb, var(--wc-accent) 8%, transparent);
}
/* (a finger dragging a picture or a shape moves it, as a mouse does, rather than scrolling the page) */
.wc-stage .wc-el-picture,
.wc-stage .wc-el-shape {
  cursor: move;
  touch-action: none;
}
.wc-stage .wc-el-shape [data-f="el"]:focus {
  cursor: text;
}
.wc-stage:focus {
  outline: none;
}
/* (an element's grips, as a box's; and the handle it is turned by, over its top) */
.wc-el:has(> .wc-edge):hover,
.wc-el.wc-box-active {
  outline: 1px dashed color-mix(in srgb, var(--wc-accent) 60%, transparent);
  outline-offset: 2px;
}
.wc-el:hover > :is(.wc-edge, .wc-handle, .wc-rot),
.wc-box-active > .wc-rot {
  opacity: 1;
}
.wc-slide .wc-chosen {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.wc-slide .wc-chosen > :is(.wc-edge, .wc-handle, .wc-rot) {
  opacity: 1;
}
.wc-rot {
  position: absolute;
  left: 50%;
  top: -28px;
  z-index: 3;
  width: 12px;
  height: 12px;
  margin-left: -6px;
  box-sizing: border-box;
  border: 1.5px solid var(--accent);
  border-radius: 50%;
  background: var(--surface);
  cursor: grab;
  opacity: 0;
  transition: opacity 0.12s;
  touch-action: none;
}
.wc-rot::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 100%;
  width: 1px;
  height: 15px;
  background: var(--accent);
}
@media (pointer: coarse) {
  .wc-el:has(> .wc-edge) {
    outline: 1px dashed color-mix(in srgb, var(--wc-accent) 45%, transparent);
    outline-offset: 2px;
  }
  .wc-el > :is(.wc-edge, .wc-handle, .wc-rot) {
    opacity: 1;
  }
  .wc-rot {
    width: 18px;
    height: 18px;
    margin-left: -9px;
    top: -34px;
  }
}
/* a box whose words run out of it at the size it was given: marked, never made smaller by itself */
.wc-over {
  position: absolute;
  right: 3px;
  bottom: 3px;
  z-index: 4;
  padding: 1px 6px;
  border-radius: 6px;
  background: #dc2626;
  color: #fff;
  font: 600 11px/1.5 var(--font);
  pointer-events: none;
}
.wc-thumb .wc-over {
  display: none;
}
/* the lines a box being moved is drawn to (the slide's middle, the other boxes' edges) */
.wc-s-in > .wc-guides {
  inset: 0;
  z-index: 50;
  pointer-events: none;
}
.wc-guide {
  position: absolute;
}
.wc-guide-x {
  top: 0;
  bottom: 0;
  border-left: 1px dashed #ec4899;
}
.wc-guide-y {
  left: 0;
  right: 0;
  border-top: 1px dashed #ec4899;
}
/* the picture place's 사진 넣기 */
.wc-s-image {
  gap: calc(var(--u) * 10);
  align-content: center;
}
.wc-s-image-add {
  font-size: 13px;
}
/* the picture the AI's hands carry from 그림 to the slide */
.wc-incoming {
  position: fixed;
  z-index: 2147483000;
  width: 72px;
  height: 54px;
  object-fit: cover;
  border-radius: 6px;
  box-shadow: var(--shadow);
  pointer-events: none;
}

/* ---------- the design toolbar (slidedesign.js) ---------- */

.sd-bar {
  /* (never squeezed by the column it stands in: on a phone the stage below it takes the room) */
  flex: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  margin: 10px 0 8px;
  padding: 5px 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}
.sd-group-row {
  display: flex;
  align-items: center;
  gap: 2px;
  padding-right: 8px;
  border-right: 1px solid var(--line);
}
.sd-group-row:last-child {
  padding-right: 0;
  border-right: 0;
}
.sd-btn {
  appearance: none;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}
.sd-btn:hover:not(:disabled),
.sd-btn:focus-visible {
  background: var(--surface-2);
}
.sd-btn[aria-pressed="true"],
.sd-btn[aria-expanded="true"],
.sd-btn.wh-pressed {
  background: var(--accent-soft);
  color: var(--accent-text);
}
.sd-btn:disabled,
.sd-font:disabled,
.sd-size:disabled {
  opacity: 0.38;
  cursor: default;
}
.sd-font {
  height: 30px;
  max-width: 132px;
  padding: 0 6px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 13px;
}
.sd-size-wrap {
  flex: none;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  height: 30px;
  padding: 0 6px 0 2px;
  border: 1px solid var(--line);
  border-radius: 7px;
}
.sd-size {
  flex: none;
  width: 42px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  text-align: right;
  -moz-appearance: textfield;
}
.sd-size::-webkit-inner-spin-button,
.sd-size::-webkit-outer-spin-button {
  margin: 0;
  -webkit-appearance: none;
}
.sd-size:focus {
  outline: none;
}
.sd-size-wrap:focus-within {
  box-shadow: 0 0 0 2px var(--ring);
}
.sd-unit {
  margin-left: 2px;
  color: var(--muted);
  font-size: 11px;
}
.sd-stack {
  display: grid;
  justify-items: center;
  gap: 1px;
}
.sd-colour-bar {
  width: 16px;
  height: 3px;
  border-radius: 2px;
}
.sd-mark-bar {
  box-shadow: inset 0 0 0 1px var(--line-strong);
}
/* a touch screen: the toolbar is one row that scrolls sideways, its buttons large enough for a finger */
@media (pointer: coarse) {
  .sd-bar {
    flex-wrap: nowrap;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: thin;
  }
  .sd-group-row {
    flex: none;
  }
  .sd-btn {
    width: 38px;
    height: 38px;
  }
  .sd-font,
  .sd-size-wrap {
    height: 38px;
  }
}

/* the toolbar's panels: palettes, shapes, the background, the theme gallery */
.sd-pop {
  position: fixed;
  z-index: 1200;
  max-width: min(420px, calc(100vw - 16px));
  max-height: min(70vh, 640px);
  overflow: auto;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
  font-size: 13px;
}
.sd-palette {
  display: grid;
  gap: 4px;
}
.sd-pal-row {
  display: flex;
  gap: 4px;
}
.sd-pal-theme {
  padding-bottom: 4px;
  border-bottom: 1px solid var(--line);
}
.sd-sw {
  width: 26px;
  height: 26px;
  padding: 0;
  border: 1px solid color-mix(in srgb, var(--ink) 18%, transparent);
  border-radius: 6px;
  background: var(--sw);
  cursor: pointer;
}
.sd-sw.on,
.sd-sw:focus-visible {
  box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent);
}
.sd-pal-foot {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin-top: 4px;
}
.sd-custom {
  position: relative;
  overflow: hidden;
}
.sd-custom-in {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}
.sd-shapes {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
}
.sd-shape {
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 6px 4px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 11.5px;
  cursor: pointer;
}
.sd-shape:hover,
.sd-shape:focus-visible {
  background: var(--surface-2);
}
.sd-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 8px;
}
.sd-tab {
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  cursor: pointer;
}
.sd-tab.on {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent-text);
}
.sd-row {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 8px;
  margin: 6px 0;
}
.sd-field {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 12px;
}
.sd-field input[type="color"] {
  width: 44px;
  height: 28px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: none;
}
.sd-field select {
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
}
.sd-grad-preview {
  height: 40px;
  margin-bottom: 6px;
  border-radius: 8px;
  border: 1px solid var(--line);
}
.sd-pics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-bottom: 8px;
}
.sd-pic {
  aspect-ratio: 4 / 3;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-2);
  cursor: pointer;
}
.sd-pic.on {
  box-shadow: 0 0 0 2px var(--accent);
}
.sd-pic img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.sd-scope {
  display: flex;
  gap: 12px;
  margin: 8px 0 4px;
}
.sd-radio {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.sd-reset {
  margin-top: 4px;
}
.sd-pop-gallery {
  width: min(420px, calc(100vw - 16px));
}
.sd-group + .sd-group {
  margin-top: 8px;
}
.sd-group h3 {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}
.sd-swatches {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
  gap: 6px;
}
.sd-theme {
  display: grid;
  gap: 4px;
  padding: 4px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 12px;
  text-align: center;
  cursor: pointer;
}
.sd-theme:hover,
.sd-theme:focus-visible {
  background: var(--surface-2);
}
.sd-theme.on {
  border-color: var(--accent);
}
.sd-mini {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 6px;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 15%, transparent);
}
.sd-mini > span {
  position: absolute;
  left: 9%;
  border-radius: 2px;
}
.sd-mini-acc {
  top: 12%;
  width: 14%;
  height: 4%;
}
.sd-mini-title {
  top: 22%;
  width: 62%;
  height: 11%;
}
.sd-mini-line {
  top: 48%;
  width: 78%;
  height: 6%;
  opacity: 0.75;
}
.sd-mini-line.short {
  top: 62%;
  width: 52%;
}
.sd-gallery-foot {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}
.sd-custom-panel {
  margin-top: 8px;
}
.sd-custom-preview {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.sd-cp-title {
  color: var(--cp-title);
  font-size: 16px;
  font-weight: 700;
}
.sd-cp-text {
  color: var(--cp-text);
  border-left: 3px solid var(--cp-accent);
  padding-left: 6px;
}
.sd-warn {
  margin: 6px 0 0;
  color: var(--warn);
  font-size: 12px;
}
.sd-apply {
  justify-content: flex-end;
}
@media (prefers-reduced-motion: reduce) {
  .wc-rot {
    transition: none;
  }
}
