.json-page .tool-topbar { min-height: 48px; padding: 5px 16px; display: flex; align-items: center; gap: 20px; border-bottom: 1px solid var(--pa-border); background: var(--pa-panel); }
.tool-topbar .brand { font-size: 19px; letter-spacing: 0; }
.tool-topbar .brand-mark { width: 28px; height: 28px; border-radius: 6px; font-size: 24px; }
.tool-topbar .brand-mark span { font-size: 17px; }
.tool-title { margin: 0; font-size: 16px; line-height: 1.5; letter-spacing: 0; white-space: nowrap; }
.tool-topbar nav { display: flex; flex-wrap: wrap; gap: 13px; font-size: 12px; color: var(--muted); }
.tool-topbar nav strong { color: var(--text); font-weight: 400; }
.tool-topbar nav a:hover { color: var(--accent); }
.privacy-badge { display: flex; align-items: center; gap: 8px; margin-left: auto; padding: 6px 12px; border: 1px solid #29413e; border-radius: 20px; color: #94b9ad; font-size: 11px; white-space: nowrap; }
.privacy-badge > span { width: 5px; height: 5px; background: var(--accent); border-radius: 50%; box-shadow: 0 0 8px #63e5cd55; }
.json-workspace { max-width: none; padding: 8px 12px 0; }
.workspace-stage { height: calc(100vh - 64px); height: calc(100dvh - 64px); min-height: 0; display: flex; flex-direction: column; }
.tool-intro { display: flex; align-items: center; flex-shrink: 0; }
.tool-intro > div:first-child { display: flex; align-items: center; gap: 24px; }
.tool-intro .section-kicker { display: none; }
.tool-intro h1 { margin: 0; font-size: 28px; letter-spacing: -1px; white-space: nowrap; }
.tool-intro h1 .title-symbol { color: #3c615e; display: inline-block; margin-left: 20px; font: 30px Consolas, monospace; vertical-align: middle; }
.tool-intro p { margin: 0; }
.intro-detail { display: none; }
.editor-workbench { flex: 1; min-height: 0; display: flex; flex-direction: column; border: 1px solid var(--pa-border); border-radius: 6px; overflow: hidden; background: var(--pa-panel); }
.workbench-toolbar { flex-shrink: 0; padding: 3px 10px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; background: var(--pa-raised); border-bottom: 1px solid var(--pa-border); }
.json-workspace .workbench-toolbar .tool-signature { flex: 1; min-width: 0; margin: 0; padding: 0 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: center; color: var(--pa-muted); font-size: 12px; }
.actions { display: flex; gap: 9px; }
.actions button { min-height: 30px; padding: 5px 12px; border-radius: 7px; font-size: 12px; }
.actions .primary-button > span:first-child { font-family: Consolas, monospace; font-weight: 700; }
.shortcut { margin-left: 10px; padding-left: 10px; border-left: 1px solid #27746455; font-size: 10px; opacity: .7; }
.indent-control { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); }
.workbench-options { display: flex; align-items: center; gap: 16px; }
.watermark-control { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 11px; white-space: nowrap; cursor: pointer; }
.watermark-control input { width: 13px; height: 13px; margin: 0; accent-color: var(--accent); }
select { font: inherit; color: #ccd7e5; background: #0e1722; border: 1px solid #304151; border-radius: 6px; padding: 4px 8px; }
.editor-columns { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); }
.editor-panel { min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.input-panel { border-right: 1px solid #273442; }
.panel-heading { flex-shrink: 0; min-height: 34px; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; padding: 5px 12px; border-bottom: 1px solid #202c3a; }
.panel-heading > div { display: flex; align-items: center; gap: 10px; }
.panel-heading h2 { margin: 0; font-size: 12px; font-weight: 500; }
.input-panel .panel-heading > div:first-child { flex: 1; min-width: 0; }
.input-panel .panel-heading h2, .input-panel .panel-dot, .input-panel .panel-code { flex-shrink: 0; }
.source-filename { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #a0b1c6; font-size: 11px; }
.source-evidence { flex-shrink: 0; padding: 5px 12px; background: #0d141f; border-bottom: 1px solid #273442; }
.source-evidence-actions { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 4px; font-size: 10px; color: #8397ae; }
.source-evidence-actions a { flex-shrink: 0; color: var(--accent); }
.original-preview { display: block; width: 100%; height: 84px; padding: 2px; border: 1px solid #273442; border-radius: 4px; background: #111c29; cursor: zoom-in; }
.original-preview img { display: block; width: 100%; height: 100%; object-fit: contain; }
#original-dialog { width: min(1600px, calc(100vw - 40px)); max-height: calc(100dvh - 40px); padding: 12px; }
.original-dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.original-dialog-heading > div { min-width: 0; }
.original-dialog-heading h2 { margin: 0; font-size: 14px; }
#original-filename { display: block; margin-top: 5px; font-size: 12px; overflow-wrap: anywhere; color: #a0b1c6; }
#close-original { flex-shrink: 0; padding: 4px 10px; }
#original-dialog > p { margin: 8px 0; color: #8397ae; font-size: 11px; }
.original-image-viewport { max-height: calc(100dvh - 150px); overflow: auto; background: #0d141f; }
#original-full-image { display: block; max-width: none; }
.panel-dot { width: 6px; height: 6px; background: #8899ec; border-radius: 50%; }
.output-dot { background: var(--accent); }
.panel-code { font: 8px Consolas, monospace; color: #586d85; letter-spacing: 1px; }
.panel-actions { gap: 4px !important; }
.panel-actions button { padding: 3px 8px; border: 0; border-radius: 4px; background: none; color: #90a3bb; font-size: 11px; }
.panel-actions button:not(:disabled):hover { background: #223345; color: var(--accent); }
.panel-actions #preview { color: var(--accent); font-weight: 700; }
.input-area, .output-area { flex: 1; min-height: 0; width: 100%; height: auto; background: #0d141f; }
.input-area { position: relative; overflow: hidden; }
#source, #source-highlight { width: 100%; height: 100%; margin: 0; font: 13px/1.7 Consolas, "Cascadia Code", monospace; tab-size: 4; padding: 18px 20px; white-space: pre; scrollbar-gutter: stable; scrollbar-color: #425b72 #0d141f; }
#source { position: relative; display: block; border: 0; outline-offset: -2px; resize: none; color: #cad8e9; background: transparent; overflow: auto; }
#source-highlight { position: absolute; inset: 0; color: transparent; pointer-events: none; overflow: hidden; }
.source-error-mark { color: transparent; background: #ef8d8d55; box-shadow: 0 1px #f0a0a0; }
#source::placeholder { color: #4e627c; }
#source[aria-invalid="true"] { box-shadow: inset 3px 0 #ed8e8e; }
.input-error { flex-shrink: 0; padding: 9px 16px; border-bottom: 1px solid #7d454a; background: #e78c8c18; color: #f0b6b6; font-size: 11px; }
.image-notice { flex-shrink: 0; padding: 6px 12px; border-bottom: 1px solid #685a38; background: #a8802418; color: #dfc78e; font-size: 11px; line-height: 1.6; }
.input-error > div { display: flex; align-items: baseline; gap: 12px; }
.input-error strong { flex: 1; font-weight: 500; overflow-wrap: anywhere; }
.input-error button { flex-shrink: 0; padding: 2px 7px; border: 1px solid #835457; border-radius: 4px; background: transparent; color: inherit; font-size: 11px; }
#input-error-context { margin: 6px 0 0; font: 12px/1.6 Consolas, "Cascadia Code", monospace; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 4.8em; overflow: auto; }
#input-error-context mark { color: #ffe0e0; background: #ed8e8e44; border-bottom: 1px solid #efabab; }
.output-area { position: relative; overflow: auto; scrollbar-gutter: stable; scrollbar-color: #425b72 #0d141f; }
#output, #preview-output { margin: 0; min-height: 100%; padding: 18px 20px; color: var(--pa-text); font: 13px/1.7 Consolas, "Cascadia Code", monospace; tab-size: 4; white-space: pre; outline-offset: -2px; }
.json-key { color: #94b5fa; }.json-string { color: #80d6b5; }.json-number { color: #e5bd83; }.json-literal { color: #b19bef; }
.json-fold { position: relative; }
.json-fold-toggle { position: relative; display: inline-block; width: 12px; height: 12px; margin-left: -15px; margin-right: 3px; padding: 0; border: 0; vertical-align: baseline; overflow: visible; background: transparent; color: var(--pa-text); font: inherit; line-height: 10px; }
.json-fold-toggle::before { content: '-'; position: absolute; inset: 0; border: 1px solid var(--pa-subtle); border-radius: 2px; background: var(--pa-panel); text-align: center; font: 10px/10px Consolas, monospace; }
.json-fold-toggle[aria-expanded="false"]::before { content: '+'; }
.json-fold-toggle:hover { color: var(--pa-accent); }
.json-fold-toggle:hover::before { border-color: var(--pa-accent); }
.json-fold-placeholder { color: var(--pa-subtle); }
#output-empty { min-height: 100%; display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 30px; text-align: center; }
#output-empty > span { color: #2c4952; font: 56px Consolas, monospace; margin-bottom: 15px; }
#output-empty h3 { color: #7c96ac; font-size: 14px; font-weight: 500; margin: 0 0 9px; }
#output-empty p { font-size: 11px; color: #51677f; margin: 0; }
.editor-footer { flex-shrink: 0; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 5px; padding: 3px 12px; border-top: 1px solid var(--pa-border); color: var(--pa-muted); font-size: 10px; }
.workbench-status { flex-shrink: 0; padding: 3px 12px; border-top: 1px solid var(--pa-border); display: flex; align-items: baseline; gap: 10px; color: var(--pa-muted); font-size: 11px; overflow-wrap: anywhere; }
.status-indicator { width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0; background: #7f93a6; }
.workbench-status.success { color: #8dd8bf; background: #15302644; }.success .status-indicator { background: #63e5cd; }
.workbench-status.error { color: #efabab; background: #3b202844; }.error .status-indicator { background: #ed8e8e; }
.feature-notes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; padding: 28px 2px 0; }
.feature-notes article { display: flex; gap: 13px; }
.feature-icon { color: #65857e; font: 10px/2 Consolas, monospace; padding-top: 2px; }
.feature-notes h3 { margin: 0 0 5px; font-size: 12px; font-weight: 500; color: #a8bacb; }
.feature-notes p { margin: 0; font-size: 11px; line-height: 1.9; color: #647b93; }
.workspace-help { margin-top: 8px; font-size: 11px; color: var(--pa-muted); }
.workspace-help summary { cursor: pointer; width: fit-content; }
.json-workspace .page-footer { margin-top: 8px; padding: 8px 0; }
.json-workspace .tool-signature { color: var(--pa-muted); font-size: 11px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
#result-preview { width: min(1200px, calc(100vw - 48px)); height: min(850px, calc(100dvh - 64px)); max-width: none; max-height: none; padding: 0; border: 1px solid var(--pa-border); border-radius: 6px; background: var(--pa-panel); color: var(--pa-text); overflow: hidden; }
#result-preview[open] { display: flex; flex-direction: column; }
#result-preview::backdrop { background: #0008; }
.preview-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 16px; border-bottom: 1px solid var(--pa-border); }
.preview-heading h2 { margin: 0; font-size: 14px; }
#preview-status { flex: 1; min-width: 0; font-size: 11px; color: var(--pa-muted); overflow-wrap: anywhere; }
#preview-output { flex: 1; min-height: 0; overflow: auto; background: var(--pa-raised); scrollbar-gutter: stable; scrollbar-color: var(--pa-border-strong) var(--pa-raised); }
@media (max-width: 1000px) {
  .tool-topbar { gap: 24px; }.tool-topbar nav { display: none; }.intro-detail { display: none; }
  .panel-heading { padding: 5px 10px; }.panel-heading > div { gap: 7px; }.panel-code { display: none; }
  #source, #source-highlight, #output, #preview-output { padding: 17px; }.feature-notes { gap: 18px; }
}
@media (max-width: 760px) {
  .json-page .tool-topbar { padding: 5px 10px; min-height: 48px; gap: 10px; flex-wrap: nowrap; }.tool-topbar .brand { font-size: 17px; gap: 6px; }.tool-topbar .brand-domain, .privacy-badge, .tool-topbar .pathadd-theme-control > span { display: none; }
  .tool-title { font-size: 13px; }.tool-topbar .pathadd-theme-control { gap: 0; }.tool-topbar .pathadd-theme-control select { min-width: 0; width: 92px; padding: 4px; font-size: 11px; }
  .json-workspace { padding: 6px 6px 0; }.workspace-stage { height: auto; min-height: 0; }
  .editor-workbench, .editor-columns { flex: none; }.editor-columns { grid-template-columns: minmax(0, 1fr); }.input-panel { border-right: 0; border-bottom: 1px solid #2b3947; }
  .input-area, .output-area { flex: none; height: max(180px, calc((100vh - 250px) / 2)); height: max(180px, calc((100dvh - 250px) / 2)); }.workbench-toolbar { padding: 4px 8px; }.shortcut { display: none; }.actions button { padding: 4px 8px; }.workbench-options { gap: 8px; }.indent-control { gap: 5px; font-size: 11px; }.watermark-control { font-size: 10px; }
  .feature-notes { grid-template-columns: 1fr; gap: 18px; padding-top: 22px; }.json-workspace .page-footer { display: block; }
}
@media (max-width: 380px) { .brand-domain { display: none; }.privacy-badge { font-size: 9px; }.indent-control { margin-left: auto; } }
