/* B/451 - the VIT DWF To converter (451-design-bezalel.md). Paper, ink lines, clay only on the action and the result. The crop frame (dashed rectangle + corner ticks) is the motif and the only dashed line.
   Radius 0, no gradients, no shadow. Controls are div[role=button]; every colour is a --vit-* token. */
.dwft { position: relative; min-height: 280px; padding: var(--vit-space-5); background: var(--vit-paper) !important; border: 1.5px dashed var(--vit-ink); border-radius: 0; color: var(--vit-ink); min-width: 0; max-width: 100%; font-family: var(--vit-f-heb), var(--vit-f-sans); }
.dwft-tag { position: absolute; inset-block-start: 10px; inset-inline-end: 12px; display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--vit-line-strong); border-radius: 50%; font: 500 10px/1 var(--vit-f-mono); letter-spacing: .04em; color: var(--vit-ink-3); background: var(--vit-paper); }
.dwft-tick { position: absolute; width: 10px; height: 10px; pointer-events: none; transition: transform .15s ease; }
.dwft-tick-a { inset-block-start: -5.5px; inset-inline-start: -5.5px; border-inline-start: 1.5px solid var(--vit-ink); border-block-start: 1.5px solid var(--vit-ink); }
.dwft-tick-b { inset-block-start: -5.5px; inset-inline-end: -5.5px; border-inline-end: 1.5px solid var(--vit-ink); border-block-start: 1.5px solid var(--vit-ink); }
.dwft-tick-c { inset-block-end: -5.5px; inset-inline-start: -5.5px; border-inline-start: 1.5px solid var(--vit-ink); border-block-end: 1.5px solid var(--vit-ink); }
.dwft-tick-d { inset-block-end: -5.5px; inset-inline-end: -5.5px; border-inline-end: 1.5px solid var(--vit-ink); border-block-end: 1.5px solid var(--vit-ink); }
.dwft[data-drag] { border: 1.5px solid var(--vit-clay-ink); background: color-mix(in srgb, var(--vit-clay) 6%, var(--vit-paper)) !important; }
.dwft[data-drag] .dwft-tick-a { transform: translate(4px, 4px); } .dwft[data-drag] .dwft-tick-b { transform: translate(-4px, 4px); }
.dwft[data-drag] .dwft-tick-c { transform: translate(4px, -4px); } .dwft[data-drag] .dwft-tick-d { transform: translate(-4px, -4px); }
@media (prefers-reduced-motion: reduce) { .dwft-tick { transition: none; } .dwft[data-drag] .dwft-tick { transform: none; } }
.dwft-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.dwft-nojs { margin: 0; color: var(--vit-ink-2); }
.dwft-state[hidden] { display: none !important; }
.dwft-state[data-state="empty"], .dwft-state[data-state="loading"], .dwft-state[data-state="error"], .dwft-state[data-state="done"], .dwft-state[data-state="working"] { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--vit-space-3); min-height: 230px; text-align: center; }
.dwft-glyph { color: var(--vit-ink); }
.dwft-main { margin: 0; font-size: var(--vit-web-h2, 22px); font-weight: 600; line-height: 1.35; }
.dwft-note { margin: 0; font-size: 12px; color: var(--vit-ink-3); line-height: 1.5; }
.dwft-note bdi[dir="ltr"], .dwft-sheet-size { font-family: var(--vit-f-mono); }
.dwft-heb { font-family: var(--vit-f-heb), var(--vit-f-sans); }   /* the Hebrew word inside the mono size line stays in Heebo (Betzalel's nit) */
.dwft-file bdi { font-family: var(--vit-f-heb), var(--vit-f-sans); }
.dwft-btn { display: inline-block; min-height: 44px; padding: 10px 22px; border: 1.5px solid var(--vit-clay); border-radius: 0; font-weight: 600; font-size: 16px; line-height: 1.4; cursor: pointer; user-select: none; text-align: center; }
.dwft-btn-line { color: var(--vit-ink); background: transparent; }
.dwft-btn-fill { background: var(--vit-clay); color: var(--vit-on-clay); }
.dwft-btn[aria-disabled="true"] { opacity: 1; background: transparent; color: var(--vit-ink-3); border: 1px dashed var(--vit-line-strong); cursor: not-allowed; }
.dwft-btn:focus-visible, .dwft-link:focus-visible, .dwft-chip:focus-visible, .dwft-opt:focus-visible, .dwft-check input:focus-visible, .dwft-input:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 2px; }
.dwft-err:focus { outline: none; }
.dwft-link { display: inline-block; padding: 4px 0; color: var(--vit-clay-text, var(--vit-clay-strong)); cursor: pointer; font-size: 14px; text-decoration: underline; text-underline-offset: 3px; }
.dwft-links { display: flex; flex-wrap: wrap; gap: var(--vit-space-4); justify-content: center; }
/* scale-bar progress: a 1px ink line with ticks every 10%, filled in clay */
.dwft-scale { position: relative; width: min(420px, 100%); height: 1px; background: var(--vit-ink); margin-block: var(--vit-space-3); background-image: repeating-linear-gradient(to right, var(--vit-ink) 0 1px, transparent 1px 10%); }
.dwft-scale::before { content: ""; position: absolute; inset-inline: 0; inset-block-start: -4px; height: 9px; background: repeating-linear-gradient(to right, var(--vit-ink) 0 1px, transparent 1px calc(10% - 1px)); opacity: .5; }
.dwft-scale > i { position: absolute; inset-block: -1px; inset-inline-start: 0; width: 0; height: 3px; background: var(--vit-clay); }
.dwft-scale[data-scale="indeterminate"] > i { width: 30%; animation: dwft-slide 1.4s ease-in-out infinite alternate; }
@keyframes dwft-slide { from { inset-inline-start: 0; } to { inset-inline-start: 70%; } }
@media (prefers-reduced-motion: reduce) { .dwft-scale[data-scale="indeterminate"] > i { animation: none; inset-inline-start: 35%; } }
/* state 3 */
.dwft-linkrow { display: flex; flex-wrap: wrap; gap: 4px var(--vit-space-4); }
.dwft-h { display: block; margin: 0 0 var(--vit-space-2); font-size: 16px; font-weight: 600; }
.dwft-h2 { margin: var(--vit-space-3) 0 var(--vit-space-1); font-size: 14px; font-weight: 600; color: var(--vit-ink-2); }
.dwft-file { margin: 0; min-width: 0; overflow-wrap: break-word; font-size: 14px; }
.dwft-sheets { max-height: 240px; overflow: auto; margin-block: var(--vit-space-2); border-block: 1px solid var(--vit-line-default); }
.dwft-sheet { display: flex; align-items: center; gap: var(--vit-space-2); padding: 6px 0; border-block-end: 1px solid var(--vit-line-faint); font-size: 14px; }
.dwft-sheet:last-child { border-block-end: 0; }
.dwft-sheet input { width: 18px; height: 18px; accent-color: var(--vit-ink); flex: none; }
.dwft-sheet-name { flex: 1; min-width: 0; overflow-wrap: break-word; }
.dwft-sheet-size { font-size: 11px; color: var(--vit-ink-3); white-space: nowrap; }
.dwft-sheets-compact .dwft-sheet { color: var(--vit-ink-3); }
.dwft-sheets-compact { width: min(420px, 100%); text-align: start; }
.dwft-sheets-compact .dwft-sheet::before { content: ""; width: 1.2em; flex: none; text-align: center; }
.dwft-sheets-compact .dwft-sheet[data-done] { color: var(--vit-ink); } .dwft-sheets-compact .dwft-sheet[data-done]::before { content: "✓"; }
.dwft-sheets-compact .dwft-sheet[data-current] { color: var(--vit-ink); font-weight: 600; } .dwft-sheets-compact .dwft-sheet[data-current]::before { content: "●"; color: var(--vit-clay); }
.dwft-out { display: grid; gap: var(--vit-space-2); margin-block-end: var(--vit-space-3); }
.dwft-opt { display: grid; grid-template-columns: 20px minmax(0, 1fr); column-gap: 10px; row-gap: 2px; align-items: center; padding: 10px 12px; border: 1px solid var(--vit-line-default); border-radius: 0; cursor: pointer; background: var(--vit-paper); }
.dwft-opt .dwft-oi { grid-row: 1 / span 2; color: var(--vit-ink); }
.dwft-opt b { font-size: 15px; font-weight: 600; grid-column: 2; } .dwft-opt span { font-size: 12px; color: var(--vit-ink-3); grid-column: 2; }
.dwft-opt[aria-checked="true"] { border: 1.5px solid var(--vit-clay); } .dwft-opt[aria-checked="true"] b { color: var(--vit-ink); }
.dwft-opt[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.dwft-checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 4px var(--vit-space-3); }
.dwft-check { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.dwft-check input { accent-color: var(--vit-ink); }
.dwft-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-block: var(--vit-space-1); }
.dwft-chip { padding: 4px 12px; border: 1px solid var(--vit-line-default); border-radius: var(--vit-r-pill, 999px); font-size: 13px; color: var(--vit-ink-2); cursor: pointer; }
.dwft-chip[data-on="1"] { border-color: var(--vit-clay); color: var(--vit-clay-text, var(--vit-clay-strong)); }
.dwft-chip[data-on="1"] { background: color-mix(in srgb, var(--vit-clay) 12%, var(--vit-paper)); }
.dwft-chip[data-on="0"]::before { content: "+ "; }
.dwft-chip[data-on="1"]::after { content: " ✕"; font-size: 11px; }
.dwft-input { width: 100%; max-width: 260px; padding: 6px 8px; border: 1px solid var(--vit-line-strong); border-radius: 0; background: var(--vit-paper); font: inherit; color: var(--vit-ink); }
.dwft-head { display: flex; margin-block: var(--vit-space-3); max-width: 100%; overflow-x: auto; border: 1px solid var(--vit-line-default); }
.dwft-head span { flex: none; padding: 5px 10px; border-inline-end: 1px solid var(--vit-line-default); font-size: 12px; white-space: nowrap; background: var(--vit-paper-2); }
.dwft-head span[data-wf] { background: color-mix(in srgb, var(--vit-clay) 12%, var(--vit-paper)); color: var(--vit-clay-text, var(--vit-clay-strong)); }
[data-convert] { margin-block-start: var(--vit-space-3); }
/* states 5 and 6 */
.dwft-ok { color: var(--vit-ink); font-weight: 700; } .dwft-sum { font-size: 14px; font-weight: 400; color: var(--vit-ink-2); }
.dwft-files { display: grid; gap: var(--vit-space-2); justify-items: center; }
.dwft-file-row { display: flex; flex-wrap: wrap; gap: var(--vit-space-3); align-items: center; justify-content: center; font-size: 14px; }
.dwft-err { display: flex; align-items: center; gap: var(--vit-space-2); margin: 0; font-size: 18px; font-weight: 500; }
.dwft-bang { display: inline-grid; place-items: center; width: 24px; height: 24px; border: 1.5px solid var(--vit-ink); border-radius: 50%; font-size: 13px; font-weight: 700; flex: none; }
@media (max-width: 720px) {
  .dwft { min-height: 240px; padding: var(--vit-space-4); }
  .dwft-tag { inset-block-start: 8px; inset-inline-end: 8px; width: 34px; height: 34px; }
}
/* the page around the zone */
.dwf-hero { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: var(--vit-space-6); align-items: start; }
.dwf-hero .lead { margin-block-start: var(--vit-space-3); }
@media (max-width: 900px) { .dwf-hero { grid-template-columns: 1fr; } }
.dwf-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--vit-space-4); }
@media (max-width: 720px) { .dwf-cards { grid-template-columns: 1fr; } }
.dwf-card { padding: var(--vit-space-4); background: var(--vit-paper-2); border: 1px solid var(--vit-line-default); border-radius: var(--vit-r-sm); }
.dwf-card h3 { margin: 0 0 var(--vit-space-2); font-size: 18px; } .dwf-card p { margin: 0; color: var(--vit-ink-2); font-size: 14px; }
.dwf-card svg { color: var(--vit-ink); margin-block-end: var(--vit-space-2); }
.dwf-export { margin: var(--vit-space-5) 0 0; }
.dwf-export-lead { margin: 0 0 var(--vit-space-3); font-family: var(--vit-f-heb), var(--vit-f-sans); font-weight: 600; font-size: 18px; }
.dwf-export-pair { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1.15fr); gap: var(--vit-space-3); align-items: center; }
.dwf-export-plan { width: 100%; height: auto; border: 1px solid var(--vit-ink); background: var(--vit-paper); display: block; }
.dwf-export-xl { width: 100%; height: auto; display: block; border: 1px solid var(--vit-line-default); }
.dwf-export-xlcol { min-width: 0; }
.dwf-export-xlbox { overflow-x: auto; direction: rtl; }   /* the screenshot is an RTL Excel: open on column A in both languages */
.dwf-export-xlbox:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 2px; }
.dwf-export-hint { display: none; margin: 4px 0 0; font-size: 12px; color: var(--vit-ink-3); }
.dwf-export-arrow { display: flex; flex-direction: column; align-items: center; gap: 4px; font-family: var(--vit-f-heb), var(--vit-f-sans); font-size: 14px; font-weight: 600; }
:lang(en) .dwf-export-arrow svg { transform: scaleX(-1); }
.dwf-export figcaption { margin-block-start: var(--vit-space-3); font-size: 13px; color: var(--vit-ink-3); }
@media (max-width: 720px) { .dwf-export-pair { grid-template-columns: 1fr; } .dwf-export-arrow { flex-direction: row; justify-content: center; } .dwf-export-arrow svg { transform: rotate(-90deg); } :lang(en) .dwf-export-arrow svg { transform: rotate(-90deg); } }
.dwf-desktop { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: var(--vit-space-6); align-items: center; }
@media (max-width: 900px) { .dwf-desktop { grid-template-columns: 1fr; } }
.dwf-detail { position: relative; border: 1px solid var(--vit-ink); background: var(--vit-paper); }
.dwf-detail img { display: block; width: 100%; height: auto; }
.dwf-detail figcaption { display: flex; gap: var(--vit-space-2); align-items: center; padding: 8px 12px; border-block-start: 1px solid var(--vit-ink); font-size: 13px; }
.dwf-detail .dwf-dtag { display: inline-grid; place-items: center; width: 22px; height: 22px; border: 1px solid var(--vit-ink); border-radius: 50%; font: 500 11px/1 var(--vit-f-mono); }
.dwf-points { list-style: none; margin: var(--vit-space-3) 0; padding: 0; display: grid; gap: var(--vit-space-2); }
.dwf-points li { display: flex; gap: var(--vit-space-2); align-items: center; }
.dwf-points li::before { content: ""; width: 10px; height: 10px; border: 1.5px solid var(--vit-clay); flex: none; }
.dwf-price { font-size: 14px; color: var(--vit-ink-2); }
.dwf-notices { max-width: var(--vit-w-narrow, 720px); margin: 24px auto; padding-inline: 16px; font-size: 14px; } .dwf-notices a { color: var(--vit-ink); text-underline-offset: 3px; }

