/* =====================================================================
 * WorkOffice — 편집기/뷰어 스타일 (엑셀 · 워드 · PPT · PDF · 한글)
 * ===================================================================== */

.editor-page { display: flex; flex-direction: column; height: calc(100vh - 54px); overflow: hidden; }

.editor-head {
  display: flex; justify-content: space-between; align-items: center; gap: 14px;
  padding: 9px 16px; background: var(--surface); border-bottom: 1px solid var(--border); flex: none;
}
.ed-title { display: flex; flex-direction: column; min-width: 0; }
.ed-title strong { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 40vw; }

.peers { display: flex; align-items: center; gap: -4px; }
.peers .avatar { margin-left: -5px; border: 2px solid var(--surface); }

.save-status { font-size: 12px; color: var(--muted); min-width: 110px; text-align: right; }
.save-status.editing { color: var(--warn); }
.save-status.saving  { color: var(--primary); }
.save-status.ok      { color: oklch(45% .12 150); }
.save-status.fail    { color: var(--danger); }
.save-status.warn    { color: var(--warn); }

/* ---------------- 도구막대 ---------------- */
.editor-toolbar {
  display: flex; align-items: center; gap: 4px; flex-wrap: wrap;
  padding: 6px 14px; background: var(--surface);
  border-bottom: 1px solid var(--border); flex: none; min-height: 42px;
}
.tb-group { display: flex; align-items: center; gap: 4px; }
.tb-sep { width: 1px; height: 20px; background: var(--border); margin: 0 6px; }
.tb-btn {
  font-family: inherit; font-size: 12.5px; font-weight: 500;
  background: transparent; border: 1px solid transparent; border-radius: 6px;
  padding: 5px 10px; cursor: pointer; color: var(--text); white-space: nowrap;
}
.tb-btn:hover:not(:disabled) { background: var(--bg); border-color: var(--border-2); }
.tb-btn:disabled { opacity: .4; cursor: not-allowed; }
.tb-btn.active { background: var(--primary-weak); border-color: var(--primary); color: var(--primary-ink); font-weight: 700; }
.tb-label { font-size: 12px; color: var(--muted); padding: 0 4px; }
.tb-hint { font-size: 11.5px; color: var(--muted); }

.editor-host { flex: 1; overflow: auto; position: relative; background: var(--bg); }

/* 워터마크 정책 (문서 설정에서 켠 경우) */
.editor-host.watermarked::before {
  content: attr(data-watermark);
  position: absolute; inset: 0; z-index: 5; pointer-events: none;
  display: grid; place-items: center;
  font-size: 40px; font-weight: 800; color: rgba(120,120,140,.09);
  transform: rotate(-24deg); letter-spacing: .1em;
}
.editor-host.no-print { }
@media print { .editor-host.no-print { display: none !important; } }

/* =====================================================================
 * 스프레드시트
 * ===================================================================== */
.sheet-formulabar {
  display: flex; align-items: center; gap: 8px; padding: 6px 12px;
  background: var(--surface); border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 6;
}
.sheet-addr {
  min-width: 64px; font-size: 12px; font-weight: 700; text-align: center;
  border: 1px solid var(--border-2); border-radius: 5px; padding: 4px 6px;
}
.sheet-formulabar .fx { font-style: italic; color: var(--muted); font-size: 12px; }
.sheet-formula {
  flex: 1; font-family: ui-monospace, Menlo, monospace; font-size: 12.5px;
  border: 1px solid var(--border-2); border-radius: 5px; padding: 5px 9px; outline: none;
}

.sheet-grid-host { padding: 0 0 40px; overflow: auto; }
.sheet-table { border-collapse: separate; border-spacing: 0; font-size: 12.5px; background: var(--surface); }
.sheet-table th, .sheet-table td {
  border-right: 1px solid var(--border); border-bottom: 1px solid var(--border);
  padding: 0; height: 26px;
}
.sheet-table thead th {
  position: sticky; top: 0; z-index: 3;
  background: var(--bg); color: var(--muted); font-size: 11px; font-weight: 700;
  min-width: 92px; text-align: center;
}
.sheet-table th.corner, .sheet-table th.rowhead {
  position: sticky; left: 0; z-index: 2;
  background: var(--bg); color: var(--muted); font-size: 11px; font-weight: 600;
  min-width: 44px; width: 44px; text-align: center;
}
.sheet-table th.corner { z-index: 4; }
.sheet-table td.cell {
  padding: 3px 7px; min-width: 92px; max-width: 260px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: cell;
  position: relative;
}
/* ── 원본 시트 레이아웃 재현 ──
   숨김열: 엑셀에서 감춰 둔 계산용 열. 보이면 원본과 표 모양이 전혀 달라진다. */
