<iframe> skipped (cannot access content). Use options.placeholders to show a placeholder instead.",e),r.placeholders){let{width:f,height:d}%3Dze(e),h%3Ddocument.createElement("div")%3Breturn h.style.cssText%3D`width:${f}px%3Bheight:${d}px%3Bbackground-image:repeating-linear-gradient(45deg,#ddd,#ddd 5px,#f9f9f9 5px,#f9f9f9 10px)%3Bdisplay:flex%3Balign-items:center%3Bjustify-content:center%3Bfont-size:12px%3Bcolor:#555%3Bborder:1px solid #aaa%3B`,pt(e,h,t,r),h}else{let{width:f,height:d}%3Dze(e),h%3Ddocument.createElement("div")%3Breturn h.style.cssText%3D`display:inline-block%3Bwidth:${f}px%3Bheight:${d}px%3Bvisibility:hidden%3B`,pt(e,h,t,r),h}}if(e.getAttribute("data-capture")%3D%3D%3D"placeholder"){let l%3De.cloneNode(!1)%3Bt.nodeMap.set(l,e),pt(e,l,t,r)%3Blet f%3Ddocument.createElement("div")%3Breturn f.textContent%3De.getAttribute("data-placeholder-text")||"",f.style.cssText%3D"color:#666%3Bfont-size:12px%3Btext-align:center%3Bline-height:1.4%3Bpadding:0.5em%3Bbox-sizing:border-box%3B",l.appendChild(f),l}if(e.tagName%3D%3D%3D"CANVAS"){let l%3D""%3Btry{let p%3De.getContext("2d",{willReadFrequently:!0})%3Btry{p&&p.getImageData(0,0,1,1)}catch{}if(await new Promise(m%3D>requestAnimationFrame(m)),l%3De.toDataURL("image/png"),!l||l%3D%3D%3D"data:,"){try{p&&p.getImageData(0,0,1,1)}catch{}if(await new Promise(m%3D>requestAnimationFrame(m)),l%3De.toDataURL("image/png"),!l||l%3D%3D%3D"data:,"){let m%3Ddocument.createElement("canvas")%3Bm.width%3De.width,m.height%3De.height%3Blet g%3Dm.getContext("2d")%3Bg&&(g.drawImage(e,0,0),l%3Dm.toDataURL("image/png"))}}}catch(p){te(t,"Canvas toDataURL failed, using empty/fallback",p)}let f%3Ddocument.createElement("img")%3Btry{f.decoding%3D"sync",f.loading%3D"eager"}catch(p){te(t,"img decoding/loading hints failed",p)}l&&(f.src%3Dl),f.width%3De.width,f.height%3De.height%3Blet{width:d,height:h}%3Dze(e)%3Breturn d>0&&(f.style.width%3D`${d}px`),h>0&&(f.style.height%3D`${h}px`),t.nodeMap.set(f,e),pt(e,f,t,r),f}if(e.tagName%3D%3D%3D"VIDEO"){let l%3D""%3Btry{let p%3Ddocument.createElement("canvas")%3Bp.width%3De.videoWidth||e.offsetWidth||320,p.height%3De.videoHeight||e.offsetHeight||240%3Blet m%3Dp.getContext("2d")%3Bm&&(m.drawImage(e,0,0,p.width,p.height),l%3Dp.toDataURL("image/png"),(!l||l%3D%3D%3D"data:,")&&(l%3D""))}catch(p){te(t,"Video frame capture failed, using poster fallback",p)}let f%3Ddocument.createElement("img")%3Btry{f.decoding%3D"sync",f.loading%3D"eager"}catch{}l?f.src%3Dl:e.poster&&(f.src%3De.poster),f.width%3De.videoWidth||e.offsetWidth||0,f.height%3De.videoHeight||e.offsetHeight||0%3Blet{width:d,height:h}%3Dze(e)%3Breturn d>0&&(f.style.width%3D`${d}px`),h>0&&(f.style.height%3D`${h}px`),f.style.objectFit%3D"contain",t.nodeMap.set(f,e),pt(e,f,t,r),f}let s%3Btry{if(s%3De.cloneNode(!1),s.attributes?.length)try{for(let l of s.attributes)/[\x00-\x08\x0B\x0C\x0E-\x1F\uFFFE\uFFFF]/.test(l.value)&&s.setAttribute(l.name,l.value.replace(/[\x00-\x08\x0B\x0C\x0E-\x1F\uFFFE\uFFFF]/g,""))}catch{}if(Od(e,s),t.nodeMap.set(s,e),e.tagName%3D%3D%3D"IMG"){Ud(e,s)%3Btry{let{width:l,height:f}%3Dze(e),d%3DMath.round(l||0),h%3DMath.round(f||0)%3Bd&&(s.dataset.snapdomWidth%3DString(d)),h&&(s.dataset.snapdomHeight%3DString(h))}catch(l){te(t,"getUnscaledDimensions for IMG failed",l)}try{let l%3De.getAttribute("style")||"",f%3Dwindow.getComputedStyle(e),d%3Dw%3D>{let v%3Dl.match(new RegExp(`${w}\\s*:\\s*([^%3B]+)`,"i")),S%3Dv?v[1].trim():f.getPropertyValue(w)%3Breturn/%|auto/i.test(String(S||""))},h%3DparseInt(s.dataset.snapdomWidth||"0",10),p%3DparseInt(s.dataset.snapdomHeight||"0",10),m%3Dd("width")||!h,g%3Dd("height")||!p%3Bm&&h&&(s.style.width%3D`${h}px`),g&&p&&(s.style.height%3D`${p}px`)%3Blet y%3Df.getPropertyValue("object-fit"),b%3Df.getPropertyValue("object-position")%3By&&y!%3D%3D"fill"?(s.style.objectFit%3Dy,b&&(s.style.objectPosition%3Db)):(h&&(s.style.minWidth%3D`${h}px`),p&&(s.style.minHeight%3D`${p}px`))}catch(l){te(t,"IMG dimension freeze failed",l)}}}catch(l){throw console.error("[Snapdom] Failed to clone node:",e,l),l}let c%3Dnull%3Bif(e instanceof HTMLTextAreaElement){let{width:l,height:f}%3Dze(e),d%3Dl||e.getBoundingClientRect().width||0,h%3Df||e.getBoundingClientRect().height||0%3Bd&&(s.style.width%3D`${d}px`),h&&(s.style.height%3D`${h}px`)}if(e instanceof HTMLInputElement){let l%3D(e.type||"text").toLowerCase()%3Bif((l%3D%3D%3D"checkbox"||l%3D%3D%3D"radio")&&ld()){let{el:f,applyVisual:d}%3DYd(e)%3Bt.nodeMap.set(f,e),c%3Dd,s%3Df}else s.value%3De.value,s.setAttribute("value",e.value),e.checked!%3D%3Dvoid 0&&(s.checked%3De.checked,e.checked&&s.setAttribute("checked",""),e.indeterminate&&(s.indeterminate%3De.indeterminate))}if((e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement)&&!e.value&&e.placeholder)try{let l%3Dwindow.getComputedStyle(e,"::placeholder"),f%3Dl&&l.color%3Bif(f&&f!%3D%3D"rgba(0, 0, 0, 0)"){let d%3D"snapdom-ph-"+(Math.random()*1e6|0)%3Bs.classList.add(d)%3Blet h%3Ddocument.createElement("style")%3Bh.textContent%3D`.${d}::placeholder{color:${f}!important%3Bopacity:${l.opacity||"1"}!important%3B}`,s.prepend(h)}}catch{}if(e instanceof HTMLSelectElement&&(n%3De.value),e instanceof HTMLTextAreaElement&&(o%3De.value),e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement||e instanceof HTMLSelectElement){e.disabled&&s.setAttribute("disabled",""),e.required&&s.setAttribute("required",""),e.readOnly&&s.setAttribute("readonly","")%3Blet l%3De%3Bl.min!%3D%3Dvoid 0&&l.min!%3D%3D""&&s.setAttribute("min",l.min),l.max!%3D%3Dvoid 0&&l.max!%3D%3D""&&s.setAttribute("max",l.max),l.pattern!%3D%3Dvoid 0&&l.pattern!%3D%3D""&&s.setAttribute("pattern",l.pattern)%3Blet f%3De.getAttribute("aria-invalid")%3Bf!%3D%3Dnull&&s.setAttribute("aria-invalid",f)}if(Dn(e)||pt(e,s,t,r),c&&c(),e instanceof SVGElement&&!Dn(e)){let l%3D["fill","stroke","stroke-width","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","opacity","fill-opacity","stroke-opacity","fill-rule","clip-rule","marker","marker-start","marker-mid","marker-end","visibility","display"]%3Btry{let f%3Dwindow.getComputedStyle(e)%3Bfor(let d of l){let h%3Df.getPropertyValue(d)%3Bh&&s.style.setProperty(d,h)}}catch{}}if(e.shadowRoot){let l%3Dfunction(w,v){if(w.nodeType%3D%3D%3DNode.ELEMENT_NODE&&w.tagName%3D%3D%3D"STYLE")return v(null)%3Bvr(w,t,r).then(S%3D>{v(S||null)}).catch(()%3D>{v(null)})}%3Btry{let w%3De.shadowRoot.querySelectorAll("slot")%3Bfor(let v of w){let S%3D[]%3Btry{S%3Dv.assignedNodes?.({flatten:!0})||v.assignedNodes?.()||[]}catch{S%3Dv.assignedNodes?.()||[]}for(let E of S)i.add(E)}}catch{}let f%3D_d(t),d%3D`[data-sd%3D"${f}"]`%3Btry{s.setAttribute("data-sd",f)}catch{}let h%3DFd(e.shadowRoot),p%3DPd(h,d),m%3DWd(h),g%3DHd(e,m,d)%3B$d(s,g+p,f)%3Blet y%3Ddocument.createDocumentFragment(),b%3Dawait Cn(Array.from(e.shadowRoot.childNodes),l,r.fast)%3By.append(...b.filter(w%3D>!!w)),s.appendChild(y)}if(e.tagName%3D%3D%3D"SLOT"){let l%3Dfunction(m,g){vr(m,t,r).then(y%3D>{y&&Vd(y),g(y||null)}).catch(()%3D>{g(null)})},f%3De.assignedNodes?.({flatten:!0})||[],d%3Df.length>0?f:Array.from(e.childNodes),h%3Ddocument.createDocumentFragment(),p%3Dawait Cn(Array.from(d),l,r.fast)%3Breturn h.append(...p.filter(m%3D>!!m)),h}function a(l,f){if(i.has(l))return f(null)%3Bvr(l,t,r).then(d%3D>{f(d||null)}).catch(()%3D>{f(null)})}let u%3Dawait Cn(Array.from(e.childNodes),a,r.fast)%3Bif(s.append(...u.filter(l%3D>!!l)),n!%3D%3Dnull&&s instanceof HTMLSelectElement){s.value%3Dn%3Bfor(let l of s.options)l.value%3D%3D%3Dn?l.setAttribute("selected",""):l.removeAttribute("selected")}return o!%3D%3Dnull&&s instanceof HTMLTextAreaElement&&(s.textContent%3Do),s}function ef(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function tf(e){let t%3DArray.isArray(e)?e:[e]%3Bfor(let r of t)r instanceof RegExp?On.push(r):typeof r%3D%3D"string"?On.push(new RegExp(ef(r),"i")):console.warn("[snapdom] Ignored invalid iconFont value:",r)}function Qe(e){let t%3Dtypeof e%3D%3D"string"?e:"",r%3D[...Qd,...On]%3Bfor(let i of r)if(i instanceof RegExp&&i.test(t))return!0%3Breturn!!(/icon/i.test(t)||/glyph/i.test(t)||/symbols/i.test(t)||/feather/i.test(t)||/fontawesome/i.test(t))}function rf(e%3D""){let t%3DString(e).toLowerCase()%3Breturn/\bmaterial\s*icons\b/.test(t)||/\bmaterial\s*symbols\b/.test(t)}function nf(e%3D""){let t%3DObject.create(null),r%3DString(e||""),i%3D/['"]?\s*([A-Za-z]{3,4})\s*['"]?\s*([+-]?\d+(?:\.\d+)?)\s*/g,n%3Bfor(%3Bn%3Di.exec(r)%3B)t[n[1].toUpperCase()]%3DNumber(n[2])%3Breturn t}async function of(e,t,r){let i%3DString(e||""),n%3Di.toLowerCase(),o%3DString(t||"").toLowerCase()%3Bif(/\bmaterial\s*icons\b/.test(n)&&!/\bsymbols\b/.test(n))return{familyForMeasure:i,familyForCanvas:i}%3Bif(!/\bmaterial\s*symbols\b/.test(n))return{familyForMeasure:i,familyForCanvas:i}%3Blet s%3Dr&&(r.FILL??r.fill),c%3D"outlined"%3B/\brounded\b/.test(o)||/\bround\b/.test(o)?c%3D"rounded":/\bsharp\b/.test(o)?c%3D"sharp":/\boutlined\b/.test(o)&&(c%3D"outlined")%3Blet a%3Ds%3D%3D%3D1,u%3Dnull%3Bif(a&&(c%3D%3D%3D"outlined"&&Tt.materialIconsFilled?u%3D{url:Tt.materialIconsFilled,alias:"snapdom-mi-filled"}:c%3D%3D%3D"rounded"&&Tt.materialIconsRound?u%3D{url:Tt.materialIconsRound,alias:"snapdom-mi-round"}:c%3D%3D%3D"sharp"&&Tt.materialIconsSharp&&(u%3D{url:Tt.materialIconsSharp,alias:"snapdom-mi-sharp"})),!u)return{familyForMeasure:i,familyForCanvas:i}%3Bif(!cs.has(u.alias))try{let f%3Dnew FontFace(u.alias,`url(${u.url})`,{style:"normal",weight:"400"})%3Bdocument.fonts.add(f),await f.load(),cs.set(u.alias,!0)}catch{return{familyForMeasure:i,familyForCanvas:i}}let l%3D`"${u.alias}"`%3Breturn{familyForMeasure:l,familyForCanvas:l}}async function sf(e%3D"Material Icons",t%3D24){try{await Promise.all([document.fonts.load(`400 ${t}px "${String(e).replace(/["']/g,"")}"`),document.fonts.ready])}catch{}}function af(e){let t%3De.getPropertyValue("-webkit-text-fill-color")?.trim()||"",r%3D/^transparent$/i.test(t)||/rgba?\(\s*0\s*,\s*0\s*,\s*0\s*,\s*0\s*\)/i.test(t)%3Bif(t&&!r&&t.toLowerCase()!%3D%3D"currentcolor")return t%3Blet i%3De.color?.trim()%3Breturn i&&i!%3D%3D"inherit"?i:"#000"}async function lf(e,{family:t%3D"Material Icons",weight:r%3D"normal",fontSize:i%3D32,color:n%3D"#000",variation:o%3D"",className:s%3D""}%3D{}){let c%3DString(t||"").replace(/^['"]+|['"]+$/g,""),a%3Dwindow.devicePixelRatio||1,u%3Dnf(o),{familyForMeasure:l,familyForCanvas:f}%3Dawait of(c,s,u)%3Bawait sf(f.replace(/^["']+|["']+$/g,""),i)%3Blet d%3Ddocument.createElement("span")%3Bd.textContent%3De,d.style.position%3D"absolute",d.style.visibility%3D"hidden",d.style.left%3D"-99999px",d.style.whiteSpace%3D"nowrap",d.style.fontFamily%3Dl,d.style.fontWeight%3DString(r||"normal"),d.style.fontSize%3D`${i}px`,d.style.lineHeight%3D"1",d.style.margin%3D"0",d.style.padding%3D"0",d.style.fontFeatureSettings%3D"'liga' 1",d.style.fontVariantLigatures%3D"normal",d.style.color%3Dn,document.body.appendChild(d)%3Blet h%3Dd.getBoundingClientRect(),p%3DMath.max(1,Math.ceil(h.width)),m%3DMath.max(1,Math.ceil(h.height))%3Bdocument.body.removeChild(d)%3Blet g%3Ddocument.createElement("canvas")%3Bg.width%3Dp*a,g.height%3Dm*a%3Blet y%3Dg.getContext("2d")%3By.scale(a,a),y.font%3D`${r?`${r} `:""}${i}px ${f}`,y.textAlign%3D"left",y.textBaseline%3D"top",y.fillStyle%3Dn%3Btry{y.fontKerning%3D"normal"}catch{}return y.fillText(e,0,0),{dataUrl:g.toDataURL(),width:p,height:m}}async function cf(e,t){if(!(e instanceof Element))return 0%3Blet r%3D'.material-icons, [class*%3D"material-symbols"]',i%3DArray.from(e.querySelectorAll(r)).filter(s%3D>s&&s.textContent&&s.textContent.trim())%3Bif(i.length%3D%3D%3D0)return 0%3Blet n%3Dt instanceof Element?Array.from(t.querySelectorAll(r)).filter(s%3D>Not flagged