/* One loading scene shared by the app router and full document navigation. */
.study-transition{--study-ink:#f4f9ff;--study-muted:#c3d7ee;--study-accent:#80e4fa;position:relative;isolation:isolate;min-height:100svh;box-sizing:border-box;display:grid;place-items:center;overflow:hidden;color:var(--study-ink);background:radial-gradient(ellipse at 22% 45%,#164c7f55,transparent 55%),radial-gradient(ellipse at 90% 80%,#404aa52e,transparent 50%),linear-gradient(155deg,#05172d,#0a2c4e);padding:max(24px,env(safe-area-inset-top)) max(20px,env(safe-area-inset-right)) max(24px,env(safe-area-inset-bottom)) max(20px,env(safe-area-inset-left));text-align:center}
.study-transition-scene{position:relative;z-index:1;width:min(1100px,100%);display:grid;grid-template-areas:'brand' 'art' 'copy';justify-items:center;gap:clamp(8px,2svh,20px)}
.study-transition-brand{grid-area:brand;display:flex;align-items:center;justify-content:center;gap:18px;text-align:left}
.study-transition-mark{display:flex;flex-direction:column;justify-content:center;flex:none;min-width:64px;min-height:64px;padding:10px;box-sizing:border-box;border:1px solid #8ddcf94d;border-radius:20px;background:linear-gradient(145deg,#6db9e126,#08274580);font-size:22px;font-weight:900;line-height:1.05;letter-spacing:-.055em;color:var(--study-ink)}
.study-transition-mark>span{color:var(--study-accent)}
.study-transition-brand>span:last-child{max-width:190px;font-size:11px;font-weight:750;line-height:1.7;text-transform:uppercase;letter-spacing:.2em;color:var(--study-muted)}
.study-transition-art{grid-area:art;position:relative;width:clamp(190px,37svh,390px);max-width:100%;aspect-ratio:1}
.study-transition-art::before{content:'';position:absolute;inset:15%;border:1px solid #87c9ff28;border-radius:50%;transform:rotate(-25deg) scaleX(1.25)}
.study-transition-art img{display:block;position:relative;width:100%;height:100%;object-fit:contain;animation:study-book-arrive 800ms ease-out both}
.study-transition-copy{grid-area:copy;width:min(500px,100%);min-width:0}
.study-transition-eyebrow{display:block;color:var(--study-accent);font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.17em;line-height:1.7}
.study-transition-copy h1,.study-transition-copy h2{margin:10px 0 14px;font:800 clamp(28px,4.2vw,48px)/1.12 system-ui,sans-serif;letter-spacing:-.04em;text-wrap:balance;color:var(--study-ink);overflow-wrap:anywhere}
.study-transition-copy>p{margin:0 auto;max-width:35ch;font:400 clamp(15px,1.8vw,19px)/1.65 system-ui,sans-serif;color:var(--study-muted);text-wrap:pretty;overflow-wrap:anywhere}
.study-transition-track{height:5px;width:min(260px,76%);margin:24px auto 12px;overflow:hidden;border-radius:99px;background:#a2c8ed25}
.study-transition-track>span{display:block;width:42%;height:100%;border-radius:inherit;background:linear-gradient(90deg,#75dff5,#bfc8ff,#ffc976);animation:study-progress 1.5s ease-in-out 8 alternate}
.study-transition-copy>a{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:4px 12px;color:var(--study-muted);font-size:13px;text-underline-offset:4px}
.study-transition-copy>a:focus-visible{outline:3px solid var(--study-accent);outline-offset:3px;border-radius:8px}
html[data-theme='light'] .study-transition{--study-ink:#103352;--study-muted:#395b77;--study-accent:#126e8b;background:radial-gradient(ellipse at 25% 50%,#caebff,transparent 65%),linear-gradient(145deg,#eff8ff,#e3e9ff)}
html[data-theme='light'] .study-transition-mark{background:#ffffffb0;border-color:#4389bd55}
@media(min-width:800px){.study-transition-scene{grid-template-columns:1.1fr 1fr;grid-template-areas:'brand brand' 'art copy';column-gap:clamp(24px,6vw,80px);row-gap:20px}.study-transition-brand{justify-self:start}.study-transition-art{width:min(48vw,560px);max-height:68svh}.study-transition-copy{text-align:left;justify-self:start}.study-transition-copy h1,.study-transition-copy h2{font-size:clamp(36px,4.4vw,58px)}.study-transition-copy>p{margin-left:0}.study-transition-track{margin-left:0}.study-transition-copy>a{padding-left:0}.study-transition-eyebrow{font-size:11px}}
@media(max-height:520px) and (min-width:540px){.study-transition{padding:16px 24px}.study-transition-scene{grid-template-columns:.8fr 1fr;grid-template-areas:'brand copy' 'art copy';column-gap:24px;row-gap:4px}.study-transition-brand{justify-self:center}.study-transition-art{width:min(42svh,260px)}.study-transition-mark{min-height:48px;min-width:48px;font-size:18px;border-radius:14px}.study-transition-brand>span:last-child{display:none}.study-transition-copy h1,.study-transition-copy h2{font-size:28px}.study-transition-track{margin-top:16px}}
@keyframes study-book-arrive{from{opacity:0;transform:translateY(16px) scale(.97)}to{opacity:1;transform:none}}
@keyframes study-progress{from{transform:translateX(-100%)}to{transform:translateX(340%)}}
@media(prefers-reduced-motion:reduce){.study-transition-art img,.study-transition-track>span{animation:none!important;transform:none}}
@media print{.study-transition{display:none!important}}

.sava-education-atmosphere{position:absolute;inset:0;overflow:hidden;pointer-events:none!important;user-select:none;contain:layout paint;z-index:0}
.sava-education-atmosphere *{pointer-events:none!important}
.sava-education-particle{position:absolute;left:var(--edu-x);top:var(--edu-y);width:var(--edu-size);height:var(--edu-size);border:1px solid var(--sa-line-9ceaf766,#9ceaf766);border-radius:50%;color:var(--sa-ink-a5edfc,#a5edfc);background:radial-gradient(circle at 28% 22%,var(--sa-surface-f0fdff35,#f0fdff35),transparent 48%),linear-gradient(135deg,var(--sa-surface-67e8f91c,#67e8f91c),var(--sa-surface-399ed408,#399ed408));box-shadow:inset -2px -3px 8px #4cc6eb14;opacity:.6;transform:translate(-50%,-50%);animation:sava-education-float 4.8s ease-out var(--edu-delay) both}
.sava-education-particle--gold{color:var(--sa-ink-f5d694,#f5d694);border-color:var(--sa-line-e9cd915c,#e9cd915c);background:radial-gradient(circle at 28% 22%,var(--sa-surface-ffefb82e,#ffefb82e),transparent 52%)}
.sava-education-particle--symbol{padding:9px;box-sizing:border-box;border-color:currentColor;background:var(--sa-surface-08284733,#08284733)}
.sava-education-particle svg{display:block;width:100%;height:100%}
.sava-education-surface,[data-education-surface]{position:relative;isolation:isolate}
.sava-education-atmosphere--course{position:fixed;z-index:-1;mask-image:linear-gradient(90deg,#000,transparent 90px,transparent calc(100% - 90px),#000)}
.sava-education-atmosphere--course .sava-education-particle{color:var(--sa-ink-377b9d,#377b9d);border-color:var(--sa-line-439bbe66,#439bbe66);background:radial-gradient(circle at 28% 22%,var(--sa-surface-bcebf135,#bcebf135),transparent 55%);opacity:.26;width:calc(var(--edu-size)*.8);height:calc(var(--edu-size)*.8)}
.sava-education-atmosphere--course .sava-education-particle--gold{color:var(--sa-ink-a57b34,#a57b34);border-color:var(--sa-line-bfa56966,#bfa56966)}
#superava-app-transition{overflow:hidden}
.superava-app-transition-card{position:relative;z-index:1}
@keyframes sava-education-float{from{transform:translate(calc(-50% - var(--edu-drift)),calc(-50% + 26px)) rotate(-8deg);opacity:0}to{transform:translate(-50%,-50%) rotate(5deg)}}
@media(max-width:600px){.sava-education-atmosphere--transition .sava-education-particle:nth-child(n+25){display:none}.sava-education-particle{width:calc(var(--edu-size)*.75);height:calc(var(--edu-size)*.75)}.sava-education-particle--symbol{padding:6px}.sava-education-atmosphere--course{mask-image:linear-gradient(90deg,#000,transparent 26px,transparent calc(100% - 26px),#000)}.sava-education-atmosphere--course .sava-education-particle:nth-child(n+11){display:none}}
@media(prefers-reduced-motion:reduce){.sava-education-particle{animation:none!important;transform:translate(-50%,-50%)}}
@media print{.sava-education-atmosphere{display:none!important}}

.portal-loading section{position:relative;z-index:1}

/* Rising study objects use composited transforms; the DOM stays bounded. */
.sava-education-atmosphere--transition .sava-education-particle{animation:sava-study-rise 6s linear var(--edu-delay) 2 both}
.sava-education-atmosphere--transition .sava-education-particle--symbol{border-radius:14px;color:#b9eaff;background:#175b812b;box-shadow:none;padding:8px}
.sava-education-atmosphere--transition .sava-education-particle--gold{color:#f4d79a}
.sava-education-atmosphere--navigation{position:fixed;z-index:80;animation:sava-education-navigation 1100ms ease-out both;mask-image:linear-gradient(90deg,#000,transparent 28%,transparent 72%,#000)}
.sava-education-atmosphere--navigation .sava-education-particle{animation:sava-study-arrive 1100ms ease-out both;color:#7bcbe9;border-color:#54afce66;opacity:.6}
.sava-education-atmosphere--navigation .sava-education-particle--symbol{border-radius:12px;background:#12426618}
.sava-education-atmosphere--navigation .sava-education-particle:nth-child(n+25){display:none}
body:has([data-study-loading])>.sava-education-atmosphere--navigation{display:none}
@keyframes sava-study-rise{0%{opacity:0;transform:translate(calc(-50% - var(--edu-drift)),calc(-50% + 110px)) rotate(-12deg)}15%,70%{opacity:.65}100%{opacity:0;transform:translate(calc(-50% + var(--edu-drift)),calc(-50% - 180px)) rotate(15deg)}}
@keyframes sava-study-arrive{from{transform:translate(-50%,calc(-50% + 65px)) rotate(-12deg)}to{transform:translate(calc(-50% + var(--edu-drift)),calc(-50% - 75px)) rotate(12deg)}}
@keyframes sava-education-navigation{0%{opacity:0}15%{opacity:.8}100%{opacity:0;visibility:hidden}}
@media(max-width:600px){.sava-education-atmosphere--navigation .sava-education-particle:nth-child(n+13){display:none}}
@media(prefers-reduced-motion:reduce){.sava-education-atmosphere--navigation{display:none!important}.sava-education-atmosphere--transition .sava-education-particle{animation:none!important;transform:translate(-50%,-50%);opacity:.35}}
#superava-app-transition{position:fixed;inset:0;z-index:2147483646;min-height:100dvh;overflow:auto;opacity:0;visibility:hidden;pointer-events:none;transition:opacity .16s ease,visibility 0s linear .16s}
html[data-superava-app-transition="active"] #superava-app-transition{opacity:1;visibility:visible;transition-delay:0s}
body:has([data-study-loading]) #superava-app-transition{display:none}
#superava-app-transition .sava-education-particle{animation-play-state:paused}
html[data-superava-app-transition="active"] #superava-app-transition .sava-education-particle{animation-play-state:running}
@media(prefers-reduced-motion:reduce){#superava-app-transition{transition:none}}

:root { --sava-motion-accent:#0875d8; --sava-motion-glow:#11aaff; --sava-motion-alt:#7738da; --sava-motion-glass:#ffffffb8; --sava-motion-rise:45vh; }
html[data-theme="dark"] { --sava-motion-accent:#68e3ff; --sava-motion-glass:#071a3cb8; }
html[data-superava-study-tone="class"] { --sava-motion-accent:#7237d7; --sava-motion-glow:#9866ff; --sava-motion-alt:#257adb; }
html[data-superava-study-tone="trail"] { --sava-motion-accent:#078873; --sava-motion-glow:#00d9b3; --sava-motion-alt:#1c8ebe; }
html[data-superava-study-tone="enem"] { --sava-motion-accent:#a26600; --sava-motion-glow:#ffc145; --sava-motion-alt:#b57316; }
html[data-superava-study-tone="lab"] { --sava-motion-accent:#007fa9; --sava-motion-glow:#13cfff; --sava-motion-alt:#0870db; --sava-motion-rise:50vh; }
html[data-superava-study-tone="library"] { --sava-motion-accent:#c32559; --sava-motion-glow:#ff668f; --sava-motion-alt:#cf456e; }
html[data-superava-study-tone="journal"] { --sava-motion-accent:#008776; --sava-motion-glow:#00dbb8; --sava-motion-alt:#299d91; }
html[data-superava-study-tone="audio"] { --sava-motion-accent:#007fae; --sava-motion-glow:#13c9f3; --sava-motion-alt:#3165db; }
html[data-superava-study-tone="arena"] { --sava-motion-accent:#ab1ac5; --sava-motion-glow:#e743ff; --sava-motion-alt:#8838e8; --sava-motion-rise:52vh; }
html:is([data-superava-study-tone="profile"],[data-superava-study-tone="access"],[data-superava-study-tone="panel"]) { --sava-motion-accent:#5363c5; --sava-motion-glow:#909dff; --sava-motion-alt:#2e8ed5; }
html[data-theme="dark"][data-superava-study-tone="class"] { --sava-motion-accent:#bd9dff; --sava-motion-alt:#7dbbff; }
html[data-theme="dark"][data-superava-study-tone="trail"] { --sava-motion-accent:#65efce; --sava-motion-alt:#69cfff; }
html[data-theme="dark"][data-superava-study-tone="enem"] { --sava-motion-accent:#ffda83; --sava-motion-alt:#ffe5b0; }
html[data-theme="dark"][data-superava-study-tone="lab"] { --sava-motion-accent:#64e3ff; --sava-motion-alt:#8dbaff; }
html[data-theme="dark"][data-superava-study-tone="library"] { --sava-motion-accent:#ff9bb8; --sava-motion-alt:#ffbbd1; }
html[data-theme="dark"][data-superava-study-tone="journal"] { --sava-motion-accent:#65efd6; --sava-motion-alt:#8ff5e5; }
html[data-theme="dark"][data-superava-study-tone="audio"] { --sava-motion-accent:#6ce2ff; --sava-motion-alt:#a2c6ff; }
html[data-theme="dark"][data-superava-study-tone="arena"] { --sava-motion-accent:#f49bff; --sava-motion-alt:#d2a4ff; }
html[data-theme="dark"]:is([data-superava-study-tone="profile"],[data-superava-study-tone="access"],[data-superava-study-tone="panel"]) { --sava-motion-accent:#b7c5ff; --sava-motion-alt:#a6e1ff; }
#superava-app-transition { z-index:2147483645; }
#sava-screen-bubbles { position:fixed; inset:0; z-index:2147483646; overflow:hidden; pointer-events:none!important; contain:layout paint; isolation:isolate; }
#sava-screen-bubbles[hidden] { display:none!important; }
#sava-screen-bubbles * { pointer-events:none!important; }
#sava-screen-bubbles .sava-study-bubble { position:absolute; left:var(--bubble-x); top:var(--bubble-y); display:grid; place-items:center; width:var(--bubble-size); height:var(--bubble-size); box-sizing:border-box; padding:calc(var(--bubble-size)*.22); border-radius:50%; border:1.5px solid currentColor; color:var(--sava-motion-accent); background:radial-gradient(circle at 27% 20%,#ffffff99,transparent 48%),var(--sava-motion-glass); box-shadow:inset 0 0 12px color-mix(in srgb,var(--sava-motion-glow) 24%,transparent),0 0 20px color-mix(in srgb,var(--sava-motion-glow) 40%,transparent); opacity:0; }
#sava-screen-bubbles svg { display:block; width:100%; height:100%; overflow:visible; }
#sava-screen-bubbles .sava-study-bubble:nth-child(3n) { color:var(--sava-motion-alt); border-radius:28%; }
#sava-screen-bubbles[data-tone="arena"] .sava-study-bubble { border-radius:28%; }
#sava-screen-bubbles[data-tone="lab"] .sava-study-bubble:nth-child(2n) { border-style:dashed; }
#sava-screen-bubbles[data-tone="audio"] .sava-study-bubble { box-shadow:0 0 0 5px color-mix(in srgb,var(--sava-motion-glow) 12%,transparent),0 0 20px color-mix(in srgb,var(--sava-motion-glow) 40%,transparent); }
#sava-screen-bubbles[data-phase="prepare"] .sava-study-bubble { animation:sava-bubble-prepare 420ms ease-out var(--bubble-delay) both; }
#sava-screen-bubbles[data-phase="depart"] .sava-study-bubble { animation:sava-bubble-depart 720ms cubic-bezier(.2,.65,.25,1) var(--bubble-delay) both; }
#sava-screen-bubbles[data-phase="wait"] .sava-study-bubble { animation:sava-bubble-wait 2100ms ease-in-out var(--bubble-delay) 6 both; }
#sava-screen-bubbles[data-phase="arrive"] .sava-study-bubble { animation:sava-bubble-arrive 980ms cubic-bezier(.18,.65,.3,1) var(--bubble-delay) both; }
html[data-superava-bubble-phase="arrive"] main:not([data-study-loading]) { animation:sava-page-reveal 260ms ease-out both; }
#superava-app-transition[data-study-tone] .study-transition-eyebrow { color:var(--sava-motion-accent); }
#superava-app-transition[data-study-tone] .study-transition-track>span { background:linear-gradient(90deg,var(--sava-motion-accent),var(--sava-motion-alt)); }
#superava-app-transition[data-study-tone="arena"] .study-transition-art img { animation:sava-study-pop 650ms ease-out both; }
#superava-app-transition[data-study-tone="lab"] .study-transition-art img { animation:sava-study-orbit 650ms ease-out both; }
#superava-app-transition[data-study-tone="trail"] .study-transition-art img { animation:sava-study-path 650ms ease-out both; }
@keyframes sava-page-reveal { from{opacity:.88} to{opacity:1} }
@keyframes sava-study-pop { from{opacity:0;transform:scale(.86) rotate(-5deg)} 70%{transform:scale(1.025) rotate(1deg)} to{opacity:1;transform:none} }
@keyframes sava-study-orbit { from{opacity:0;transform:translate(-14px,8px) rotate(-6deg)} to{opacity:1;transform:none} }
@keyframes sava-study-path { from{opacity:0;transform:translate(-24px,12px)} to{opacity:1;transform:none} }
@keyframes sava-bubble-prepare { 0%{opacity:0;transform:translate3d(-50%,35px,0) scale(.5)} 45%{opacity:.32} 100%{opacity:0;transform:translate3d(-50%,-6px,0) scale(.8)} }
@keyframes sava-bubble-depart { 0%{opacity:0;transform:translate3d(-50%,65px,0) scale(.5)} 22%,65%{opacity:.78} 100%{opacity:0;transform:translate3d(calc(-50% + var(--bubble-drift)),calc(var(--sava-motion-rise)*-.7),0) rotate(var(--bubble-turn)) scale(1.04)} }
@keyframes sava-bubble-wait { 0%{opacity:0;transform:translate3d(-50%,60px,0) scale(.7)} 25%,60%{opacity:.55} 100%{opacity:0;transform:translate3d(calc(-50% + var(--bubble-drift)),calc(var(--sava-motion-rise)*-.8),0) rotate(var(--bubble-turn)) scale(1)} }
@keyframes sava-bubble-arrive { 0%{opacity:.4;transform:translate3d(-50%,60px,0) scale(.58)} 15%,45%{opacity:.86} 100%{opacity:0;transform:translate3d(calc(-50% + var(--bubble-drift)),calc(var(--sava-motion-rise)*-1),0) rotate(var(--bubble-turn)) scale(1.08)} }
@media(max-width:767px){#sava-screen-bubbles .sava-study-bubble:nth-child(n+13){display:none}#sava-screen-bubbles .sava-study-bubble{width:calc(var(--bubble-size)*.76);height:calc(var(--bubble-size)*.76);padding:calc(var(--bubble-size)*.16)}html{--sava-motion-rise:42vh}}
@media(prefers-reduced-motion:reduce){#sava-screen-bubbles{display:none!important}html[data-superava-bubble-phase="arrive"] main:not([data-study-loading]),#superava-app-transition[data-study-tone] .study-transition-art img{animation:none!important}}
@media print{#sava-screen-bubbles,#superava-app-transition{display:none!important}}