/* shrink section (451-design-bezalel-r2.md 12-14): ink outline button, one clay (download) in the result, before/after bars with ONE solid ink tick at the 40 MB target */
.dwft-shrink { margin-block: var(--vit-space-4) var(--vit-space-3); padding-block-start: var(--vit-space-3); border-block-start: 1px solid var(--vit-line-default); }
.dwft-shrink .dwft-h2 { margin-block-start: 0; }
.dwft-shrink .dwft-note { margin-block-end: var(--vit-space-2); }
.dwft-shrink .dwft-btn { margin-block-start: var(--vit-space-1); }
.dwft-mono { font-family: var(--vit-f-mono); }
.dwft-over { display: inline-block; margin-block-start: var(--vit-space-1); padding: 2px 8px; border: 1.5px solid var(--vit-ink); font: 600 12px/1.4 var(--vit-f-heb), var(--vit-f-sans); color: var(--vit-ink); cursor: pointer; }
.dwft-over:focus-visible, .dwft-shrink .dwft-link:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 2px; }
.dwft-sbars { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; grid-template-rows: 14px 14px; gap: var(--vit-space-2); align-items: center; margin-block: 30px var(--vit-space-3); font-size: 13px; position: relative; }
.dwft-c1 { grid-column: 1; } .dwft-c2 { grid-column: 2; } .dwft-c3 { grid-column: 3; } .dwft-r1 { grid-row: 1; } .dwft-r2 { grid-row: 2; }
.dwft-sbar-lbl { color: var(--vit-ink-2); line-height: 14px; }
.dwft-sbar { position: relative; height: 14px; background: var(--vit-paper-2); border: 1px solid var(--vit-line-default); box-sizing: border-box; }
.dwft-sbar > i { position: absolute; inset-block: 0; inset-inline-start: 0; width: 0; }
.dwft-sbar-before > i { background: color-mix(in srgb, var(--vit-ink) 38%, var(--vit-paper)); } .dwft-sbar-after > i { background: var(--vit-ink); }
.dwft-sbars .dwft-mono { font-size: 12px; white-space: nowrap; line-height: 14px; }
/* ONE solid ink tick across both bars: an overlay in the bar column (rows 1-2), its offset is the target as a share of the bar scale */
.dwft-stick-wrap { grid-column: 2; grid-row: 1 / span 2; align-self: stretch; position: relative; pointer-events: none; }
.dwft-stick { position: absolute; inset-block: -6px; inset-inline-start: 0; width: 2px; margin-inline-start: -1px; background: var(--vit-ink); border-inline: 1px solid var(--vit-paper); box-sizing: content-box; }
.dwft-stick-lbl { position: absolute; inset-block-start: -16px; inset-inline-start: 0; transform: translateX(-50%); font: 500 11px/1 var(--vit-f-sans); color: var(--vit-ink); white-space: nowrap; }
.dwft-stick-lbl:dir(rtl) { transform: translateX(50%); }
.dwft-verdict { display: flex; align-items: center; gap: var(--vit-space-2); margin: 0 0 var(--vit-space-2); font-size: 15px; font-weight: 600; }
.dwft-shrink-err { font-size: 14px; margin-block-start: var(--vit-space-2); }
.dwft-shrink-result .dwft-file-row { justify-content: flex-start; margin-block-end: var(--vit-space-2); }
.dwft [hidden]{display:none!important}

