.task-running-card{position:absolute;z-index:7;left:50%;top:50%;width:min(430px,calc(100% - 42px));padding:17px 18px;transform:translate(-50%,-50%);border:1px solid rgba(152,131,255,.9);border-radius:15px;background:linear-gradient(145deg,rgba(244,241,255,.97),rgba(255,255,255,.97) 55%,rgba(231,251,244,.97));box-shadow:0 18px 45px rgba(10,15,31,.38),0 0 0 5px rgba(121,91,235,.1);pointer-events:none;text-align:left}
.task-running-heading{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:8px}
.task-running-heading strong{min-width:0;color:#452cb5;font-size:16px;font-weight:950;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.task-running-heading time{padding:5px 9px;border-radius:8px;background:linear-gradient(105deg,#5d42d6,#8b49dc);box-shadow:0 5px 12px rgba(91,60,194,.25);color:#fff;font-size:11px;font-weight:900;white-space:nowrap}
.task-running-orb{width:15px;height:15px;border:4px solid #7356e7;border-right-color:transparent;border-radius:50%;animation:resultTaskSpin .75s linear infinite;box-shadow:0 0 0 5px rgba(115,86,231,.11)}
.task-running-card p{margin:13px 0 10px;padding:10px 11px;border-radius:9px;background:#fff4dd;color:#8c4c00;font-size:13px;font-weight:900}
.task-running-tips{display:flex;flex-wrap:wrap;gap:5px}
.task-running-tips span{padding:5px 9px;border-radius:99px;background:#ddf8ed;color:#006d4d;font-size:11px;font-weight:900}
.empty-result.runtime-hidden{display:none!important}
.modal-image-loading{position:absolute;z-index:2;left:50%;top:50%;width:min(340px,calc(100% - 40px));padding:22px 24px;display:grid;justify-items:center;gap:9px;transform:translate(-50%,-50%);border:1px solid rgba(157,137,255,.72);border-radius:15px;background:rgba(20,25,38,.9);box-shadow:0 18px 44px rgba(0,0,0,.42);backdrop-filter:blur(10px);color:#fff;text-align:center;pointer-events:none}
.modal-image-loading i{width:29px;height:29px;border:4px solid #8d73ff;border-right-color:transparent;border-radius:50%;animation:resultTaskSpin .75s linear infinite}
.modal-image-loading strong{font-size:15px}.modal-image-loading small{color:#c5cfde;font-size:11px}.modal-image-loading.error{border-color:rgba(244,113,127,.8);background:rgba(55,25,32,.94)}.modal-image-loading.error i{display:none}.modal-image-loading.error strong{color:#ffb2ba}
.result-metrics{position:absolute;z-index:8;left:50%;bottom:14px;display:flex;align-items:center;gap:7px;transform:translateX(-50%);padding:6px;border:1px solid rgba(255,255,255,.18);border-radius:10px;background:rgba(16,23,34,.86);box-shadow:0 7px 20px rgba(0,0,0,.3);backdrop-filter:blur(8px);color:#fff;pointer-events:none;white-space:nowrap}
.result-metrics b,.result-metrics em{padding:4px 8px;border-radius:7px;font-size:11px;font-style:normal;font-weight:900}
.result-metrics b{background:#6250dc;color:#fff}
.result-metrics em{background:#dff8ed;color:#067153}
.run-command-row{display:grid;grid-template-columns:minmax(0,1fr);gap:9px;align-items:stretch}
.run-command-row.has-feedback{grid-template-columns:minmax(0,3fr) minmax(122px,1fr)}
.run-command-row .run-button{height:100%;min-height:66px}
.result-feedback-actions{display:grid;grid-template-columns:1fr;gap:6px}
.result-feedback-actions button{min-height:30px;padding:4px 7px;border-radius:8px;background:#fff;font-size:10.5px;font-weight:850;line-height:1.2}
.result-feedback-actions button.is-unavailable{opacity:.7;border-style:dashed}
.result-feedback-button{border:1px solid #93a4c0;color:#344866}
.result-feedback-button:hover{border-color:#6d57d8;background:#f6f3ff;color:#5238bc}
.result-refund-button{border:1px solid #ec9b47;color:#a65408;background:#fff9ee!important}
.result-refund-button:hover{border-color:#dc7611;background:#fff1d7!important;color:#8b4000}
@keyframes resultTaskSpin{to{transform:rotate(360deg)}}
@media(max-width:600px){.task-running-card{width:calc(100% - 24px);padding:14px}.task-running-heading{grid-template-columns:auto minmax(0,1fr)}.task-running-heading time{grid-column:2;justify-self:start}.task-running-card p{font-size:12px}.result-metrics{bottom:9px}.run-command-row.has-feedback{grid-template-columns:minmax(0,3fr) minmax(108px,1fr)}}
/* ID card review: external stylesheet required by production CSP. */
.idcard-review{position:fixed;inset:0;z-index:10000;background:#17223b99;display:grid;place-items:center;padding:12px;box-sizing:border-box}
.idcard-review *{box-sizing:border-box}
.idcard-review>section{background:white;border-radius:16px;width:min(1050px,100%);height:min(820px,calc(100dvh - 24px));max-height:calc(100vh - 24px);padding:18px;color:#27324a;display:flex;flex-direction:column;overflow:hidden;min-height:0}
.idcard-review header,.idcard-review footer{display:flex;align-items:center;gap:10px;justify-content:space-between;flex-shrink:0;background:white;position:static}
.idcard-review h2{font-size:19px;margin:0}.idcard-review p{font-size:13px;line-height:1.6;margin:8px 0;flex-shrink:0}
.idcard-review .panels{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:18px;margin:10px 0;min-height:0;overflow:auto;flex:1}
.idcard-review .panels>div{min-width:0}
.idcard-review canvas{width:100%;height:auto;touch-action:none;cursor:crosshair;display:block;background:#edf0f8}
.idcard-review img{max-width:100%;height:auto;display:block;-webkit-user-drag:none}
.idcard-review button{border:1px solid #d8dbea;border-radius:8px;padding:10px 14px;background:white;cursor:pointer;color:#27324a;white-space:normal}
.idcard-review button.primary{background:#7352e8;color:white}.idcard-review button:disabled{opacity:.45;cursor:default}
.idcard-review .message{color:#9b4a1b;min-height:21px}.idcard-review .actions{display:flex;gap:8px;flex-wrap:wrap;margin:8px 0}
@media(max-width:650px){.idcard-review .panels{grid-template-columns:minmax(0,1fr)}.idcard-review>section{padding:12px}.idcard-review h2{font-size:16px}.idcard-review footer button{padding:9px;font-size:13px}}
/* Fit the entire source and all four handles within the editor viewport. */
.perspective-review .panels{overflow:hidden}
.perspective-review .source-panel,.perspective-review .preview-panel{display:flex;flex-direction:column;min-height:0;gap:8px}
.perspective-review .canvas-fit,.perspective-review .preview-fit{flex:1;min-height:0;display:flex;align-items:center;justify-content:center;overflow:hidden;background:#edf0f8;border-radius:8px}
.perspective-review canvas{width:auto;height:auto;max-width:100%;max-height:100%}
.perspective-review img{max-width:100%;max-height:100%;width:auto;height:auto;object-fit:contain}
@media(max-width:650px){.perspective-review .panels{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(160px,1.3fr) minmax(100px,1fr);gap:8px;overflow:auto}.perspective-review .preview-panel>p{display:none}.perspective-review>section>p{font-size:12px;line-height:1.4}}