.sheet-table .col-hidden { display: none; }
/* 열 너비가 지정된 열은 기본 min-width(92px)를 풀어야 지정 폭이 실제로 적용된다.
   (풀지 않으면 92px 미만 열이 전부 92px로 뭉개져 모든 열이 같은 폭으로 보인다) */
.sheet-table th.col-sized, .sheet-table td.col-sized { min-width: 0; max-width: none; }
/* 병합셀: 세로 병합이 많아 가운데 정렬이 원본과 가깝다 */
.sheet-table td.cell-merged { vertical-align: middle; }
/* 원본이 눈금선을 꺼 둔 시트 — 셀 경계선을 지운다(머리글 경계는 남긴다) */
.sheet-table.no-gridlines td.cell { border-right-color: transparent; border-bottom-color: transparent; }

.sheet-table td.cell.num { text-align: right; font-variant-numeric: tabular-nums; }
.sheet-table td.cell.formula { color: var(--primary-ink); }
.sheet-table td.cell.sel { outline: 2px solid var(--primary); outline-offset: -2px; background: var(--primary-weak); }
.sheet-table td.cell.editing { padding: 0; }
.cell-input {
  width: 100%; height: 100%; border: 0; outline: 2px solid var(--primary); outline-offset: -2px;
  padding: 3px 7px; font-family: inherit; font-size: 12.5px; background: var(--surface);
}
/* 다른 사람이 선택 중인 셀 */
.sheet-table td.cell.peer { box-shadow: inset 0 0 0 2px var(--peer); }
.sheet-table td.cell.peer::after {
  content: attr(data-peer); position: absolute; top: -14px; left: -1px; z-index: 5;
  background: var(--peer); color: #fff; font-size: 9px; font-weight: 700;
  padding: 0 4px; border-radius: 3px 3px 3px 0; white-space: nowrap;
}
.sheet-more { margin: 12px; }

.sheet-tabs {
  display: flex; gap: 2px; padding: 6px 10px; background: var(--surface);
  border-top: 1px solid var(--border); position: sticky; bottom: 0; z-index: 6; overflow-x: auto;
}
.sheet-tab {
  font-family: inherit; font-size: 12.5px; background: var(--bg); border: 1px solid var(--border);
  border-radius: 6px 6px 0 0; padding: 5px 14px; cursor: pointer; white-space: nowrap;
}
.sheet-tab.active { background: var(--surface); border-bottom-color: var(--surface); font-weight: 700; color: var(--primary-ink); }
.sheet-tab.add { color: var(--muted); }

/* =====================================================================
 * 워드 / 한글 / 텍스트 — 문단 블록
 * ===================================================================== */
.doc-wrap { padding: 26px 20px 80px; display: flex; justify-content: center; }
.doc-page {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 6px; box-shadow: var(--shadow);
  width: 100%; max-width: 820px; padding: 52px 62px; min-height: 60vh;
}
.doc-page.doc-plain { padding: 24px 28px; }

.doc-block {
  outline: none; padding: 3px 6px; margin: 0 -6px 3px; border-radius: 4px;
  font-size: 14.5px; line-height: 1.75; min-height: 1.75em; position: relative;
  /* 연속 공백·줄바꿈 보존 — 없으면 저장 시 원본 텍스트가 훼손된다 */
  white-space: pre-wrap;
}
.doc-block:hover { background: oklch(97% .004 260); }
.doc-block:focus { background: var(--primary-weak); box-shadow: inset 2px 0 0 var(--primary); }
.doc-block.is-empty::before { content: '빈 문단'; color: oklch(80% .01 260); font-size: 12px; }
.doc-block.is-empty:focus::before { content: none; }
.doc-block.mono { font-family: ui-monospace, Menlo, monospace; font-size: 13px; line-height: 1.6; }