/* PDF booklet (B/522): the layout toggle and the page-order grid; present only in a build with PUBLIC_DWF_BOOKLET=1 */
.dwft-booklet { margin-block-end: var(--vit-space-3); }
.dwft-mode { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--vit-space-2); margin-block-end: var(--vit-space-2); }
.dwft-mode-opt { grid-template-columns: minmax(0, 1fr); text-align: start; }
.dwft-mode-opt b { grid-column: 1; font-family: var(--vit-f-heb), var(--vit-f-sans); font-size: 13px; }
.dwft-bgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: var(--vit-space-2); max-height: 340px; overflow-y: auto; padding-block-end: 2px; }
.dwft-bcard { position: relative; display: grid; gap: 4px; padding: 6px; border: 1px solid var(--vit-line-default); background: var(--vit-paper); cursor: grab; touch-action: manipulation; }
.dwft-bcard[data-drag] { opacity: .45; }
.dwft-bcard:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 2px; }
.dwft-bthumb { aspect-ratio: 4 / 3; background: var(--vit-paper-2, var(--vit-paper)); border: 1px solid var(--vit-line-default); display: grid; place-items: center; overflow: hidden; }
.dwft-bthumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.dwft-bnum { position: absolute; inset-block-start: 6px; inset-inline-start: 6px; min-width: 20px; padding: 0 5px; background: var(--vit-ink); color: var(--vit-paper); font: 600 12px/20px var(--vit-f-mono, monospace); text-align: center; }
.dwft-bname { font-family: var(--vit-f-heb), var(--vit-f-sans); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dwft-barrows { display: flex; justify-content: space-between; }
.dwft-barrow { min-width: 32px; min-height: 28px; display: inline-grid; place-items: center; font-size: 15px; }
.dwft-barrow[aria-disabled="true"] { opacity: .3; cursor: default; }

/* crop to scale (B/524 r2a, 451-design-bezalel-r2.md section 4): in crop mode the zone is one column so the sheet gets the width. The crop rectangle is SOLID 1.5px clay with ink corner ticks
   and the outside washed with paper (B/574: the inline paywall was removed). */
.dwft-crop { margin-block: var(--vit-space-3); padding-block-start: var(--vit-space-3); border-block-start: 1px solid var(--vit-line-default); }
.dwft-crop .dwft-h2:first-child { margin-block-start: 0; }
.dwft-fields { display: flex; flex-wrap: wrap; gap: var(--vit-space-2) var(--vit-space-4); margin-block: var(--vit-space-2); }
.dwft-field { display: grid; gap: 4px; font-size: 13px; color: var(--vit-ink-2); min-width: 0; }
.dwft-select { min-height: 36px; padding: 4px 8px; border: 1px solid var(--vit-line-strong); border-radius: 0; background: var(--vit-paper); color: var(--vit-ink); font: inherit; font-size: 14px; max-width: 100%; }
.dwft-ratio { display: inline-flex; align-items: center; gap: 4px; }
.dwft-ratio bdi { font-family: var(--vit-f-mono); font-size: 13px; }
.dwft-num { width: 88px; font-family: var(--vit-f-mono); }
.dwft-select:focus-visible, .dwft-view:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 2px; }
.dwft-fmt { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.dwft-fmt .dwft-opt { grid-template-columns: minmax(0, 1fr); }
.dwft-fmt .dwft-opt b, .dwft-fmt .dwft-opt span { grid-column: 1; }
.dwft-cropsum { color: var(--vit-ink-2); font-size: 13px; }
.dwft-crop [data-crop-run] { margin-block: var(--vit-space-2) var(--vit-space-1); }
.dwft-soon { display: inline-block; padding: 1px 8px; border: 1px solid var(--vit-ink); font: 600 12px/1.5 var(--vit-f-heb), var(--vit-f-sans); color: var(--vit-ink); }
.dwft-link[aria-disabled="true"] { color: var(--vit-ink-3); cursor: not-allowed; text-decoration: none; }
@media (max-width: 720px) { .dwft-fmt { grid-template-columns: minmax(0, 1fr); } }

/* ===== B/558: the full-width tool after a file is loaded (design: Bezalel's B/555 board, dwf-full-mock.html). Left: file, sheet rows with a thumbnail, three sections (convert, crop, export comments), one action bar.
   Right: the big sheet with pan, zoom, minimap and the crop rectangle. Paper, ink lines, clay only on the action and on state; radius 0; controls are div[role=button]. ===== */
.dwft[data-wide] { width: 100vw; max-width: 100vw; margin-inline: calc(50% - 50vw); padding: 0; border: 0; border-block: 1.5px solid var(--vit-ink); border-radius: 0; min-height: 0; }
.dwft[data-wide] .dwft-tag, .dwft[data-wide] .dwft-tick { display: none; }
html:has(.dwft[data-wide]) { overflow-x: clip; }
.dwf-hero:has(.dwft[data-wide]) { grid-template-columns: minmax(0, 1fr); gap: var(--vit-space-3); }
.dwf-hero:has(.dwft[data-wide]) > div:first-child { display: flex; align-items: baseline; gap: var(--vit-space-4); flex-wrap: wrap; }
#hero .dwf-hero:has(.dwft[data-wide]) h1 { margin: 0; font-size: 20px; line-height: 1.3; }
.dwf-hero:has(.dwft[data-wide]) .lead { margin: 0; font-size: 13px; flex: 1; min-width: 0; }
.dwft[data-wide] [data-state="working"], .dwft[data-wide] [data-state="done"] { padding: var(--vit-space-5); }
.dwft-app { display: grid; grid-template-columns: 380px minmax(0, 1fr); height: clamp(560px, calc(100dvh - 150px), 940px); text-align: start; }
.dwft-side { border-inline-end: 1px solid var(--vit-line-default); display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.dwft-side-scroll { overflow: auto; padding: 14px 16px; flex: 1; min-height: 0; }
.dwft-filebar { margin-block-end: var(--vit-space-3); }
.dwft-filebar .dwft-file { font-weight: 600; }
.dwft-h-row { display: flex; justify-content: space-between; align-items: baseline; gap: var(--vit-space-3); margin: 0 0 6px; font-size: 13px; }
.dwft-h-row .dwft-linkrow { gap: 4px var(--vit-space-3); }
.dwft-h-row .dwft-link { font-size: 12px; font-weight: 400; }
.dwft-go { border-block-start: 1px solid var(--vit-line-default); padding: 12px 16px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.dwft-go .dwft-btn { min-height: 40px; padding: 8px 26px; font-size: 15px; }
.dwft-go .dwft-note { min-width: 0; }   /* no overflow-wrap:anywhere: banned on UI text by the layout sweep; the note is spaced words */
.dwft-app .dwft-sheets { max-height: none; overflow: visible; margin: 0; border-block: 1px solid var(--vit-line-default); }
.dwft-app .dwft-sheet { display: grid; grid-template-columns: 18px minmax(0, 1fr); column-gap: 10px; align-items: center; padding: 8px 10px; position: relative; border-block-end: 1px solid var(--vit-line-faint); font-size: 14px; }
.dwft-app .dwft-sheet:last-child { border-block-end: 0; }
.dwft-app .dwft-sheet[data-current] { background: var(--vit-paper-2); }
.dwft-show { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 10px; align-items: center; min-width: 0; cursor: pointer; }
.dwft-show:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 2px; }
.dwft-th { display: block; height: 40px; aspect-ratio: var(--ar, 1.4); border: 1px solid var(--vit-line-default); background: color-mix(in srgb, var(--vit-paper-2) 60%, var(--vit-paper)); line-height: 0; overflow: hidden; }
.dwft-th img { display: block; width: 100%; height: 100%; object-fit: contain; }
.dwft-th:not([data-loaded])::after { content: ""; display: block; height: 100%; background: linear-gradient(100deg, transparent 30%, color-mix(in srgb, var(--vit-ink) 6%, transparent) 50%, transparent 70%); background-size: 200% 100%; animation: dwft-sh 1.6s linear infinite; }
@keyframes dwft-sh { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .dwft-th:not([data-loaded])::after { animation: none; } }
.dwft-tx { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.dwft-app .dwft-sheet-name { overflow-wrap: break-word; line-height: 1.3; }
.dwft-app .dwft-sheet-size { font-size: 11px; }
/* a sheet wider than 3:1: the thumbnail takes its own line under the name, the same 40px height, the aspect kept */
.dwft-wide .dwft-show { grid-template-columns: minmax(0, 1fr); grid-template-areas: "tx" "th"; row-gap: 6px; }
.dwft-wide .dwft-tx { grid-area: tx; } .dwft-wide .dwft-th { grid-area: th; width: min(100%, calc(40px * var(--ar, 4))); height: auto; max-height: 40px; }
/* the checkbox (option B, Bezalel B/555): a 1.5px ink square, a thick clay tick, a focus ring of 1.5px clay at 2px */
.dwft-cb { appearance: none; -webkit-appearance: none; width: 18px; height: 18px; margin: 0; border: 1.5px solid var(--vit-ink); border-radius: 0; background: var(--vit-paper) center / 16px 16px no-repeat; cursor: pointer; flex: none; }
.dwft-cb { position: relative; }
.dwft-cb:checked::before { content: ""; position: absolute; inset: 0; background-color: var(--vit-clay-ink); -webkit-mask: var(--dwft-tick) center / 14px 14px no-repeat; mask: var(--dwft-tick) center / 14px 14px no-repeat; }
.dwft { --dwft-tick: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M2.2 7.2l3.2 3.2 6.4-7' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='square'/%3E%3C/svg%3E"); }
.dwft-cb:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 2px; }
.dwft[data-mode="xlsx"] .dwft-cb, .dwft[data-mode="crop"] .dwft-cb { opacity: .5; }
/* the three sections */
.dwft-secs { margin-block-start: 16px; border-block-start: 1.5px solid var(--vit-ink); }
.dwft-sec { border-block-end: 1px solid var(--vit-line-default); }
.dwft-sec-h { display: flex; align-items: center; gap: 10px; padding: 11px 4px; cursor: pointer; user-select: none; }
.dwft-sec-i { flex: none; color: var(--vit-ink); }
.dwft-sec-t { display: flex; flex-direction: column; min-width: 0; }
.dwft-sec-t b { font-size: 15px; font-weight: 600; }
.dwft-sec-t > span { font-size: 12px; color: var(--vit-ink-3); }
.dwft-opt-tag { font-size: 12px; font-weight: 400; color: var(--vit-ink-3); }
.dwft-chev { margin-inline-start: auto; flex: none; transition: transform .15s; }
.dwft-sec[data-open] .dwft-chev { transform: rotate(180deg); }
.dwft-sec[data-open] .dwft-sec-h { border-inline-start: 3px solid var(--vit-clay); padding-inline-start: 8px; }
.dwft-sec-b { padding: 2px 4px 14px; }
.dwft-sec:not([data-open]) .dwft-sec-b { display: none; }
.dwft-sec-h:focus-visible, .dwft-tb:focus-visible, .dwft-x:focus-visible, .dwft-pl-x:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .dwft-chev { transition: none; } }
.dwft-app .dwft-out { margin-block: 6px 10px; }
.dwft-app .dwft-opt { padding: 7px 10px; }
.dwft-app .dwft-crop { margin: 0; padding-block-start: 0; border: 0; }
.dwft-app .dwft-shrink { margin-block: var(--vit-space-3) 0; }
.dwft-app .dwft-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; margin-block: 10px; }
.dwft-draw { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-block: 6px; }
/* the stage */
.dwft-stage { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.dwft-tools { display: flex; align-items: center; gap: 6px; padding: 8px 12px; border-block-end: 1px solid var(--vit-line-default); font-size: 13px; flex-wrap: wrap; }
.dwft-cur-nm { font-weight: 600; margin-inline-end: 4px; }
.dwft-cur-sz { font-family: var(--vit-f-mono); font-size: 11px; color: var(--vit-ink-3); }
.dwft-sp { flex: 1; }
.dwft-tb { min-width: 34px; height: 34px; border: 1px solid var(--vit-line-strong); display: inline-flex; align-items: center; justify-content: center; padding-inline: 7px; cursor: pointer; background: var(--vit-paper); user-select: none; gap: 6px; font-size: 13px; color: var(--vit-ink); }
.dwft-tb[aria-pressed="true"] { border: 1.5px solid var(--vit-clay-ink); background: color-mix(in srgb, var(--vit-clay) 10%, var(--vit-paper)); }
.dwft-tb[aria-disabled="true"] { opacity: .45; cursor: default; }
.dwft-pct { font-family: var(--vit-f-mono); font-size: 12px; min-width: 48px; text-align: center; }
.dwft-view { position: relative; flex: 1; min-height: 0; overflow: hidden; background: var(--vit-paper-3); touch-action: none; cursor: grab; user-select: none; }
.dwft-view[data-grab] { cursor: grabbing; }
.dwft-view[data-draw] { cursor: crosshair; }
.dwft-world { position: absolute; left: 0; top: 0; transform-origin: 0 0; outline: 1px solid var(--vit-ink); background: var(--vit-paper); }
.dwft-cropimg { display: block; pointer-events: none; max-width: none; }
.dwft-view-load { position: absolute; inset: 0; display: grid; place-items: center; margin: 0; font-size: 14px; color: var(--vit-ink-2); pointer-events: none; }
.dwft-view-load[hidden] { display: none; }
.dwft-cropbox { position: absolute; box-sizing: border-box; border: 1.5px solid var(--vit-clay-ink); background: color-mix(in srgb, var(--vit-clay) 8%, transparent); cursor: move; touch-action: none; }
.dwft-ctk { position: absolute; width: 14px; height: 14px; touch-action: none; }
.dwft-ctk::before { content: ""; position: absolute; width: 10px; height: 10px; border: 0 solid var(--vit-clay-ink); }
.dwft-ctk-a { inset-block-start: -7px; inset-inline-start: -7px; cursor: nwse-resize; } .dwft-ctk-a::before { inset-block-start: 1px; inset-inline-start: 1px; border-block-start-width: 2px; border-inline-start-width: 2px; }
.dwft-ctk-b { inset-block-start: -7px; inset-inline-end: -7px; cursor: nesw-resize; } .dwft-ctk-b::before { inset-block-start: 1px; inset-inline-end: 1px; border-block-start-width: 2px; border-inline-end-width: 2px; }
.dwft-ctk-c { inset-block-end: -7px; inset-inline-start: -7px; cursor: nesw-resize; } .dwft-ctk-c::before { inset-block-end: 1px; inset-inline-start: 1px; border-block-end-width: 2px; border-inline-start-width: 2px; }
.dwft-ctk-d { inset-block-end: -7px; inset-inline-end: -7px; cursor: nwse-resize; } .dwft-ctk-d::before { inset-block-end: 1px; inset-inline-end: 1px; border-block-end-width: 2px; border-inline-end-width: 2px; }
.dwft-cropbox[data-locked] .dwft-ctk { pointer-events: none; }
.dwft-croplbl { position: absolute; bottom: 100%; left: 0; margin-block-end: 6px; padding: 1px 6px; border: 1px solid var(--vit-clay-ink); background: var(--vit-paper); font: 500 11px/1.5 var(--vit-f-mono); color: var(--vit-ink); white-space: nowrap; pointer-events: none; }
.dwft-x { position: absolute; bottom: 100%; right: 0; margin-block-end: 4px; width: 28px; height: 28px; display: grid; place-items: center; background: var(--vit-paper); border: 1.5px solid var(--vit-clay-ink); cursor: pointer; color: var(--vit-ink); }
.dwft-mini { position: absolute; bottom: 12px; left: 12px; background: var(--vit-paper); border: 1px solid var(--vit-ink); padding: 4px; line-height: 0; cursor: pointer; }
.dwft-mini img { width: 180px; height: auto; display: block; max-height: 120px; object-fit: contain; }
.dwft-vp { position: absolute; border: 1.5px solid var(--vit-clay-ink); background: color-mix(in srgb, var(--vit-clay) 12%, transparent); pointer-events: none; }
.dwft-hint { position: absolute; bottom: 12px; right: 12px; font-size: 12px; color: var(--vit-ink-2); background: var(--vit-paper); border: 1px solid var(--vit-line-default); padding: 3px 8px; pointer-events: none; }
.dwft-hint-m { display: none; }
/* the plans window (flag PUBLIC_DWF_PLANS=1) */
.dwft-plans { border: 1.5px solid var(--vit-ink); border-radius: 0; padding: 0; background: var(--vit-paper); color: var(--vit-ink); width: min(1040px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow: auto; font-family: var(--vit-f-heb), var(--vit-f-sans); }
.dwft-plans::backdrop { background: color-mix(in srgb, var(--vit-ink) 45%, transparent); }
.dwft-tsd { width: min(420px, calc(100vw - 32px)); }
.dwft-ts { padding: 0 20px 20px; min-height: 65px; }
.dwft-pl-h { display: flex; align-items: flex-start; gap: 12px; padding: 18px 20px 6px; }
.dwft-pl-h h2 { font-size: 21px; font-weight: 600; margin: 0; flex: 1; line-height: 1.3; }
.dwft-pl-x { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--vit-line-strong); cursor: pointer; flex: none; }
.dwft-pl-lead { padding: 0 20px; margin: 0 0 14px; color: var(--vit-ink-2); font-size: 14px; text-wrap: balance; }
.dwft-pl-cards { padding: 0 20px 20px; }
@media (max-width: 420px) { .dwft-pl-h { padding-inline: 14px; } .dwft-pl-lead { padding-inline: 14px; } .dwft-pl-cards { padding: 0 14px 14px; } }
@media (max-width: 720px) {
  .dwft[data-wide] [data-state="working"], .dwft[data-wide] [data-state="done"] { padding: var(--vit-space-4); }
  .dwf-hero:has(.dwft[data-wide]) .lead { display: none; }
  .dwft-app { grid-template-columns: minmax(0, 1fr); height: auto; }
  .dwft-stage { order: -1; height: var(--stage-h, 62dvh); min-height: 300px; }
  .dwft-side { border-inline-end: 0; border-block-start: 1px solid var(--vit-line-default); }
  .dwft-side-scroll { overflow: visible; }
  .dwft-go { position: sticky; inset-block-end: 0; background: var(--vit-paper); z-index: 2; }
  .dwft-cur-sz, .dwft-cur-nm { display: none; }
  .dwft-mini { display: none; }
  .dwft-hint-d { display: none; } .dwft-hint-m { display: block; left: 12px; right: auto; bottom: 10px; }
}
/* gate fixes (Bezalel, design-gate 16.11) */
/* the Vitru bubble floats over the physical bottom-left corner, which is the sticky Convert button (en), the minimap (he) or the sheet rows (phone); while the tool shows a loaded file the launcher steps aside (gate blocker 1) */
html.dwf-wide .vitru-bubble .vb { display: none; }
/* disabled buttons in the plans window: the DS disabled look (ink-3 text, no fill, dashed border) */
@media (max-width: 767px) {
  .dwft-tb { min-width: 44px; height: 44px; }
  .dwft-x { width: 44px; height: 44px; }
  .dwft-hint-m { left: 12px; transform: none; }
  .dwf-hero:has(.dwft[data-wide]) { padding-block: var(--vit-space-3); }
  #hero:has(.dwft[data-wide]) { padding-block-start: var(--vit-space-3); }
}
/* phone: the Excel window keeps a readable size (about 10px text) and scrolls sideways inside its own box, starting at column A (gate 21.11) */
@media (max-width: 720px) { .dwf-export-xl { width: 900px; max-width: none; } .dwf-export-hint { display: block; } }

/* ── one tool per page (B/585, founder 21.11 "a tool per task"): data-tool on the root shows only that tool. The section headers go (the page title says what this is);
   the output choices are narrowed to the tool's own. Structure first; the visual pass follows Bezalel's spec. ── */
.dwft[data-tool] .dwft-sec:not([data-open]) { display: none; }
.dwft[data-tool] .dwft-sec-h { display: none; }
.dwft[data-tool] .dwft-secs { border-block-start: 0; }
.dwft[data-tool="pdf"] [data-out="jpg"], .dwft[data-tool="pdf"] [data-out="png"] { display: none; }
.dwft[data-tool="image"] [data-out="pdf"], .dwft[data-tool="image"] [data-booklet] { display: none; }
.dwft[data-tool="pdf"] .dwft-shrink, .dwft[data-tool="image"] .dwft-shrink { display: none; }
.dwft[data-tool="shrink"] .dwft-out, .dwft[data-tool="shrink"] [data-booklet], .dwft[data-tool="shrink"] [data-convert] { display: none; }
.dwft-next { margin-block-start: 16px; display: grid; gap: 8px; }

/* ── B/585 visual pass (Bezalel's spec, founder 21.11: L3 stacked logo, P3 full-tint tool cards in drawing-sheet boxes). Colours only through the --vit-tool-* tokens. ── */
.dwf-ic { display: inline-block; width: 32px; height: 32px; flex: none; background-color: var(--vit-tool-pdf); -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat; }
.dwf-ic[data-ic="pdf"] { --ic: url(/assets/icons/dwf-tools/pdf.svg); }
.dwf-ic[data-ic="image"] { --ic: url(/assets/icons/dwf-tools/image.svg); }
.dwf-ic[data-ic="excel"] { --ic: url(/assets/icons/dwf-tools/excel.svg); }
.dwf-ic[data-ic="crop"] { --ic: url(/assets/icons/dwf-tools/crop.svg); }
.dwf-ic[data-ic="shrink"] { --ic: url(/assets/icons/dwf-tools/shrink.svg); }
.dwf-logo { display: block; height: 112px; width: auto; max-width: 100%; flex: none; }
.dwf-hero-menu, .dwf-hero-tool { grid-template-columns: minmax(0, 1fr); gap: var(--vit-space-6); }
.dwf-brand { display: flex; align-items: center; gap: var(--vit-space-5); flex-wrap: wrap; }
.dwf-brand .lead { margin-block-start: var(--vit-space-2); }
.dwf-menu { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; }
.dwf-tool-card { --corner: var(--vit-ink); --tint: var(--vit-tool-pdf); position: relative; isolation: isolate; display: grid; grid-template-rows: auto auto 1fr auto; gap: 6px; align-content: start; min-height: 168px; padding: var(--vit-space-4) var(--vit-space-4) 0; background: color-mix(in srgb, var(--tint) 14%, var(--vit-paper)); border: 1px solid var(--vit-ink); border-radius: 0; color: var(--vit-ink); text-decoration: none; transition: background-color .2s ease; }
.dwf-tool-card[data-tool-card="image"], .dwf-strip[data-tint="image"] { --tint: var(--vit-tool-image); }
.dwf-tool-card[data-tool-card="excel"], .dwf-strip[data-tint="excel"] { --tint: var(--vit-tool-excel); }
.dwf-tool-card[data-tool-card="crop"], .dwf-strip[data-tint="crop"] { --tint: var(--vit-tool-crop); }
.dwf-tool-card[data-tool-card="shrink"], .dwf-strip[data-tint="shrink"] { --tint: var(--vit-tool-shrink); }
.dwf-tool-card::before, .dwf-strip::before { content: ""; position: absolute; inset: -6px; z-index: -1; pointer-events: none;
  background:
    linear-gradient(var(--corner), var(--corner)) 0 6px / 11px 1px no-repeat, linear-gradient(var(--corner), var(--corner)) 6px 0 / 1px 11px no-repeat,
    linear-gradient(var(--corner), var(--corner)) 100% 6px / 11px 1px no-repeat, linear-gradient(var(--corner), var(--corner)) calc(100% - 6px) 0 / 1px 11px no-repeat,
    linear-gradient(var(--corner), var(--corner)) 0 calc(100% - 6px) / 11px 1px no-repeat, linear-gradient(var(--corner), var(--corner)) 6px 100% / 1px 11px no-repeat,
    linear-gradient(var(--corner), var(--corner)) 100% calc(100% - 6px) / 11px 1px no-repeat, linear-gradient(var(--corner), var(--corner)) calc(100% - 6px) 100% / 1px 11px no-repeat; }
.dwf-tool-card b { font-size: 17px; font-weight: 600; font-family: var(--vit-f-heb); }
.dwf-tool-card .dwf-card-line { font-size: 14px; color: var(--vit-ink-2); }
.dwf-card-fmt { display: flex; justify-content: flex-end; margin-inline: calc(-1 * var(--vit-space-4)); padding: 6px var(--vit-space-4); border-top: 1px solid var(--vit-ink); font-family: var(--vit-f-mono); font-size: 12px; color: var(--vit-ink-2); }
.dwf-tool-card:hover { --corner: var(--vit-clay-ink); background: color-mix(in srgb, var(--tint) 22%, var(--vit-paper)); border-color: var(--vit-clay-ink); }
.dwf-tool-card:active { background: color-mix(in srgb, var(--tint) 28%, var(--vit-paper)); }
.dwf-tool-card:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 4px; }
.dwf-tool-card .dwf-ic, .dwf-strip .dwf-ic { background-color: var(--tint); }
.dwf-strip { --corner: var(--vit-ink); --tint: var(--vit-tool-pdf); position: relative; isolation: isolate; display: flex; align-items: center; gap: var(--vit-space-4); min-height: 72px; padding: var(--vit-space-3) var(--vit-space-4); background: color-mix(in srgb, var(--tint) 14%, var(--vit-paper)); border-block: 1px solid var(--vit-ink); }
.dwf-strip .dwf-logo { height: 64px; }
.dwf-strip-text { flex: 1 1 auto; min-width: 0; }
#hero .dwf-strip h1 { margin: 0; font-size: 28px; font-weight: 700; line-height: 1.2; letter-spacing: 0; }
#hero .dwf-strip .lead { margin: 2px 0 0; font-size: 15px; line-height: 1.35; }
.dwf-back { flex: none; color: var(--vit-ink); font-size: 14px; text-decoration: underline; text-underline-offset: 3px; min-height: 44px; display: inline-flex; align-items: center; }
@media (max-width: 1279px) { .dwf-menu { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 767px) {
  .dwf-logo { height: 80px; } .dwf-strip .dwf-logo { height: 52px; }
  .dwf-menu { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .dwf-tool-card { min-height: 144px; }
  .dwf-strip { flex-wrap: wrap; } #hero .dwf-strip h1 { font-size: 22px; } .dwf-strip .dwf-ic { display: none; }
}
@media (max-width: 479px) { .dwf-tool-card:last-child { grid-column: span 2; } }
@media (prefers-reduced-motion: reduce) { .dwf-tool-card { transition: none; } }

/* B/585 chips: a pill in the tool's ground, a frame mixed from the tool colour and ink; state-style, so the area keeps its single clay fill. */
.dwft-chip { --tint: var(--vit-tool-pdf); display: inline-flex; align-items: center; gap: var(--vit-space-2); min-height: 44px; padding: 0 var(--vit-space-4); border: 1px solid color-mix(in srgb, var(--tint) 60%, var(--vit-ink)); border-radius: 999px; background: color-mix(in srgb, var(--tint) 14%, var(--vit-paper)); color: var(--vit-ink); font-size: 14px; cursor: pointer; }
.dwft-chip[hidden] { display: none; }
.dwft-chip[data-tint="image"] { --tint: var(--vit-tool-image); } .dwft-chip[data-tint="excel"] { --tint: var(--vit-tool-excel); } .dwft-chip[data-tint="crop"] { --tint: var(--vit-tool-crop); } .dwft-chip[data-tint="shrink"] { --tint: var(--vit-tool-shrink); }
.dwft-chip .dwf-ic { width: 18px; height: 18px; background-color: var(--tint); }
.dwft-chip:hover { background: color-mix(in srgb, var(--tint) 22%, var(--vit-paper)); }
.dwft-chip:focus-visible { outline: 1.5px solid var(--vit-clay); outline-offset: 4px; }
.dwft-trust { margin: var(--vit-space-3) 0 0; font-size: 17px; color: var(--vit-ink); text-align: center; }   /* body text: the sweep wants ink at 17px or more */

.dwft-next-shrink { margin-block-start: var(--vit-space-4); }

/* B/585 §4-5: the selected option = the tool's ground + a 1.5px clay frame; the done screen's one big download */
.dwft[data-tool] .dwft-opt[aria-checked="true"] { background: color-mix(in srgb, var(--vit-tool-pdf) 14%, var(--vit-paper)); }
.dwft[data-tool="pdf"] .dwft-opt[aria-checked="true"], .dwft[data-tool="shrink"] .dwft-opt[aria-checked="true"] { background: color-mix(in srgb, var(--vit-tool-pdf) 14%, var(--vit-paper)); }
.dwft[data-tool="image"] .dwft-opt[aria-checked="true"] { background: color-mix(in srgb, var(--vit-tool-image) 14%, var(--vit-paper)); }
.dwft[data-tool="excel"] .dwft-opt[aria-checked="true"] { background: color-mix(in srgb, var(--vit-tool-excel) 14%, var(--vit-paper)); }
.dwft[data-tool="crop"] .dwft-opt[aria-checked="true"] { background: color-mix(in srgb, var(--vit-tool-crop) 14%, var(--vit-paper)); }
.dwft [data-download-all], .dwft [data-download].dwft-btn-fill { min-width: 240px; }

/* B/585 fixes 1-5 (gate on 43c957e) */
.dwft-go { flex-direction: column-reverse; align-items: stretch; gap: 8px; }
.dwft-go .dwft-btn { width: 100%; min-height: 44px; text-align: center; }
.dwft-go .dwft-note { text-align: center; }
.dwft[data-tool="shrink"] .dwft-go { display: none; }
.dwft-shrink [data-shrink-run] { width: 100%; min-height: 44px; text-align: center; margin-block-start: var(--vit-space-3); }
.dwft [data-shrink-download] { min-width: 240px; }
.dwft-more { display: flex; justify-content: space-between; align-items: center; min-height: 44px; border-block: 1px solid var(--vit-line-default); font-size: 15px; font-weight: 600; cursor: pointer; margin-block-start: var(--vit-space-3); }
.dwft-more:focus-visible { outline: 1.5px solid var(--vit-clay-ink); outline-offset: 2px; }
.dwft-more-pm { font-family: var(--vit-font-mono, monospace); font-weight: 400; direction: ltr; }
.dwft-more-body[hidden] { display: none; }
.dwft[data-tool="crop"] [data-tool="rect"] { display: none; }
.dwft-file-row [data-download].dwft-link { display: inline-flex; align-items: center; min-height: 44px; padding-inline: 12px; }
#hero .dwf-hero:has(.dwft[data-wide]) .dwf-strip h1 { font-size: 28px; line-height: 1.2; }
#hero .dwf-hero:has(.dwft[data-wide]) .dwf-strip .lead { font-size: 15px; flex: initial; }
@media (max-width: 767px) { #hero .dwf-hero:has(.dwft[data-wide]) .dwf-strip h1 { font-size: 22px; } }

/* B/585 booklet re-gate: 44px hit areas */
.dwft-mode-opt { min-height: 44px; }
.dwft-barrow { position: relative; }
.dwft-barrow::after { content: ""; position: absolute; inset: -8px; }

/* founder 21.11: the strip carries links to the other tools, the current one marked */
.dwf-strip-nav { flex: 0 0 100%; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 0 var(--vit-space-4); }   /* its own row under the title at every width: same strip height on every tool */
.dwf-strip { flex-wrap: wrap; }
.dwf-tl, .dwf-back { white-space: nowrap; }
.dwf-tl { color: var(--vit-ink); font-size: 14px; text-decoration: underline; text-underline-offset: 3px; height: 44px; line-height: 1.2; display: inline-flex; flex-direction: column; justify-content: center; }
.dwf-tl::after { content: attr(data-label); font-weight: 700; height: 0; overflow: hidden; visibility: hidden; pointer-events: none; }   /* reserves the bold width, so no tool changes the strip height */
.dwf-tl[aria-current="page"] { font-weight: 700; text-decoration: none; box-shadow: inset 0 -2px 0 var(--vit-clay-ink); }
.dwf-tl:focus-visible, .dwf-back:focus-visible { outline: 1.5px solid var(--vit-clay-ink); outline-offset: 2px; }


/* B-6 plans links: the two plan buttons are links to /account/dwf; same face as the buttons, a 44px target */
a.dwft-btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
a.dwft-btn-line:hover { background: var(--vit-ink); border-color: var(--vit-ink); color: var(--vit-paper); }
a.dwft-btn-fill:hover { background: var(--vit-ink); border-color: var(--vit-ink); color: var(--vit-paper); }

/* B/690 (founder 26.11): the menu page says first that the web tools work now; the desktop block says it is the desktop app only, in development. */
.dwf-now { display: flex; align-items: flex-start; gap: var(--vit-space-2); margin: var(--vit-space-2) 0 0; font-size: 15px; font-weight: 500; color: var(--vit-ink); }
.dwf-now-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--vit-clay); flex: none; margin-block-start: calc(0.75em - 4px); } /* centred on the first line (line-height 1.5) */
/* Bezalel B/690 (ch.5, gate item 15): one sentence per line, at every width. */
.dwf-now-t > span, .dwf-dev > span { display: block; }
.dwf-now { line-height: 1.5; }
.dwf-dev { margin: 0 0 var(--vit-space-3); padding: var(--vit-space-2) var(--vit-space-3); border-inline-start: 3px solid var(--vit-clay); background: var(--vit-paper-2); font-size: 15px; color: var(--vit-ink); }
/* B/703 (Bezalel B/690, ch.5): the hero lead is three sentences, one per line at every width. */
.dwf-lead > span { display: block; }
