/* Three focused steps. The photo gets the space; actions stay within reach. */
.scan-app main{max-width:760px;padding:12px 16px}
.scan-stappen{margin:0 0 12px;justify-content:space-between;overflow:visible}
.scan-stappen li{flex:1}.scan-stappen button{width:100%;font-size:13px;padding:8px 4px}
.scan-invoer{display:block;text-align:center;margin:0}.scan-invoer h1{font-size:26px;margin:18px 0}
.scan-invoer .acties{justify-content:center}.scan-startbeeld{height: min(48dvh,360px);display:grid;place-items:center;background:#e9e3d9;border-radius:14px}
.scan-startbeeld span{font-size:70px;color:#80718e;border:2px dashed #a599b3;border-radius:12px;padding:12px 38px}
#melding:empty{display:none}#melding{font-size:14px;margin:8px 0}
#paginas{margin:0;display:block}#paginas>li{display:flex;flex-direction:column;background:transparent;border:0;padding:0;gap:8px;overflow:visible}
#paginas>li>img{order:0;width:100%;height: min(57dvh,580px);max-height:none;object-fit:contain;aspect-ratio:auto;background:#e9e3d9;border-radius:12px}
.scan-pagina-acties{order:1;display:flex;flex-direction:row;justify-content:center;flex-wrap:wrap;width:100%;gap:6px}
.scan-pagina-acties button{font-size:22px;min-width:44px;width:auto;padding:6px 10px;margin:0}
.scan-pagina-acties button:first-child{font-size:15px}
#paginas>li{position:relative}
.scan-foto{position:relative;width:100%;height:min(57dvh,580px);background:#e9e3d9;border-radius:12px;overflow:hidden}
.scan-foto img{position:absolute;inset:0;width:100%;height:100%;max-width:none;aspect-ratio:auto;object-fit:contain}
.scan-pagina-acties{position:absolute;right:8px;top:12px;width:auto;flex-direction:column;padding:5px;border-radius:12px;background:#fff8eddd;box-shadow:0 2px 12px #2d21451a;z-index:1}
.scan-pagina-acties button,.scan-pagina-acties button:first-child{font-size:25px;width:44px;height:44px;padding:4px}
.scan-meer{order:2;font-size:12px;color:#6e6485}.scan-meer summary{min-height:28px;cursor:pointer}.scan-meer button{font-size:14px;padding:6px 10px}
.scan-film{display:flex;align-items:center;gap:8px;margin:10px 0}
#scan-miniaturen{gap:6px;padding:2px;margin:0;min-width:0;max-width:calc(100% - 110px)}
#scan-miniaturen>li{flex-basis:44px}#scan-miniaturen button{position:relative;width:44px;height:52px;padding:3px;border-radius:8px}
#scan-miniaturen img{width:34px;height:42px}#scan-miniaturen span{position:absolute;bottom:1px;right:2px;background:white;border-radius:3px;padding:0 3px;font-size:11px}
#scan-nog{flex:0 0 44px;height:48px;padding:4px;border-width:1px;border-radius:8px}
#scan-totaal{margin:0 0 0 auto;font-size:13px;font-weight:400;white-space:nowrap;color:#6e6485}
.scan-doorgaan{position:sticky;bottom:0;background:#fff8ed;padding:8px 0;margin:0;z-index:3}.scan-doorgaan button{width:100%}
#scan-uitvoer{border:0;margin:0;padding:0}#scan-uitvoer h2{margin-top:16px}
#scan-uitvoer .acties button{flex:1}#bewerken{background:transparent;color:#48318e;border-color:#d6cce9}
.scan-uitleg{margin:12px 0;font-size:12px;color:#6e6485}.scan-uitleg summary{min-height:32px}
#camera-dialog,#papier-dialog{background:#fff8ed;color:#2d2145;padding:10px;max-height:calc(100dvh - 16px)}
#camera-dialog[open]{display:flex;flex-direction:column;gap:6px}
#camera-dialog h2{margin:0;font-size:17px}#camera-dialog .camera-beeld{min-height:0;flex:1;display:grid;place-items:center}
#camera-dialog #camera-video{max-height:calc(100dvh - 165px)}
#camera-status{margin:0!important;font-size:12px!important;min-height:17px}
#camera-dialog .acties{display:flex!important;margin:0;gap:8px}#camera-dialog .acties button{width:auto}#camera-dialog #camera-opnemen{flex:1}
#camera-opnemen,#live-camera{background:#ffc95b!important;border-color:#ffc95b!important;color:#2d2145}
#camera-stop,#camera-flits,#open-bestanden{border:1px solid #e6b64d;background:transparent;color:#2d2145}
#papier-dialog .papier-kop h2{font-size:17px}#papier-dialog .papier-kop button{min-height:40px}
#papier-dialog #papier-preview{max-height:calc(100dvh - 215px);margin:6px auto}
#papier-dialog details{font-size:12px;padding:0;border:0}#papier-dialog details summary{min-height:28px}
#papier-dialog .acties{background:#fff8ed;bottom:-10px;display:flex;gap:6px;margin:4px 0 0;padding:6px 0}
#papier-dialog .acties button{font-size:13px;width:auto;padding:10px 8px;min-height:44px}
#papier-toepassen{flex:1;background:#48318e;color:white;border-color:#48318e}
#papier-toepassen:hover{background:#3a2774;border-color:#3a2774}
#papier-status:empty{display:none}#papier-status{font-size:12px;margin:4px 0}
@media(max-width:600px){
 .scan-app main{padding:8px}.scan-stappen{margin-bottom:8px}
 #camera-dialog,#papier-dialog{width:100%;height:100dvh;max-height:100dvh;max-width:none;margin:0;border:0;border-radius:0;padding:8px}
 #papier-dialog #papier-preview{max-height:calc(100dvh - 205px)}
 #camera-dialog .camera-beeld{flex:0 1 auto}#camera-dialog #camera-video{max-height:calc(100dvh - 130px)}
 #camera-dialog .acties{margin-top:auto;padding-bottom:env(safe-area-inset-bottom)}
 #papier-dialog .acties{padding-bottom:max(6px,env(safe-area-inset-bottom))}
}
