/* 유즈킷 — 여권·증명사진 규격 조절 (/id-photo/)
   외부 요청 없이 동작하는 자체 완결형 스타일시트 (외부 폰트·아이콘을 불러오지 않습니다)
   상단 메뉴·푸터는 site-chrome.css 가 맡고, 이 파일은 도구 화면과 본문만 꾸밉니다. */

:root {
  --bg: #faf8f1;
  --bg-soft: #f3eee0;
  --card: #ffffff;
  --ink: #1d1b16;
  --ink-2: #46433a;
  --muted: #7a7468;
  --line: #eae3d2;
  --line-strong: #d8cdb2;
  --brand: #e9a400;
  --brand-dark: #a56a00;
  --brand-soft: #fff4cc;
  --ok: #0a8f52;
  --warn: #b45309;
  --danger: #c2413b;
  --radius: 16px;
  --radius-sm: 11px;
  --shadow-sm: 0 1px 2px rgba(29, 27, 22, .05);
  --shadow: 0 1px 2px rgba(29, 27, 22, .04), 0 14px 32px -18px rgba(29, 27, 22, .28);
  --font: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, system-ui,
          "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body.idp-app {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  word-break: keep-all;
  overflow-wrap: break-word;
}

h1, h2, h3 { line-height: 1.3; letter-spacing: -.02em; margin: 0 0 .5em; font-weight: 800; }
h1 { font-size: clamp(1.6rem, 4.2vw, 2.45rem); }
h2 { font-size: clamp(1.22rem, 2.6vw, 1.6rem); margin-top: 0; }
h3 { font-size: 1.02rem; font-weight: 700; }
p { margin: 0 0 1em; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
code, kbd { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em; }
kbd {
  border: 1px solid var(--line-strong); border-bottom-width: 2px;
  border-radius: 5px; padding: 1px 5px; background: #fff; color: var(--ink-2);
}
img, canvas, svg { max-width: 100%; }

.wrap { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.muted { color: var(--muted); }
.tiny { font-size: .8rem; line-height: 1.55; }

/* ---------- buttons (site-chrome.css 와 같은 모양) ---------- */
.btn {
  --btn-bg: #fff; --btn-fg: var(--ink); --btn-bd: var(--line-strong);
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  font: inherit; font-size: .93rem; font-weight: 700;
  padding: 10px 16px; border-radius: 10px; cursor: pointer;
  background: var(--btn-bg); color: var(--btn-fg); border: 1px solid var(--btn-bd);
  transition: transform .06s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease;
  text-decoration: none; white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .48; cursor: not-allowed; }
.btn-primary {
  --btn-bg: var(--brand); --btn-fg: #fff; --btn-bd: transparent;
  box-shadow: 0 8px 18px -10px rgba(233, 164, 0, .85);
}
.btn-primary:hover:not(:disabled) { background: var(--brand-dark); }
.btn-soft { --btn-bg: var(--brand-soft); --btn-fg: var(--brand-dark); --btn-bd: #f0dfa8; }
.btn-soft:hover:not(:disabled) { background: #ffeeb0; }
.btn-sm { padding: 6px 11px; font-size: .82rem; border-radius: 9px; }
.btn-lg { padding: 14px 20px; font-size: 1rem; }
.btn-block { width: 100%; }

/* ---------- page head ---------- */
.page-head { padding: 30px 0 14px; }
.eyebrow {
  font-size: .78rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: var(--brand); margin-bottom: 10px;
}
.h1-sub {
  display: block; margin-top: 8px; font-size: .46em; font-weight: 600;
  letter-spacing: -.01em; color: var(--muted);
}
.lead { max-width: 800px; font-size: 1.03rem; color: var(--ink-2); }
.lead strong { color: var(--ink); }
.trust-row { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 14px 0 0; }
.trust-row li {
  font-size: .8rem; font-weight: 700; color: var(--ink-2);
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px;
}
.trust-row li::before { content: "✓"; color: var(--ok); margin-right: 6px; font-weight: 800; }

/* ---------- tool layout ---------- */
.tool { padding-bottom: 8px; }
.tool-grid { display: grid; grid-template-columns: minmax(0, 1fr) 372px; gap: 20px; align-items: start; }
.tool-main { min-width: 0; }

.dropzone {
  background: var(--card); border: 1.5px dashed var(--line-strong); border-radius: var(--radius);
  padding: 30px 22px; text-align: center; cursor: pointer;
  transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
  box-shadow: var(--shadow-sm);
}
.dropzone:hover, .dropzone:focus-visible { border-color: var(--brand); background: #fffdf4; outline: none; }
.dropzone.is-drag { border-color: var(--brand); background: var(--brand-soft); box-shadow: 0 0 0 4px rgba(233, 164, 0, .12); }
.dropzone.is-compact { padding: 11px 14px; display: flex; align-items: center; gap: 8px 14px; flex-wrap: wrap; text-align: start; }
.dropzone.is-compact .dz-icon { margin: 0; }
.dropzone.is-compact .dz-icon svg { width: 22px; height: 22px; }
.dropzone.is-compact .dz-title { margin: 0; font-size: .95rem; }
.dropzone.is-compact .dz-sub { margin: 0; flex: 1 1 12ch; min-width: 0; font-size: .8rem; }
.dropzone.is-compact .dz-actions { margin: 0 0 0 auto; }
.dz-icon { color: var(--brand); margin-bottom: 6px; }
.dz-title { font-size: 1.06rem; font-weight: 800; margin: 0 0 4px; }
.dz-sub { color: var(--muted); font-size: .85rem; margin: 0 0 4px; }
.dz-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 12px; }

/* ---------- editor stage ---------- */
.editor { margin-top: 12px; }
.stage-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 12px;
}
.stage-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 0 2px 10px; border-bottom: 1px solid var(--line); margin-bottom: 10px;
}
.stage-bar .file-name {
  font-size: .88rem; font-weight: 700; margin: 0; max-width: 30ch;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.stage-bar .file-sub { font-size: .76rem; color: var(--muted); display: flex; gap: 8px; flex-wrap: wrap; margin: 0; }
.stage-bar .stage-tools { display: flex; gap: 4px; flex-wrap: wrap; margin-inline-start: auto; }
.stage-bar .btn { padding: 6px 9px; font-size: .8rem; }

.stage-wrap {
  padding: 14px; border-radius: var(--radius-sm); border: 1px solid var(--line);
  background: repeating-conic-gradient(#efe9d8 0 25%, #f5f2e8 0 50%) 50% / 20px 20px;
  display: flex; justify-content: center; align-items: center; min-height: 220px;
}
.stage { position: relative; line-height: 0; touch-action: none; cursor: grab; user-select: none; }
.stage.is-dragging { cursor: grabbing; }
.stage canvas { display: block; border-radius: 3px; box-shadow: 0 10px 26px -16px rgba(29, 27, 22, .55); background: #fff; }
.stage canvas.guides { position: absolute; inset: 0; pointer-events: none; background: transparent; box-shadow: none; border-radius: 3px; }
.stage .guides-tag {
  position: absolute; inset-inline-start: 4px; top: 4px; pointer-events: none;
  font-size: .62rem; font-weight: 800; letter-spacing: .02em;
  background: rgba(29, 27, 22, .62); color: #fff; border-radius: 5px; padding: 1px 6px; line-height: 1.6;
}
.guide-note { font-size: .74rem; color: var(--muted); margin: 9px 2px 0; line-height: 1.5; }
.guide-note b { color: var(--ink-2); }

.empty-state { margin-top: 14px; text-align: center; color: var(--muted); font-size: .88rem; }
.empty-state .empty-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 12px; }
.empty-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 12px; text-align: start; box-shadow: var(--shadow-sm);
}
.empty-card b { display: block; font-size: .86rem; color: var(--ink); margin-bottom: 2px; }
.empty-card span { font-size: .78rem; }

/* ---------- panel ---------- */
.panel {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px; box-shadow: var(--shadow); position: sticky; top: 76px;
}
.panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.panel-head h2 { font-size: 1.02rem; margin: 0; }
.panel-head span { font-size: .74rem; color: var(--muted); font-weight: 700; }

.field { border: 0; padding: 0; margin: 0 0 16px; }
.field + .field { border-top: 1px solid var(--line); padding-top: 14px; }
.field > legend {
  padding: 0; font-size: .78rem; font-weight: 800; color: var(--ink-2);
  letter-spacing: .01em; margin-bottom: 8px; display: flex; align-items: center; gap: 6px;
}
.legend-val {
  font-weight: 700; color: var(--brand-dark); background: var(--brand-soft);
  border-radius: 6px; padding: 0 6px; font-variant-numeric: tabular-nums; font-size: .74rem;
}
.presets { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.preset {
  text-align: start; font: inherit; cursor: pointer; font-size: .8rem; font-weight: 700;
  background: #fff; color: var(--ink-2); border: 1px solid var(--line);
  border-radius: 9px; padding: 7px 8px; line-height: 1.3;
  transition: border-color .12s ease, background .12s ease, color .12s ease;
}
.preset span { display: block; font-size: .66rem; font-weight: 600; color: var(--muted); margin-top: 1px; }
.preset:hover { border-color: var(--brand); background: #fffdf4; color: var(--brand-dark); }
.preset.is-active { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-dark); }
.preset[data-preset="custom"] { grid-column: 1 / -1; }

select, input[type="number"], input[type="text"] {
  width: 100%; font: inherit; font-size: .88rem; color: var(--ink);
  background: #fff; border: 1px solid var(--line-strong); border-radius: 9px;
  padding: 8px 10px; transition: border-color .12s ease, box-shadow .12s ease;
}
select:focus, input[type="number"]:focus, input[type="text"]:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(233, 164, 0, .14);
}
input[type="range"] { width: 100%; accent-color: var(--brand); margin: 2px 0 0; }
input[type="checkbox"] { accent-color: var(--brand); }

.field-sub { margin-top: 10px; }
.field-sub:first-child { margin-top: 0; }
.range-scale { display: flex; justify-content: space-between; font-size: .68rem; color: var(--muted); margin-top: 1px; }
.help { font-size: .73rem; color: var(--muted); margin: 7px 0 0; line-height: 1.5; }
.help strong { color: var(--ink-2); }

.chips { display: flex; gap: 4px; flex-wrap: wrap; margin: 8px 0 0; }
.chip {
  font: inherit; font-size: .74rem; font-weight: 700; color: var(--ink-2);
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 4px 9px; cursor: pointer;
}
.chip:hover { border-color: var(--brand); color: var(--brand-dark); background: var(--brand-soft); }
.chip.is-active { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-dark); }

.check-line { display: flex; align-items: center; gap: 7px; font-size: .84rem; font-weight: 700; color: var(--ink-2); cursor: pointer; }

.custom-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 6px; align-items: center; }
.custom-row label { font-size: .72rem; font-weight: 700; color: var(--muted); display: block; margin-bottom: 2px; }
.custom-row input, .custom-row select { padding: 6px 8px; font-size: .82rem; }

/* 미세 조정 패드 */
.nudge {
  display: grid; grid-template-columns: repeat(3, 40px); grid-template-rows: repeat(3, 34px);
  gap: 4px; justify-content: center; margin: 4px auto 0;
}
.nudge button {
  font: inherit; font-size: .9rem; font-weight: 800; color: var(--ink-2);
  background: #fff; border: 1px solid var(--line-strong); border-radius: 8px; cursor: pointer;
  display: flex; align-items: center; justify-content: center; line-height: 1;
}
.nudge button:hover { border-color: var(--brand); color: var(--brand-dark); background: #fffdf4; }
.nudge .nudge-mid { border: 0; background: transparent; cursor: default; font-size: .62rem; color: var(--muted); }
.nudge .nudge-mid:hover { background: transparent; border: 0; color: var(--muted); }

.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; background: var(--bg-soft); border-radius: 10px; padding: 3px; }
.seg button {
  font: inherit; font-size: .79rem; font-weight: 700; color: var(--ink-2);
  background: transparent; border: 0; border-radius: 8px; padding: 7px 3px; cursor: pointer;
}
.seg button.is-active { background: #fff; color: var(--brand-dark); box-shadow: var(--shadow-sm); }

.save-row { display: grid; gap: 8px; }
.save-row .btn-primary { padding: 13px 16px; font-size: .98rem; }
.privacy-note { font-size: .72rem; color: var(--muted); text-align: center; margin: 8px 0 0; line-height: 1.5; }

.result {
  margin-top: 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--bg-soft);
  padding: 10px 12px; font-size: .8rem; color: var(--ink-2);
}
.result.is-ok { background: #eefaf2; border-color: #c8e9d5; color: #1c6a3f; }
.result.is-warn { background: #fff8ec; border-color: #f5dfb8; color: #7c5310; }
.result b { font-variant-numeric: tabular-nums; }
.result .result-title { display: block; font-weight: 800; margin-bottom: 3px; }

/* ---------- 실시간 규격 점검 ---------- */
.compliance {
  margin-top: 12px; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 12px 14px 10px;
}
.comp-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.comp-title { font-size: .84rem; font-weight: 800; margin: 0; color: var(--ink-2); letter-spacing: 0; }
.comp-badge {
  margin-inline-start: auto; font-size: .78rem; font-weight: 800; line-height: 1.4;
  border-radius: 999px; padding: 4px 11px; border: 1px solid var(--line-strong);
  background: var(--bg-soft); color: var(--ink-2); text-align: center;
}
.comp-badge.is-ok { background: #eefaf2; border-color: #c8e9d5; color: #1c6a3f; }
.comp-badge.is-warn { background: #fff8ec; border-color: #f5dfb8; color: #7c5310; }
.comp-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; }
.comp-item {
  display: flex; gap: 7px; align-items: flex-start;
  font-size: .78rem; line-height: 1.45; color: var(--ink-2);
  padding: 3px 6px; border-radius: 8px;
}
.comp-item.is-warn { background: #fffaf1; }
.comp-ico {
  flex: 0 0 16px; width: 16px; height: 16px; border-radius: 50%;
  font-size: .66rem; font-weight: 900; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center; margin-top: 1px;
}
.comp-item.is-ok .comp-ico { background: #e3f6ea; color: #0a8f52; }
.comp-item.is-warn .comp-ico { background: #fdeccb; color: #92400e; }
.comp-txt { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.comp-txt b { font-size: .78rem; color: var(--ink); font-weight: 800; }
.comp-txt span { color: var(--muted); }
.comp-item.is-warn .comp-txt span { color: #7c5310; }
.comp-note { font-size: .7rem; color: var(--muted); margin: 8px 2px 0; line-height: 1.5; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%);
  z-index: 60; max-width: min(92vw, 560px);
  background: #101828; color: #fff; font-size: .86rem; font-weight: 600;
  border-radius: 10px; padding: 11px 16px; box-shadow: 0 12px 30px -12px rgba(29, 27, 22, .7);
}
.toast.is-error { background: #8f2323; }

/* ---------- sections ---------- */
.intro { padding: 24px 0 4px; }
.badges { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 14px 0 0; }
.badges li {
  font-size: .78rem; font-weight: 700; color: var(--ink-2);
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 4px 11px;
}
.section { padding: 30px 0; }
.section-lead { max-width: 820px; color: var(--ink-2); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.step { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow-sm); }
.step p { margin: 0; font-size: .88rem; color: var(--ink-2); }
.step-n {
  display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px; border-radius: 8px; margin-bottom: 10px;
  background: var(--brand-soft); color: var(--brand-dark); font-weight: 800; font-size: .85rem;
}
.cards-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.cards-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.mini-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow-sm); }
.mini-card h3 { margin-bottom: 4px; }
.mini-card p { margin: 0; font-size: .87rem; color: var(--ink-2); }
.mini-card .tag {
  display: inline-block; font-size: .68rem; font-weight: 800; color: var(--brand-dark);
  background: var(--brand-soft); border-radius: 6px; padding: 1px 6px; margin-bottom: 6px;
}

.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
table { width: 100%; border-collapse: collapse; font-size: .86rem; min-width: 640px; }
th, td { padding: 11px 14px; text-align: start; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { background: var(--bg-soft); font-size: .77rem; color: var(--ink-2); white-space: nowrap; }
tbody th { font-weight: 700; color: var(--ink); width: 22%; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
td b { color: var(--brand-dark); }
td .num { font-variant-numeric: tabular-nums; }

.callout {
  background: var(--brand-soft); border: 1px solid #f0dfa8; border-radius: 12px;
  padding: 13px 16px; font-size: .88rem; color: var(--brand-dark); margin: 16px 0 6px;
}
.warn-box {
  background: #fff8ec; border: 1px solid #f5dfb8; border-radius: 12px;
  padding: 13px 16px; font-size: .88rem; color: #7c5310; margin: 14px 0 6px;
}
.checklist { margin: 10px 0 0; padding-inline-start: 20px; font-size: .88rem; color: var(--ink-2); }
.checklist li { margin-bottom: 5px; }

.faq { display: grid; gap: 8px; max-width: 920px; }
.faq details {
  background: var(--card); border: 1px solid var(--line); border-radius: 12px;
  padding: 0 16px; box-shadow: var(--shadow-sm);
}
.faq summary {
  cursor: pointer; font-weight: 700; font-size: .93rem; padding: 13px 26px 13px 0;
  list-style: none; position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; inset-inline-end: 2px; top: 50%; transform: translateY(-50%);
  color: var(--brand); font-size: 1.2rem; font-weight: 700; line-height: 1;
}
.faq details[open] summary::after { content: "−"; }
.faq details p { font-size: .89rem; color: var(--ink-2); margin: 0 0 13px; }

.noscript-note { background: #fff8ec; border: 1px solid #f5dfb8; border-radius: 12px; padding: 12px 14px; color: #7c5310; font-size: .9rem; }

/* ---------- RTL ---------- */
[dir="rtl"] .stage-bar .stage-tools { margin-inline-start: auto; }
[dir="rtl"] .range-scale { flex-direction: row-reverse; }
[dir="rtl"] .faq summary { padding: 13px 0 13px 26px; }
[dir="rtl"] .faq summary::after { inset-inline-end: auto; inset-inline-start: 2px; }

/* ---------- responsive ---------- */
@media (max-width: 1040px) {
  .tool-grid { grid-template-columns: 1fr; }
  .panel { position: static; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .cards-3 { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .page-head { padding: 20px 0 10px; }
  .dropzone { padding: 22px 14px; }
  .dz-actions { margin-top: 10px; }
  .steps, .cards-2 { grid-template-columns: 1fr; }
  .empty-state .empty-cards { grid-template-columns: 1fr; }
  .panel { padding: 14px; }
  .stage-wrap { padding: 8px; }
  .presets { grid-template-columns: 1fr 1fr; }
  th, td { padding: 9px 10px; }
  .nudge { grid-template-columns: repeat(3, 44px); grid-template-rows: repeat(3, 38px); }
  .compliance { padding: 11px 12px 9px; }
  .comp-head { align-items: flex-start; }
  .comp-badge { margin-inline-start: 0; width: 100%; text-align: start; }
  .comp-item { font-size: .76rem; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- 업로드 후 드롭존을 한 줄로 (yuzu-theme 의 대표 드롭존 규칙보다 우선) ---------- */
.tool-grid > .tool-main > .dropzone.is-compact {
  min-height: 0; flex-direction: row; flex-wrap: wrap; align-items: center;
  justify-content: flex-start; padding: 10px 14px; gap: 4px 12px; border-width: 1.5px;
  text-align: start; cursor: pointer;
}
.tool-grid > .tool-main > .dropzone.is-compact .dz-icon { order: 0; width: 24px; height: 24px; margin: 0; }
.tool-grid > .tool-main > .dropzone.is-compact .dz-title { order: 0; margin: 0; font-size: .9rem; font-weight: 700; color: var(--ink); }
.tool-grid > .tool-main > .dropzone.is-compact .dz-sub { order: 0; margin: 0; font-size: .76rem; max-width: none; flex: 1 1 16ch; min-width: 0; }
.tool-grid > .tool-main > .dropzone.is-compact .dz-actions { order: 0; margin: 0 0 0 auto; }
.tool-grid > .tool-main > .dropzone.is-compact .dz-actions .btn,
.tool-grid > .tool-main > .dropzone.is-compact .dz-actions .btn-primary {
  padding: 7px 13px; font-size: .84rem; border-radius: 9px; box-shadow: none;
}
@media (max-width: 620px) {
  .tool-grid > .tool-main > .dropzone.is-compact .dz-sub { display: none; }
  .tool-grid > .tool-main > .dropzone.is-compact .dz-actions { margin-inline-start: auto; }
}

/* ---------- RTL: 숫자·단위가 뒤집혀 보이지 않게 ---------- */
[dir="rtl"] td.num,
[dir="rtl"] .chip,
[dir="rtl"] .legend-val,
[dir="rtl"] #idp-res,
[dir="rtl"] .preset span { direction: ltr; }
[dir="rtl"] td.num, [dir="rtl"] .preset span, [dir="rtl"] .legend-val { text-align: right; }
[dir="rtl"] .chip { text-align: center; }
