/*! Copyright (c) 2026 Dominic Tope. Classroom use permitted. See COPYRIGHT.txt and THIRD-PARTY-NOTICES.txt. */
.processing-layer{position:fixed;inset:0;z-index:1250;display:grid;place-items:center;overflow-y:auto;background:rgba(15,23,42,.44);padding:24px;backdrop-filter:blur(11px) saturate(88%);animation:processing-layer-in 170ms ease both}.processing-card{position:relative;width:min(510px,100%);height:470px;max-height:calc(100dvh - 48px);display:flex;flex-direction:column;align-items:center;justify-content:center;overflow-x:hidden;overflow-y:auto;border:1px solid rgba(191,219,254,.95);border-radius:25px;background:rgba(255,255,255,.97);padding:34px 38px 32px;text-align:center;box-shadow:0 30px 90px rgba(15,23,42,.35);animation:processing-card-in 210ms cubic-bezier(.22,1,.36,1) both}.processing-close{position:absolute;top:14px;right:15px;z-index:2;width:38px;height:38px;display:grid;place-items:center;border:0;border-radius:11px;background:#eef4fb;color:#52627a;padding:0 0 2px;font-size:1.55rem;line-height:1;cursor:pointer}.processing-close:hover{background:#dfeafb;color:var(--ink)}.processing-visual{position:relative;width:136px;height:136px;flex:none;margin:1px auto 16px}.processing-dots{position:absolute;inset:0}.processing-dot{--dot-index:0;position:absolute;top:50%;left:50%;width:11px;height:11px;border:2px solid #cbd9eb;border-radius:50%;background:#f2f6fb;margin:-5.5px;transform:rotate(calc(var(--dot-index) * 22.5deg)) translateY(-59px) scale(.88);transition:background 120ms ease,border-color 120ms ease,box-shadow 120ms ease,transform 120ms ease}.processing-dot.is-filled{border-color:#4c87d9;background:#4c87d9;box-shadow:0 0 0 4px rgba(76,135,217,.13);transform:rotate(calc(var(--dot-index) * 22.5deg)) translateY(-59px) scale(1)}.processing-centre{position:absolute;top:50%;left:50%;width:66px;height:66px;display:grid;place-items:center;border:1px solid #c7d9f2;border-radius:22px;background:linear-gradient(145deg,#f7fbff,#dceafe);color:var(--brand-bright);font-size:2rem;font-weight:900;line-height:1;box-shadow:0 10px 26px rgba(17,70,161,.14);transform:translate(-50%,-50%)}.processing-card:not(.ready):not(.error) .processing-centre{animation:processing-worker-turn 1.55s linear infinite}.processing-card.ready .processing-centre{border-color:#a7f3d0;background:#dcfce7;color:var(--success);animation:none}.processing-card.error .processing-centre{border-color:#fecaca;background:#fee4e2;color:var(--danger);animation:none}.processing-card.ready .processing-dot.is-filled{border-color:#12b76a;background:#12b76a;box-shadow:0 0 0 4px rgba(18,183,106,.13)}.processing-card.error .processing-dot.is-filled{border-color:#f04438;background:#f04438;box-shadow:0 0 0 4px rgba(240,68,56,.12)}.processing-eyebrow{min-height:1em;margin:0 0 5px;color:#3572c8;font-size:.7rem;font-weight:900;letter-spacing:.14em}.processing-card h2{min-height:2.35em;display:flex;align-items:center;justify-content:center;margin:0;color:var(--ink);font-size:clamp(1.65rem, 4vw, 2rem);letter-spacing:-.035em}.processing-card>p:not(.processing-eyebrow):not(.sr-only){min-height:3.2em;display:flex;align-items:flex-start;justify-content:center;max-width:405px;margin:10px auto 0;color:#596579;line-height:1.6}.processing-action{min-width:190px;margin-top:19px}.processing-action[aria-hidden=true]{visibility:hidden}@keyframes processing-layer-in{from{opacity:0}to{opacity:1}}@keyframes processing-card-in{from{opacity:0;transform:translateY(12px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}@keyframes processing-worker-turn{from{transform:translate(-50%,-50%) rotate(0)}to{transform:translate(-50%,-50%) rotate(360deg)}}.processing-layer{--ink:#0f172a;--brand-bright:#2563eb;--success:#067647;--danger:#b42318;-webkit-backdrop-filter:blur(11px) saturate(88%)}.processing-layer,.processing-layer *{box-sizing:border-box}.processing-layer [hidden],.processing-layer[hidden]{display:none!important}body.modal-open{overflow:hidden}.processing-layer .processing-card{font-family:Arial,Helvetica,sans-serif}.processing-layer .processing-card h2{font-size:clamp(1.65rem, 4vw, 2rem);line-height:1.15;font-weight:700}.processing-layer .processing-eyebrow{font-size:.7rem;line-height:1.25}.processing-layer #processing-message{font-size:1rem;line-height:1.6}.processing-layer .processing-action{min-height:44px;border:1px solid #1146a1;border-radius:14px;background:#1146a1;color:#fff;padding:11px 18px;font:700 .9rem/1.25 Arial,Helvetica,sans-serif;cursor:pointer}.processing-layer .processing-action:hover{background:#0b347c}.processing-layer button:focus-visible{outline:3px solid #2563eb;outline-offset:4px}.processing-layer .sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media (max-width:620px){.processing-layer{padding:16px}.processing-layer .processing-card{max-height:calc(100dvh - 32px);padding:30px 22px 27px}.processing-visual{width:126px;height:126px}.processing-dot{transform:rotate(calc(var(--dot-index) * 22.5deg)) translateY(-54px) scale(.88)}.processing-dot.is-filled{transform:rotate(calc(var(--dot-index) * 22.5deg)) translateY(-54px) scale(1)}}@media (prefers-reduced-motion:reduce){.processing-layer,.processing-layer *{animation:none!important;transition:none!important}}@media print{.processing-layer{display:none!important}}.processing-layer .processing-visual{display:grid;place-items:center;aspect-ratio:1/1}.processing-layer .processing-centre{inset:0;margin:auto;width:66px;height:66px;min-width:66px;min-height:66px;max-width:66px;max-height:66px;aspect-ratio:1/1;padding:0;border-radius:18px;transform:none;animation:none!important}.processing-layer .processing-centre svg{display:block;width:36px;height:36px;flex:none;overflow:visible;transform-origin:50% 50%;transform-box:view-box}.processing-layer .processing-centre[data-icon=working] svg{animation:processing-cog-turn 2.4s linear infinite}@keyframes processing-cog-turn{from{transform:rotate(0)}to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.processing-layer .processing-centre[data-icon=working] svg{animation:none}}.processing-layer .processing-card{height:auto;min-height:min(390px,calc(100dvh - 48px));justify-content:flex-start;padding:34px clamp(20px,5vw,38px) 28px}.processing-layer .processing-card h2{min-height:0;max-width:100%;overflow-wrap:anywhere}.processing-layer #processing-message{min-height:0;overflow-wrap:anywhere}.processing-layer .processing-action{max-width:100%;min-width:min(190px,100%);flex:none;white-space:normal}@media(max-height:480px){.processing-layer{padding:12px}.processing-layer .processing-card{min-height:0;max-height:calc(100dvh - 24px);padding:18px 20px}.processing-layer .processing-visual{zoom:.65;margin-bottom:8px}.processing-layer .processing-card h2{font-size:1.4rem}.processing-layer .processing-action{margin-top:12px}}