/* Бумажные куклы: детали печатаются в натуральную величину (размеры в мм заданы в SVG, кукла 12/16 см от макушки
   до подошв), поле раскладки 184 × 230 мм (PD_AREA в engine.js). Чтобы поле влезло в рамку Printitos и на Letter,
   у листов с деталями заголовок ниже обычного. */
.pd-in { width: 100%; font: 15px var(--body); padding: 7px 10px; border: 2px solid var(--line); border-radius: 10px; box-sizing: border-box; }
.pd-presets, .pd-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.pd-actions { margin: 4px 0 10px; }
.panel .pd-presets .btn, .panel .pd-actions .btn { width: auto; font-size: 14px; padding: 6px 12px; border-radius: 999px; background: #fff; color: var(--ink); border: 2px solid var(--line); box-shadow: none; }
.panel .pd-presets .btn[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.pd-radios label { display: flex; gap: 8px; align-items: flex-start; margin: 6px 0; font-size: 14px; line-height: 1.4; cursor: pointer; }
.pd-radios input { margin-top: 3px; accent-color: var(--brand-dark); }
.pd-things { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.pd-thing { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px 4px; border: 2px solid var(--line); border-radius: 10px; cursor: pointer; font-size: 12.5px; line-height: 1.25; text-align: center; min-width: 0; position: relative; }
.pd-thing:has(input:checked) { border-color: var(--brand); background: #fff4ec; }
.pd-thing input { position: absolute; top: 5px; left: 5px; accent-color: var(--brand-dark); }
.pd-thing .pd-svg { width: auto; height: 96px; max-width: 100%; }
.pd-small .pd-svg { height: 60px; }
#pd-wardrobe.pd-off { opacity: .5; }
#pd-try-view { height: 260px; margin-top: 8px; }
#pd-try-view svg { display: block; height: 100%; width: auto; max-width: 100%; margin: auto; }
#pd-err:not([hidden]) { color: #b3261e; font-weight: 700; }

/* лист с деталями: поле раскладки и детали в мм */
.sheet:has(.pd-area) .sheet-title { font-size: 20pt; margin: 3mm 0 2mm; }
.pd-area { position: relative; flex-shrink: 0; align-self: flex-start; }
.pd-piece { position: absolute; }
.pd-svg { display: block; overflow: visible; }
.pd-svg text { font-family: var(--body); }
.pd-bw image { filter: grayscale(1); }
/* инструкции */
.pd-col { width: 100%; align-self: flex-start; display: flex; flex-direction: column; }
.pd-text { font: 10.5pt/1.45 var(--body); color: #333; }
.pd-text h3 { font: 600 1.3em/1.25 var(--head); color: var(--brand-dark); margin: 3mm 0 1.5mm; }
.pd-text p { margin: 0 0 2mm; }
.pd-text ol { margin: 1mm 0 2mm; padding-left: 6mm; }
.pd-text li { margin-bottom: 1.5mm; }
.pd-box { border: .35mm solid var(--brand); border-radius: 3mm; background: #fff7ef; padding: 3mm 4mm; }
.pd-scale { display: block; margin: 2mm auto 0; flex-shrink: 0; }
.pd-scale text { font-family: var(--body); }
.pd-note { font-size: .9em; color: #555; margin-top: 3mm; }
.pd-diagram { display: block; margin: 0 auto 2mm; width: 180mm; height: 83mm; flex-shrink: 0; }
.pd-diagram text { font-family: var(--body); }
.pd-joins { border-collapse: collapse; margin-top: 3mm; font-size: .9em; }
.pd-joins th, .pd-joins td { border: .25mm solid #ccc; padding: 1.2mm 2mm; text-align: left; vertical-align: top; }
.pd-joins th:first-child { width: 14mm; }
.pd-joins th { background: #fff4ec; }
/* подвал: подпись одной строкой (ужимается в app.js) */
.sheet:has(.pd-area) .sheet-foot, .sheet:has(.pd-col) .sheet-foot { gap: 4mm; }
.sheet:has(.pd-area) .sheet-foot span, .sheet:has(.pd-col) .sheet-foot span { white-space: nowrap; }
.sheet:has(.pd-area) .sheet-foot span:last-child, .sheet:has(.pd-col) .sheet-foot span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