h1.doc-block { font-size: 24px; font-weight: 800; margin-top: 22px; }
h2.doc-block { font-size: 19px; font-weight: 700; margin-top: 18px; }
h3.doc-block { font-size: 16px; font-weight: 700; margin-top: 14px; }
h4.doc-block, h5.doc-block, h6.doc-block { font-size: 14.5px; font-weight: 700; margin-top: 12px; }

.doc-block.in-table { border-left: 2px solid var(--border-2); padding-left: 10px; }
.doc-block.is-list { padding-left: 20px; }
.doc-block.is-list::marker { content: none; }
.doc-block.is-list::before { content: '·'; position: absolute; left: 6px; color: var(--muted); }
.doc-block.lv1 { padding-left: 38px; }
.doc-block.lv2 { padding-left: 56px; }

/* 서식이 여러 run으로 쪼개진 문단 — 편집 시 합쳐진다는 표시 */
.doc-block.is-mixed::after {
  content: '서식혼합'; position: absolute; right: -58px; top: 4px;
  font-size: 9.5px; color: var(--warn); opacity: .65;
}
.doc-block.hit { background: var(--warn-weak); }
.doc-block.remote-edit { animation: remoteFlash 900ms ease-out; }
@keyframes remoteFlash {
  0%   { background: var(--accent-weak); box-shadow: inset 2px 0 0 var(--accent); }
  100% { background: transparent; }
}
.doc-block.peer { box-shadow: inset 2px 0 0 var(--peer); }
.doc-block.peer::after {
  content: attr(data-peer); position: absolute; right: -6px; top: -12px;
  background: var(--peer); color: #fff; font-size: 9px; font-weight: 700;
  padding: 0 5px; border-radius: 3px; white-space: nowrap;
}

/* 한글 HWP 미리보기 */
.hwp-preview { border-top: 1px solid var(--border); padding-top: 14px; margin-top: 14px; max-height: 55vh; overflow-y: auto; }
.hwp-line { margin: 0 0 5px; font-size: 13.5px; line-height: 1.7; }

.image-view { display: grid; place-items: center; padding: 30px; }
.image-view img { max-width: 100%; box-shadow: var(--shadow); border-radius: 6px; }

.engine-frame { width: 100%; height: 100%; min-height: 70vh; border: 0; display: block; }

/* =====================================================================
 * 슬라이드 (PPTX) — 원본 레이아웃 그대로 그리기
 * ===================================================================== */
.slide-wrap { display: flex; height: 100%; }
.slide-strip {
  width: 190px; min-width: 190px; overflow-y: auto; padding: 10px;
  background: var(--surface); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 6px;
}
.slide-thumb {
  display: flex; gap: 8px; align-items: flex-start; text-align: left;
  background: var(--bg); border: 1px solid var(--border); border-radius: 6px;
  padding: 8px 10px; cursor: pointer; font-family: inherit; font-size: 11.5px; position: relative;
}
.slide-thumb.active { border-color: var(--primary); background: var(--primary-weak); }
.slide-thumb-no { font-weight: 800; color: var(--muted); flex: none; }
.slide-thumb-text { color: var(--text); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; }
.slide-thumb.peer { box-shadow: 0 0 0 2px var(--peer); }
.slide-thumb.peer::after {
  content: attr(data-peer); position: absolute; right: 4px; top: 4px;
  background: var(--peer); color: #fff; font-size: 9px; font-weight: 700; padding: 0 4px; border-radius: 3px;
}

.slide-stage { flex: 1; overflow: auto; padding: 22px; display: flex; flex-direction: column; align-items: center; }
.slide-stage.zoom-wide .ppt-canvas { max-width: none; width: 1600px; }

/* 슬라이드 캔버스 — 원본 비율 유지, 도형은 % 좌표로 절대 배치 */
.ppt-canvas {
  position: relative; width: 100%; max-width: 1180px; background: #fff;
  border: 1px solid var(--border); border-radius: 4px;
  box-shadow: 0 2px 14px rgba(16,20,40,.10); overflow: hidden; flex: none;
}
.ppt-shape { position: absolute; box-sizing: border-box; overflow: visible; }
.ppt-shape.ppt-pic { overflow: hidden; }
.ppt-img { width: 100%; height: 100%; object-fit: contain; display: block; }
.ppt-group { border: 1px dashed transparent; pointer-events: none; }

