/* Palet pencarian (Ctrl K), toast, dialog. */
/* palet pencarian */
#cmdk{width:min(620px,calc(100vw - 32px));margin-top:12vh;padding:0}
.ck-in{display:flex;align-items:center;gap:10px;padding:0 16px;height:56px;border-bottom:1px solid var(--stroke)}
.ck-in svg{width:18px;height:18px;color:var(--fg-3)}
.ck-in input{flex:1;border:0;background:none;outline:none;font-size:16px;color:var(--fg);height:100%;min-width:0}
.ck-in input::placeholder{color:var(--fg-3)}
.ck-in:focus-within{box-shadow:inset 0 -2px 0 var(--blue)}
.ck-res{max-height:min(420px,55vh);overflow-y:auto;padding:8px}
.ck-g{font-size:12px;font-weight:500;color:var(--fg-3);padding:10px 10px 4px}
.ck-i{display:flex;align-items:center;gap:12px;padding:9px 10px;border-radius:var(--r);font-size:14px;line-height:20px;color:var(--fg);cursor:pointer}
.ck-i .ic{width:28px;height:28px;border-radius:6px;background:var(--bg-3);display:grid;place-items:center;color:var(--fg-2);flex:none}
.ck-i .ic svg{width:15px;height:15px}
.ck-i .s{display:block;font-size:12px;line-height:16px;color:var(--fg-3);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.ck-i .m{min-width:0;flex:1}
.ck-i[aria-selected="true"]{background:var(--bg-3)}
.ck-empty{padding:28px 16px;text-align:center;color:var(--fg-3);font-size:14px}
.ck-f{display:flex;gap:16px;padding:10px 16px;border-top:1px solid var(--stroke);font-size:12px;color:var(--fg-3)}
.ck-f span{display:inline-flex;align-items:center;gap:6px}

/* toast & dialog */
.toast{position:fixed;left:50%;bottom:calc(20px + env(safe-area-inset-bottom,0px));transform:translate(-50%,16px);display:flex;align-items:center;gap:10px;background:var(--fg);color:var(--bg);border-radius:var(--r);box-shadow:var(--shadow-xl);padding:10px 16px;font-size:14px;line-height:20px;opacity:0;pointer-events:none;transition:opacity .2s,transform .2s;z-index:95;max-width:calc(100vw - 32px)}
.toast svg{width:18px;height:18px}
.toast.show{opacity:1;transform:translate(-50%,0)}
dialog{border:1px solid var(--stroke-2);border-radius:var(--r-lg);padding:0;box-shadow:var(--shadow-xl);background:var(--bg);color:var(--fg-2)}
dialog::backdrop{background:var(--scrim)}
dialog[open]{animation:mIn .2s ease}
@keyframes mIn{from{opacity:0;transform:scale(.97) translateY(-8px)}}
#doneDlg{width:min(440px,calc(100vw - 32px))}
.m-body{padding:32px 24px 24px;display:flex;flex-direction:column;align-items:center;text-align:center;gap:14px}
.m-ic{width:52px;height:52px;border-radius:50%;background:var(--pos-soft);display:grid;place-items:center;color:var(--pos)}
.m-ic svg{width:26px;height:26px}
.m-ic path{stroke-dasharray:30;stroke-dashoffset:30}
dialog[open] .m-ic path{animation:draw .45s .2s ease-out forwards}
@keyframes draw{to{stroke-dashoffset:0}}
.m-body h2{font-size:22px;line-height:30px;font-weight:600;color:var(--fg)}
.m-body .m-sub{font-size:14px;line-height:22px;color:var(--fg-2);margin-top:4px}
.m-foot{display:flex;gap:10px;padding:0 24px 24px}
.m-foot .btn{flex:1}
#lightbox{width:min(1200px,calc(100vw - 32px));max-height:calc(100vh - 32px)}
#lightbox .lb-h{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:8px 8px 8px 20px;border-bottom:1px solid var(--stroke);font-size:14px;color:var(--fg-2)}
#lightbox .lb-b{padding:16px;overflow:auto;max-height:calc(100vh - 120px);background:var(--bg-2);display:grid;place-items:center}
#lightbox img{display:block;max-width:100%;height:auto;border-radius:6px}
