/* ───────── offertes en facturen ───────── */
.sheet > .figs:first-child { padding-top: 16px; }
.startnr { display: grid; grid-template-columns: 1fr 220px auto; gap: 12px 16px; align-items: end; padding-top: 16px; }
.startnr h2 { margin-bottom: 2px; }
.startnr .form-err { grid-column: 1 / -1; }
.doc-detail { display: grid; grid-template-columns: minmax(260px, 340px) minmax(0, 1fr); gap: 24px; align-items: start; }
.doc-side { display: grid; gap: 16px; position: sticky; top: 16px; }
.doc-side .sheet + .sheet { margin-top: 0; }
.doc-detail .docs, .ed-preview .docs { background: var(--surface-2); border: 1px solid var(--line); padding: 16px; min-height: 240px; }
.bedrag { display: grid; gap: 2px; padding-top: 16px; }
.bedrag b { font-family: var(--head); font-weight: 700; font-size: 28px; letter-spacing: -0.6px; line-height: 1.15; }
.stapel { display: grid; gap: 10px; justify-items: start; }
.stapel > .btn, .stapel > form, .stapel > .field, .stapel > .row { width: 100%; }
.stapel > .row { padding: 10px 0; border-top: 1px solid var(--line-2); }
.stapel > .row:first-child { border-top: 0; }
.getekend { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; background: var(--ok-soft); color: var(--ok); width: 100%; }
.getekend b { color: var(--ink); }
.kopieer { display: flex; gap: 8px; }
.kopieer input { flex: 1; min-width: 0; }
.knoprij { display: flex; gap: 8px; flex-wrap: wrap; }
.ed-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.ed-form { min-width: 0; }
.ed-form .sheet + .sheet { margin-top: 18px; }
.ed-preview { position: sticky; top: 16px; max-height: calc(100vh - 32px); overflow: auto; }
.ed-toggle { display: none; }
.ed-acties { display: flex; justify-content: flex-end; align-items: center; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.ed-acties .form-err { margin-right: auto; }
.nk { border-left: 3px solid var(--chroma); padding-left: 12px; }

/* blokken in het kostenoverzicht */
.pst { border: 1px solid var(--line); padding: 12px; display: grid; gap: 10px; margin-bottom: 12px; background: var(--surface); }
.pst-top { display: flex; gap: 4px; align-items: center; }
.pst-titel { flex: 1; font-weight: 600; }
.pst-rij { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: end; }
.pst-veld { display: grid; gap: 4px; width: 90px; }
.pst-veld.prijs { width: 130px; }
.pst-veld span { font-family: var(--head); font-size: 12px; font-weight: 700; }
.pst-tot { margin-left: auto; font-size: 13px; color: var(--ink-2); white-space: nowrap; padding-bottom: 9px; }
.pst-tot b { color: var(--ink); font-size: 14.5px; }
.pst-modus { justify-self: start; max-width: 100%; overflow-x: auto; }
.rg-lijst { display: grid; gap: 8px; }
.rg { display: grid; grid-template-columns: 76px 84px 104px auto minmax(0, 1fr) 32px; gap: 6px 8px; align-items: end; padding: 8px; background: var(--surface-2); }
.rg-oms { grid-column: 1 / 4; }
.rg-toel { grid-column: 4 / -1; }
.rg input[type="text"] { padding-left: 8px; padding-right: 8px; height: 38px; }
.rg-veld { display: grid; gap: 3px; }
.rg-veld span { font-family: var(--head); font-size: 11.5px; font-weight: 700; color: var(--ink-2); }
.rg-num { text-align: right; }
.rg-nac { font-size: 12.5px; color: var(--ink-2); padding-bottom: 9px; }
.rg-tot { text-align: right; font-size: 13.5px; font-weight: 600; white-space: nowrap; padding-bottom: 9px; }
.rg > .btn { margin-bottom: 3px; }
.pst > .btn.sm { justify-self: start; }
.pst-voet { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding-top: 4px; }
.pst-voet b { font-family: var(--head); font-size: 18px; margin-left: 8px; }
.hand-huidig { display: flex; align-items: center; gap: 12px; min-height: 70px; padding: 8px 12px; border: 1px dashed var(--line); background: #fff; }
.hand-huidig img { max-height: 70px; max-width: 280px; }
.tekenvlak { display: block; width: 100%; height: 170px; background: #fff; border: 1px solid var(--line); border-bottom: 2px solid var(--ink); cursor: crosshair; margin: 8px 0; }

@media (max-width: 1180px) {
  .ed-grid { grid-template-columns: minmax(0, 1fr); }
  .ed-preview { display: none; position: static; max-height: none; }
  .ed-grid.toon .ed-preview { display: block; }
  .ed-toggle { display: inline-flex; }
}
@media (max-width: 960px) {
  .doc-detail { grid-template-columns: minmax(0, 1fr); }
  .doc-side { position: static; }
}
@media (max-width: 720px) {
  .startnr { grid-template-columns: 1fr; }
  .rg { grid-template-columns: 1fr 1fr 1fr; }
  .rg-oms, .rg-toel { grid-column: 1 / -1; }
  .rg-nac { grid-column: 1; }
  .rg-tot { grid-column: 2; }
  .doc-detail .docs, .ed-preview .docs { padding: 8px; }
}