.ppt-shape.selected { outline: 2px solid var(--primary); outline-offset: 1px; z-index: 20; }
.ppt-shape:hover { outline: 1px dashed oklch(70% .08 260); outline-offset: 1px; }
.ppt-handle {
  position: absolute; width: 9px; height: 9px; background: #fff;
  border: 2px solid var(--primary); border-radius: 2px; z-index: 25;
}
.ppt-handle.h-nw { left: -5px; top: -5px; cursor: nwse-resize; }
.ppt-handle.h-ne { right: -5px; top: -5px; cursor: nesw-resize; }
.ppt-handle.h-sw { left: -5px; bottom: -5px; cursor: nesw-resize; }
.ppt-handle.h-se { right: -5px; bottom: -5px; cursor: nwse-resize; }

/* 텍스트 상자 — bodyPr 여백과 세로정렬을 그대로 반영 */
.ppt-text {
  width: 100%; height: 100%; display: flex; flex-direction: column;
  box-sizing: border-box; overflow: hidden;
}
.ppt-para {
  outline: none; word-break: break-word;
  /* 연속 공백과 줄바꿈을 그대로 보존해야 한다.
     기본값(normal)이면 HTML이 공백을 합치고 개행을 없애서,
     편집 후 저장할 때 원본 텍스트가 조용히 훼손된다(실제로 겪은 문제). */
  white-space: pre-wrap;
}
.ppt-para:focus { background: rgba(39,110,241,.08); box-shadow: inset 2px 0 0 var(--primary); }
.ppt-para.is-empty:empty::before { content: ''; }
.ppt-para.has-bullet { padding-left: 1em; text-indent: -1em; }
.ppt-para.has-bullet::before { content: '• '; }
.ppt-para.remote-edit { animation: remoteFlash 900ms ease-out; }

.ppt-table { width: 100%; height: 100%; border-collapse: collapse; }
.ppt-table td { border: 1px solid rgba(0,0,0,.15); padding: 2px 4px; vertical-align: middle; }

.slide-note { margin-top: 10px; }
.outline-slide { border-bottom: 1px solid var(--border); padding: 10px 0; }
.outline-slide h4 { margin: 0 0 6px; font-size: 14px; }
.outline-slide ul { margin: 0; padding-left: 20px; font-size: 13px; color: var(--muted); }

/* =====================================================================
 * PDF
 * ===================================================================== */
