.pg-layout { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 18px; align-items: start; }
.pg-sec { border: 1px solid var(--c-border); border-radius: var(--radius-sm); margin-bottom: 10px; background: var(--c-surface); }
.pg-sec > summary { padding: 9px 12px; font-weight: 600; cursor: pointer; }
.pg-fields { padding: 2px 12px 8px; }
.pg-field { margin-bottom: 10px; }
.pg-field textarea, .pg-field input[type=text], .pg-field select { width: 100%; }
.pg-req { color: var(--c-text-3); font-weight: 400; font-size: .8rem; }
.pg-multi { border: 0; margin: 0; padding: 0; }
.pg-multi legend { font-weight: 600; font-size: .9rem; padding: 0; margin-bottom: 3px; }
.pg-multi .check { display: flex; margin-bottom: 2px; }
.pg-multi .field { margin-top: 5px; }
.pg-out { position: sticky; top: 76px; min-width: 0; }
.pg-doc { border: 1px solid var(--c-border); border-radius: var(--radius-sm); background: #fff; color: #1f2937; padding: 22px 24px; max-height: calc(100vh - 210px); overflow: auto; line-height: 1.55; font-size: .92rem; overflow-wrap: anywhere; }
.pg-doc h1 { font-size: 1.45rem; line-height: 1.2; margin: 0 0 10px; color: #111827; }
.pg-doc h2 { font-size: 1.08rem; margin: 18px 0 6px; color: #111827; }
.pg-doc h3 { font-size: .98rem; margin: 12px 0 4px; color: #111827; }
.pg-doc p { margin: 0 0 9px; }
.pg-doc ul { margin: 0 0 9px; padding-left: 20px; }
.pg-doc mark { background: #fde68a; color: #111827; padding: 0 2px; border-radius: 2px; }
.pg-doc .draft-note { background: #fff7dc; border: 1px solid #d9a633; padding: 8px 11px; border-radius: 4px; font-size: .85rem; }
.pg-editor { width: 100%; height: calc(100vh - 210px); min-height: 340px; font-family: var(--font-mono, monospace); font-size: .85rem; line-height: 1.45; }
.pg-tabs { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 7px; }
.pg-print { position: absolute; left: -10000px; width: 800px; height: 600px; }
.pg-print iframe { height: 600px; }
@media (max-width: 900px) {
    .pg-layout { grid-template-columns: minmax(0, 1fr); }
    .pg-out { position: static; }
    .pg-doc { max-height: 70vh; }
    .pg-editor { height: 60vh; }
}
[data-form] { min-height: 620px; }
.pg-doc { min-height: 420px; }