.pdf-wrap { display: flex; height: 100%; }
.pdf-side {
  width: 150px; min-width: 150px; background: var(--surface);
  border-right: 1px solid var(--border); display: flex; flex-direction: column; overflow: hidden;
}
.pdf-side-head { padding: 8px 12px; font-size: 11.5px; font-weight: 700; color: var(--muted); border-bottom: 1px solid var(--border); }
.pdf-thumbs { flex: 1; overflow-y: auto; padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.pdf-thumb {
  position: relative; background: var(--bg); border: 2px solid transparent;
  border-radius: 5px; padding: 4px; cursor: pointer; display: flex; justify-content: center;
}
.pdf-thumb.active { border-color: var(--primary); }
.pdf-thumb canvas { display: block; box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.pdf-thumb-no { position: absolute; bottom: 4px; right: 6px; font-size: 10px; color: var(--muted); background: rgba(255,255,255,.85); padding: 0 4px; border-radius: 3px; }
.pdf-thumb.peer { border-color: var(--peer); }
.pdf-thumb.peer::after {
  content: attr(data-peer); position: absolute; top: 2px; left: 2px;
  background: var(--peer); color: #fff; font-size: 9px; font-weight: 700; padding: 0 4px; border-radius: 3px;
}

.pdf-viewport { flex: 1; overflow: auto; padding: 20px; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.pdf-viewport.picking { cursor: crosshair; }
.pdf-page { position: relative; background: #fff; box-shadow: var(--shadow); border-radius: 3px; }
.pdf-canvas { display: block; border-radius: 3px; }

.pdf-textlayer { position: absolute; inset: 0; overflow: hidden; line-height: 1; opacity: .01; }
.pdf-text { position: absolute; white-space: pre; transform-origin: 0 0; color: transparent; }
.pdf-textlayer .pdf-text.hit { background: var(--warn); opacity: 1; color: transparent; border-radius: 2px; }
.pdf-viewport:has(.pdf-text.hit) .pdf-textlayer { opacity: 1; }

.pdf-annolayer { position: absolute; inset: 0; }
.anno { position: absolute; border-radius: 2px; cursor: pointer; }
.anno-highlight { background: var(--anno-color); opacity: .38; }
.anno-underline { border-bottom: 2px solid var(--anno-color); }
.anno-strikeout { border-top: 2px solid var(--anno-color); }
.anno-rect      { border: 2px solid var(--anno-color); }
.anno-redact    { background: #111; opacity: .82; border: 1px dashed #fff; }
.anno-ghost     { background: var(--anno-color); opacity: .3; border: 1px dashed var(--anno-color); pointer-events: none; }
.anno-note {
  background: var(--anno-color); border-radius: 50% 50% 50% 2px;
  display: grid; place-items: center; min-width: 20px; min-height: 20px;
  box-shadow: 0 1px 4px rgba(0,0,0,.25);
}
.anno-pin { font-size: 11px; }
.anno.resolved { opacity: .28; }
.anno-tip {
  position: absolute; left: 0; top: 100%; margin-top: 3px;
  background: var(--navbar); color: #fff; font-size: 10.5px; padding: 2px 6px;
  border-radius: 4px; white-space: nowrap; opacity: 0; pointer-events: none; transition: .15s;
}
.anno:hover .anno-tip { opacity: 1; }

.pdf-pageinput {
  width: 46px; text-align: center; font-size: 12px; font-family: inherit;
  border: 1px solid var(--border-2); border-radius: 5px; padding: 4px;
}

.pageop-list { display: flex; flex-direction: column; gap: 5px; max-height: 46vh; overflow-y: auto; }
.pageop-row {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding: 7px 12px; background: var(--bg); border: 1px solid var(--border);
  border-radius: 6px; font-size: 12.5px;
}
.pageop-row.removed { opacity: .45; text-decoration: line-through; }
.pageop-no { font-weight: 700; min-width: 32px; }

@media (max-width: 900px) {
  .pdf-side, .slide-strip { display: none; }
  .doc-page { padding: 26px 20px; }
  .doc-block.is-mixed::after { display: none; }
}

/* ---------------- 수식 · 선택 · 상태 (웹엑셀 확장) ---------------- */
.formula-hint { font-size: 11.5px; color: var(--muted); white-space: nowrap; max-width: 40%; overflow: hidden; text-overflow: ellipsis; }
.formula-hint.bad { color: var(--danger); }

.sheet-table td.cell.in-sel { background: var(--primary-weak); }
.sheet-table th.colhead.hl, .sheet-table th.rowhead.hl { background: var(--primary-weak); color: var(--primary-ink); }
.sheet-table th.colhead, .sheet-table th.rowhead, .sheet-table th.corner { cursor: pointer; }

/* 수식 셀 / 오류 셀 */
.sheet-table td.cell.formula { color: var(--primary-ink); }
.sheet-table td.cell.cell-error {
  color: var(--danger); background: var(--danger-weak); font-weight: 600; text-align: center;
}
/* 우리가 계산하지 못해 원본 값을 그대로 쓰는 셀 — 오른쪽 위 작은 삼각형 */
.sheet-table td.cell.cell-unsupported { position: relative; }
.sheet-table td.cell.cell-unsupported::after {
  content: ''; position: absolute; top: 0; right: 0;
  border-width: 0 5px 5px 0; border-style: solid;
  border-color: transparent var(--warn) transparent transparent;
}

/* 상태 표시줄 (시트 탭 오른쪽) */
.sheet-status {
  margin-left: auto; display: flex; align-items: center; gap: 6px;
  font-size: 11.5px; color: var(--muted); padding-right: 6px; white-space: nowrap;
}
.sheet-status .st-sep { opacity: .4; }

/* 함수 목록 모달 */
.fn-group h4 { margin: 12px 0 6px; font-size: 13px; }
.fn-list { display: flex; flex-wrap: wrap; gap: 5px; }
.fn-chip {
  font-family: ui-monospace, Menlo, monospace; font-size: 11.5px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 5px;
  padding: 2px 7px; cursor: pointer;
}
.fn-chip:hover { border-color: var(--primary); background: var(--primary-weak); color: var(--primary-ink); }

/* ---------------- 드래그 시 셀 텍스트가 선택되지 않게 ---------------- */
.sheet-grid-host, .sheet-table { user-select: none; -webkit-user-select: none; }
.sheet-table td.cell.editing, .cell-input { user-select: text; -webkit-user-select: text; }

/* ---------------- 홈 리본 ---------------- */
.tb-sq {
  font-family: inherit; font-size: 12.5px; min-width: 28px; height: 26px;
  background: transparent; border: 1px solid transparent; border-radius: 5px;
  cursor: pointer; color: var(--text); position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 2px; padding: 0 5px;
}
.tb-sq:hover:not(:disabled) { background: var(--bg); border-color: var(--border-2); }
.tb-sq:disabled { opacity: .4; cursor: not-allowed; }
.tb-sq.active { background: var(--primary-weak); border-color: var(--primary); color: var(--primary-ink); }
.tb-sq.f-b { font-weight: 800; }
.tb-sq.f-i { font-style: italic; font-family: Georgia, serif; }
.tb-sq.f-u { text-decoration: underline; }
.tb-sq.f-s { text-decoration: line-through; }
.tb-sq .sw-bar {
  position: absolute; left: 4px; right: 4px; bottom: 2px; height: 3px;
  border-radius: 2px; border: 1px solid var(--border-2);
}
.tb-select {
  font-family: inherit; font-size: 12px; height: 26px; padding: 0 5px;
  border: 1px solid var(--border-2); border-radius: 5px; background: var(--surface); color: var(--text);
  max-width: 130px;
}
.tb-select.sm { max-width: 58px; }

/* 색상 팔레트 팝업 */
.color-pop {
  position: fixed; z-index: 400; background: var(--surface);
  border: 1px solid var(--border-2); border-radius: 8px; box-shadow: var(--shadow);
  padding: 8px; display: flex; flex-direction: column; gap: 6px;
}
.color-grid { display: grid; grid-template-columns: repeat(5, 22px); gap: 4px; }
.color-sw { width: 22px; height: 22px; border: 1px solid var(--border-2); border-radius: 4px; cursor: pointer; }
.color-sw:hover { outline: 2px solid var(--primary); outline-offset: 1px; }

/* ---------------- 함수 자동완성 ---------------- */
.fx-auto {
  position: fixed; z-index: 500; width: 330px; max-height: 230px; overflow-y: auto;
  background: var(--surface); border: 1px solid var(--border-2);
  border-radius: 8px; box-shadow: 0 8px 28px rgba(16,20,40,.16);
}
.fx-item { padding: 6px 10px; cursor: pointer; border-bottom: 1px solid var(--border); }
.fx-item:last-child { border-bottom: 0; }
.fx-item.active { background: var(--primary-weak); }
.fx-sig { font-family: ui-monospace, Menlo, monospace; font-size: 12px; }
.fx-sig strong { color: var(--primary-ink); }
.fx-args { color: var(--muted); }
.fx-desc { font-size: 11.5px; color: var(--muted); margin-top: 1px; }

/* ---------------- 채우기 핸들 ---------------- */
.sheet-table td.cell.sel { overflow: visible; }
.fill-handle {
  position: absolute; right: -4px; bottom: -4px; width: 8px; height: 8px;
  background: var(--primary); border: 1px solid #fff; border-radius: 1px;
  cursor: crosshair; z-index: 4;
}
.fill-handle:hover { transform: scale(1.35); }
.sheet-table td.cell.fill-prev {
  background: var(--primary-weak);
  box-shadow: inset 0 0 0 1px var(--primary);
}

/* 머리글 드래그 중 텍스트 선택 방지 */
.sheet-table th.rowhead, .sheet-table th.colhead, .sheet-table th.corner {
  user-select: none; -webkit-user-select: none;
}

/* 도형 윤곽(SVG) — custGeom·선·타원·화살표 */
.ppt-geom { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.ppt-shape.ppt-shape { }
.ppt-text { position: relative; z-index: 1; }

/* 차트 */
/* 도형 div(.ppt-shape.ppt-chart)와 구분하려고 내부 래퍼는 ppt-chart-box 로 둔다 */
.ppt-chart-box { width: 100%; height: 100%; display: grid; place-items: center; overflow: hidden; }
.ppt-chart-box svg { max-width: 100%; max-height: 100%; }
.ppt-chart-fallback {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  color: var(--muted); font-size: 12px; text-align: center;
}
.ppt-chart-fallback em { font-style: normal; font-size: 10.5px; opacity: .7; }
