/* Three visual editions for Building With Intelligence.
   Content, semantics, accessibility, and print behavior remain shared. */

.edition-switcher{display:flex;align-items:center;gap:.35rem;margin-right:.25rem;font:700 11px/1 var(--sans);letter-spacing:.04em}
.edition-switcher a{padding:.42rem .58rem;border:1px solid var(--line);border-radius:999px;color:var(--muted);text-decoration:none;white-space:nowrap;transition:transform .18s ease,background .18s ease,color .18s ease}
.edition-switcher a:hover{transform:translateY(-1px);color:var(--ink)}
.edition-switcher a[aria-current="page"]{background:var(--accent);border-color:var(--accent);color:var(--paper)}
.cover>*{position:relative;z-index:2}

/* COMIC / ANIME EDITION */
body.theme-anime{--paper:#fff9f2;--ink:#15152b;--muted:#5d5c70;--line:#25233d;--accent:#e34f68;--accent-soft:#ffe0df;--panel:#fffdf8;--warn:#d45b2a;background-color:var(--paper)}
:root[data-theme="dark"] body.theme-anime{--paper:#101326;--ink:#f9f1e8;--muted:#b8b8cc;--line:#4c5271;--accent:#ff7184;--accent-soft:#2a2034;--panel:#171b31;--warn:#ffad63}
.theme-anime .progress i{background:linear-gradient(90deg,#41d9ff,var(--accent),#ffb24c)}
.theme-anime .topbar{border-bottom:2px solid var(--line);box-shadow:0 3px 0 color-mix(in srgb,var(--accent) 45%,transparent)}
.theme-anime aside{border-right:2px solid var(--line);background-image:radial-gradient(circle at 10px 10px,color-mix(in srgb,var(--ink) 8%,transparent) 1px,transparent 1.5px);background-size:18px 18px}
.theme-anime .cover{max-width:none;min-height:calc(100vh - 50px);display:grid;align-content:center;padding-right:48%;background:#07162e url("assets/themes/anime-hero.webp") center/cover no-repeat;color:#fff;isolation:isolate;overflow:hidden}
.theme-anime .cover::before{content:"";position:absolute;inset:0;z-index:0;background:linear-gradient(90deg,rgba(5,15,37,.96) 0%,rgba(5,15,37,.9) 30%,rgba(5,15,37,.25) 64%,rgba(5,15,37,.05))}
.theme-anime .cover::after{content:"";position:absolute;inset:auto auto 7% 3%;z-index:1;width:16rem;height:16rem;border-radius:50%;opacity:.24;background:radial-gradient(circle,#41d9ff 1.3px,transparent 1.6px);background-size:10px 10px;animation:anime-drift 12s ease-in-out infinite}
.theme-anime .cover h1{max-width:8ch;font-style:italic;text-transform:uppercase;letter-spacing:-.055em;text-shadow:4px 4px 0 #e34f68,8px 8px 0 rgba(65,217,255,.45)}
.theme-anime .cover .subtitle,.theme-anime .cover .edition{color:#eef9ff}.theme-anime .cover .eyebrow{color:#64e5ff}
.theme-anime .part-page{background:linear-gradient(135deg,#171832,#282547 55%,#e34f68 180%);position:relative;overflow:hidden}
.theme-anime .part-page::after{content:"";position:absolute;inset:0;pointer-events:none;background:repeating-linear-gradient(-12deg,transparent 0 16px,rgba(255,255,255,.035) 17px 18px)}
.theme-anime .chapter-header{position:relative;padding:1.4rem 1.5rem;border:2px solid var(--line);box-shadow:8px 8px 0 color-mix(in srgb,var(--accent) 65%,var(--line));background:var(--panel);transform:rotate(-.15deg)}
.theme-anime .chapter-header::after{content:"";position:absolute;right:1rem;top:1rem;width:3.2rem;height:3.2rem;background:radial-gradient(circle,var(--accent) 1px,transparent 1.4px);background-size:7px 7px;opacity:.38}
.theme-anime h2,.theme-anime h3,.theme-anime h4{font-family:var(--sans)}
.theme-anime .callout,.theme-anime .worked,.theme-anime .chapter-lab,.theme-anime .lab,.theme-anime .project-card,.theme-anime .kind-card{border:2px solid var(--line);box-shadow:5px 5px 0 color-mix(in srgb,var(--line) 22%,transparent)}
.theme-anime .callout{border-left:7px solid var(--accent)}
.theme-anime details{border:2px solid var(--line);border-radius:0}
.theme-anime .study-button,.theme-anime .quiz-question button{border:2px solid var(--line);box-shadow:3px 3px 0 var(--line);text-transform:uppercase;font-weight:900}
.theme-anime .study-button{color:var(--ink)}.theme-anime .study-button[aria-pressed="true"],.theme-anime .quiz-question button{background:var(--ink);color:var(--paper)}
.theme-anime .project-card,.theme-anime .kind-card{transition:transform .2s ease,box-shadow .2s ease}
.theme-anime .project-card:hover,.theme-anime .kind-card:hover{transform:translate(-2px,-2px) rotate(-.2deg);box-shadow:9px 9px 0 color-mix(in srgb,var(--accent) 70%,var(--line))}
.theme-anime .intelligence-map{background-color:#121a31;background-image:linear-gradient(rgba(65,217,255,.08) 1px,transparent 1px),linear-gradient(90deg,rgba(65,217,255,.08) 1px,transparent 1px);background-size:24px 24px}
@keyframes anime-drift{50%{transform:translate(18px,-12px) rotate(8deg)}}

/* ANIMAL COMPANION EDITION */
body.theme-animals{--paper:#f8f2df;--ink:#263327;--muted:#657064;--line:#b7b398;--accent:#3e7652;--accent-soft:#e0ead5;--panel:#fffaf0;--warn:#a85532;background-color:var(--paper);background-image:radial-gradient(circle at 15% 12%,rgba(104,139,91,.08),transparent 24%),radial-gradient(circle at 90% 70%,rgba(194,129,72,.08),transparent 28%)}
:root[data-theme="dark"] body.theme-animals{--paper:#18231c;--ink:#f4eddc;--muted:#b6bda9;--line:#566752;--accent:#8ec38d;--accent-soft:#263b2d;--panel:#202c23;--warn:#efaa7a}
.theme-animals .progress i{background:linear-gradient(90deg,#6f9b65,#d68a4c)}
.theme-animals .topbar,.theme-animals aside{background-color:color-mix(in srgb,var(--paper) 90%,transparent);backdrop-filter:blur(14px)}
.theme-animals aside{border-right:1px solid var(--line);box-shadow:8px 0 30px rgba(59,75,56,.08)}
.theme-animals .cover{max-width:none;min-height:calc(100vh - 50px);display:grid;align-content:center;padding-right:49%;background:#f8f2df url("assets/themes/animals-hero.webp") center/cover no-repeat;color:#263327;isolation:isolate;overflow:hidden}
.theme-animals .cover::before{content:"";position:absolute;inset:0;z-index:0;background:linear-gradient(90deg,rgba(255,250,236,.97) 0%,rgba(255,250,236,.91) 33%,rgba(255,250,236,.28) 64%,rgba(255,250,236,.02))}
.theme-animals .cover::after{content:"";position:absolute;left:7%;bottom:8%;z-index:1;width:4.8rem;height:7.5rem;border:2px solid rgba(62,118,82,.28);border-radius:100% 0 100% 0;transform:rotate(-32deg);animation:leaf-sway 7s ease-in-out infinite;transform-origin:bottom right}
.theme-animals .cover h1{max-width:9ch;color:#263327;letter-spacing:-.055em}.theme-animals .cover .subtitle{color:#485447}.theme-animals .cover .edition{color:#647063}.theme-animals .cover .eyebrow{color:#3e7652}
.theme-animals .part-page{background:linear-gradient(145deg,#294333,#426349);border-radius:0 0 48% 0}
.theme-animals .chapter{position:relative}.theme-animals .chapter-header{padding:1.5rem 1.65rem;border:1px solid var(--line);border-radius:2rem .7rem 2rem .7rem;background:color-mix(in srgb,var(--panel) 94%,transparent);box-shadow:0 12px 28px rgba(50,70,46,.08)}
.theme-animals h2,.theme-animals h3{color:color-mix(in srgb,var(--ink) 88%,var(--accent))}
.theme-animals h3::before{content:"";display:inline-block;width:.62rem;height:.9rem;margin-right:.48rem;border-radius:100% 0 100% 0;background:var(--accent);transform:rotate(-28deg);opacity:.72}
.theme-animals .callout,.theme-animals .worked,.theme-animals .chapter-lab,.theme-animals .lab,.theme-animals .project-card,.theme-animals .kind-card{border:1px solid var(--line);border-radius:1.2rem .45rem 1.2rem .45rem;background:color-mix(in srgb,var(--panel) 96%,transparent);box-shadow:0 8px 20px rgba(50,70,46,.06)}
.theme-animals .callout{border-left:6px solid #c77a43}.theme-animals details{border-radius:1rem;background:color-mix(in srgb,var(--panel) 90%,transparent)}
.theme-animals .study-button,.theme-animals .quiz-question button{border-radius:999px;background:var(--accent)}
.theme-animals .project-card,.theme-animals .kind-card{transition:transform .28s ease,box-shadow .28s ease}
.theme-animals .project-card:hover,.theme-animals .kind-card:hover{transform:translateY(-4px);box-shadow:0 15px 30px rgba(50,70,46,.14)}
.theme-animals .course-meter,.theme-animals .lab-bar{border-radius:999px;overflow:hidden}.theme-animals .intelligence-map{border-radius:1.5rem;background-color:#dfe8d6}
@keyframes leaf-sway{50%{transform:rotate(-24deg) translateY(-4px)}}

/* MINIMAL GLASS EDITION */
html.theme-glass-root{overflow-x:clip}
body.theme-glass{--paper:#edf2f8;--ink:#121722;--muted:#5e6877;--line:rgba(79,95,119,.22);--accent:#1877f2;--accent-soft:rgba(211,230,255,.72);--panel:rgba(255,255,255,.66);--warn:#ad5528;font-family:-apple-system,BlinkMacSystemFont,"SF Pro Text","Helvetica Neue",sans-serif;background:radial-gradient(circle at 82% 8%,rgba(116,164,255,.3),transparent 26rem),radial-gradient(circle at 5% 48%,rgba(171,131,255,.18),transparent 28rem),#edf2f8;background-attachment:fixed}
:root[data-theme="dark"] body.theme-glass{--paper:#0b1019;--ink:#f4f7fb;--muted:#a8b1c0;--line:rgba(204,220,255,.18);--accent:#68a8ff;--accent-soft:rgba(37,73,125,.5);--panel:rgba(20,28,42,.68);--warn:#ffa777;background:radial-gradient(circle at 82% 8%,rgba(52,105,200,.32),transparent 26rem),radial-gradient(circle at 5% 48%,rgba(115,78,177,.22),transparent 28rem),#0b1019;background-attachment:fixed}
.theme-glass h1,.theme-glass h2,.theme-glass h3,.theme-glass h4,.theme-glass .subtitle{font-family:-apple-system,BlinkMacSystemFont,"SF Pro Display","Helvetica Neue",sans-serif}
.theme-glass .progress{height:2px;background:transparent}.theme-glass .progress i{background:linear-gradient(90deg,#1387ff,#8e6cff)}
.theme-glass .topbar{margin:.65rem .75rem 0;border:1px solid rgba(255,255,255,.5);border-radius:1rem;background:color-mix(in srgb,var(--panel) 78%,transparent);box-shadow:0 14px 36px rgba(24,46,81,.1);backdrop-filter:blur(28px) saturate(145%)}
.theme-glass aside{top:64px;margin:1rem 0 1rem 1rem;height:calc(100vh - 80px);border:1px solid rgba(255,255,255,.48);border-radius:1.5rem;background:color-mix(in srgb,var(--panel) 72%,transparent);box-shadow:0 18px 50px rgba(24,46,81,.1);backdrop-filter:blur(30px) saturate(145%)}
.theme-glass .cover{max-width:none;min-height:calc(100vh - 64px);display:grid;align-content:center;overflow:hidden;isolation:isolate}
.theme-glass .cover::before,.theme-glass .cover::after{content:"";position:absolute;z-index:0;border:1px solid rgba(255,255,255,.65);background:linear-gradient(145deg,rgba(255,255,255,.55),rgba(255,255,255,.08));box-shadow:inset 0 1px 1px rgba(255,255,255,.7),0 30px 80px rgba(60,95,150,.16);backdrop-filter:blur(18px);animation:glass-float 12s ease-in-out infinite}
.theme-glass .cover::before{width:25rem;height:25rem;right:-5rem;top:10%;border-radius:42% 58% 64% 36%/48% 37% 63% 52%;transform:rotate(18deg)}
.theme-glass .cover::after{width:14rem;height:14rem;right:24%;bottom:5%;border-radius:50%;animation-delay:-5s}
.theme-glass .cover h1{max-width:12ch;font-weight:750;letter-spacing:-.065em;background:linear-gradient(125deg,var(--ink) 15%,#337dd7 80%);-webkit-background-clip:text;background-clip:text;color:transparent}
.theme-glass .part-page{margin:2rem;border-radius:2rem;min-height:calc(70vh - 2rem);background:linear-gradient(145deg,#161d2a,#31548c);box-shadow:0 30px 80px rgba(24,46,81,.2)}
.theme-glass .chapter-header,.theme-glass .callout,.theme-glass .worked,.theme-glass .chapter-lab,.theme-glass .lab,.theme-glass .project-card,.theme-glass .kind-card,.theme-glass details,.theme-glass table{border:1px solid rgba(255,255,255,.55);border-radius:1.45rem;background:color-mix(in srgb,var(--panel) 88%,transparent);box-shadow:inset 0 1px 0 rgba(255,255,255,.55),0 18px 46px rgba(30,63,108,.08);backdrop-filter:blur(22px) saturate(135%)}
.theme-glass .chapter-header{padding:1.75rem 2rem;margin-bottom:3rem}.theme-glass .chapter-header h2{letter-spacing:-.045em}
.theme-glass .callout{border-left:1px solid rgba(255,255,255,.65)}.theme-glass .callout::before{content:"";display:block;width:2.2rem;height:.2rem;margin-bottom:.7rem;border-radius:99px;background:linear-gradient(90deg,var(--accent),#9b73ff)}
.theme-glass .study-button,.theme-glass .quiz-question button{border:0;border-radius:999px;background:linear-gradient(135deg,#0667ca,#4052c8);color:#fff;box-shadow:0 8px 22px rgba(34,111,224,.22)}
.theme-glass .project-card,.theme-glass .kind-card{transition:transform .3s ease,box-shadow .3s ease}.theme-glass .project-card:hover,.theme-glass .kind-card:hover{transform:translateY(-5px) scale(1.01);box-shadow:0 25px 60px rgba(30,63,108,.16)}
.theme-glass .intelligence-map{border-radius:2rem;background:linear-gradient(145deg,rgba(13,25,47,.92),rgba(33,63,104,.84));box-shadow:0 25px 60px rgba(30,63,108,.16)}
.theme-glass .course-meter{border-radius:99px;overflow:hidden}.theme-glass .course-meter i{background:linear-gradient(90deg,#1684ff,#9b73ff)}
@keyframes glass-float{50%{transform:translateY(-18px) rotate(12deg) scale(1.03)}}

/* PROGRESSION QUEST EDITION */
html.theme-levelup-root{overflow-x:clip}
body.theme-levelup{--paper:#edf2ff;--ink:#11182d;--muted:#5d6880;--line:#9cadd1;--accent:#6546df;--accent-soft:#e2dcff;--panel:#f8f9ff;--warn:#b04d73;font-family:Inter,ui-sans-serif,system-ui,-apple-system,sans-serif;background:radial-gradient(circle at 85% 10%,rgba(91,65,213,.18),transparent 25rem),#edf2ff}
:root[data-theme="dark"] body.theme-levelup{--paper:#070914;--ink:#f1f3ff;--muted:#aab2d0;--line:#333d68;--accent:#8b72ff;--accent-soft:#211b49;--panel:#101426;--warn:#ff84b2;background:radial-gradient(circle at 80% 8%,rgba(86,53,205,.18),transparent 30rem),radial-gradient(circle at 10% 70%,rgba(31,113,180,.1),transparent 28rem),#070914;background-attachment:fixed}
.theme-levelup h1,.theme-levelup h2,.theme-levelup h3,.theme-levelup h4,.theme-levelup .subtitle{font-family:Inter,ui-sans-serif,system-ui,-apple-system,sans-serif}
.theme-levelup .progress{height:3px;background:#11152a}.theme-levelup .progress i{background:linear-gradient(90deg,#4bbfff,#8d70ff,#ff6fc8);box-shadow:0 0 14px #896eff}
.theme-levelup .topbar{border-bottom:1px solid #49527e;background:rgba(6,8,20,.88);color:#eef1ff;box-shadow:0 8px 28px rgba(0,0,0,.28);backdrop-filter:blur(18px)}
.theme-levelup .topbar button,.theme-levelup .edition-switcher a{border-color:#49527e;background:#11162d;color:#c8cdef}.theme-levelup .edition-switcher a[aria-current="page"]{background:linear-gradient(135deg,#6546df,#3e96e8);border-color:#a18cff;color:#fff;box-shadow:0 0 18px rgba(128,99,255,.4)}
.theme-levelup aside{border-right:1px solid #303860;background:rgba(8,11,25,.95);color:#e9ecff;box-shadow:12px 0 40px rgba(0,0,0,.22)}
.theme-levelup aside input{border-color:#39436d;background:#0f142a;color:#eef1ff}.theme-levelup .toc a{color:#b8c0df}.theme-levelup .toc a:hover,.theme-levelup .toc a[aria-current="location"]{color:#fff;background:#1b2040}.theme-levelup .toc .part-link{color:#8c77ff}
.theme-levelup .cover{max-width:none;min-height:calc(100vh - 50px);display:grid;align-content:center;padding-right:48%;background:#030612 url("assets/themes/level-up-hero.webp") center/cover no-repeat;color:#fff;isolation:isolate;overflow:hidden}
.theme-levelup .cover::before{content:"";position:absolute;inset:0;z-index:0;background:linear-gradient(90deg,rgba(2,4,14,.98) 0%,rgba(2,4,14,.9) 37%,rgba(2,4,14,.25) 67%,rgba(2,4,14,.02))}
.theme-levelup .cover::after{content:"";position:absolute;left:4%;bottom:8%;z-index:1;width:20rem;height:20rem;border:1px solid rgba(128,105,255,.38);transform:rotate(45deg);box-shadow:0 0 55px rgba(91,71,222,.2),inset 0 0 55px rgba(91,71,222,.12);animation:rune-pulse 6s ease-in-out infinite}
.theme-levelup .cover h1{max-width:9ch;text-transform:uppercase;font-style:italic;letter-spacing:-.065em;background:linear-gradient(180deg,#fff 10%,#a8caff 58%,#8066ef);-webkit-background-clip:text;background-clip:text;color:transparent;filter:drop-shadow(0 0 20px rgba(99,124,255,.28))}
.theme-levelup .cover .subtitle,.theme-levelup .cover .edition{color:#c9d0ef}.theme-levelup .cover .eyebrow{color:#8ecfff}
.theme-levelup .part-page{background:linear-gradient(145deg,#090d21,#181a3f 58%,#352467);position:relative;overflow:hidden}
.theme-levelup .part-page::before{content:"ZONE UNLOCKED";position:absolute;right:5%;top:10%;font:900 clamp(2rem,7vw,6rem)/1 sans-serif;letter-spacing:.08em;color:rgba(146,128,255,.06);transform:rotate(-8deg)}
.theme-levelup .chapter-header{position:relative;padding:1.7rem 2rem;border:1px solid #3d4776;background:linear-gradient(145deg,color-mix(in srgb,var(--panel) 94%,transparent),color-mix(in srgb,var(--accent-soft) 30%,var(--panel)));box-shadow:0 18px 55px rgba(0,0,0,.16),inset 3px 0 0 var(--accent);clip-path:polygon(0 0,calc(100% - 1.25rem) 0,100% 1.25rem,100% 100%,1.25rem 100%,0 calc(100% - 1.25rem))}
.theme-levelup .chapter-header::before{content:"ACTIVE QUEST";position:absolute;right:1.6rem;top:1.35rem;font:800 10px/1 sans-serif;letter-spacing:.14em;color:var(--accent)}
.theme-levelup .callout,.theme-levelup .worked,.theme-levelup .chapter-lab,.theme-levelup .lab,.theme-levelup .project-card,.theme-levelup .kind-card,.theme-levelup details{border:1px solid var(--line);background:linear-gradient(145deg,color-mix(in srgb,var(--panel) 96%,transparent),color-mix(in srgb,var(--accent-soft) 18%,var(--panel)));box-shadow:0 14px 38px rgba(0,0,0,.1)}
.theme-levelup .callout{border-left:4px solid var(--accent)}.theme-levelup .chapter-lab,.theme-levelup .lab{position:relative;overflow:hidden}.theme-levelup .chapter-lab::before,.theme-levelup .lab::before{content:"";position:absolute;inset:0 auto 0 0;width:3px;background:linear-gradient(var(--accent),#4ebaff);box-shadow:0 0 14px var(--accent)}
.theme-levelup .study-button,.theme-levelup .quiz-question button,.theme-levelup .boss-button{border:1px solid #8e7aff;border-radius:.3rem;background:linear-gradient(135deg,#593bd1,#337fd1);color:#fff;box-shadow:0 8px 24px rgba(76,56,193,.24);font-weight:800;text-transform:uppercase;letter-spacing:.04em}
.theme-levelup .intelligence-map{background-color:#0b1025;background-image:linear-gradient(rgba(111,98,225,.09) 1px,transparent 1px),linear-gradient(90deg,rgba(111,98,225,.09) 1px,transparent 1px);background-size:24px 24px}
.theme-levelup .project-card{position:relative;transition:transform .22s ease,box-shadow .22s ease}.theme-levelup .project-card::before{content:"BOSS QUEST";display:block;margin-bottom:.8rem;font:900 10px/1 sans-serif;letter-spacing:.15em;color:#9e8aff}.theme-levelup .project-card:hover{transform:translateY(-4px);box-shadow:0 20px 50px rgba(80,57,190,.2)}
.theme-levelup .game-cleared{border-color:#52d5b1!important;box-shadow:0 0 0 1px rgba(82,213,177,.18),0 16px 45px rgba(45,175,147,.12)!important}.theme-levelup .game-cleared::before{background:#52d5b1}
.game-hud{margin:1rem 0 1.2rem;padding:1rem;border:1px solid #48558b;background:linear-gradient(145deg,#111731,#17133c);clip-path:polygon(0 0,calc(100% - .7rem) 0,100% .7rem,100% 100%,.7rem 100%,0 calc(100% - .7rem));color:#eef1ff}.game-hud h2{margin:.15rem 0 .75rem;font-size:1.2rem}.game-kicker{margin:0;color:#8fcaff;font:800 10px/1 sans-serif;letter-spacing:.15em;text-transform:uppercase}.game-level{display:flex;align-items:end;justify-content:space-between;gap:.5rem;margin:.5rem 0}.game-level span{color:#a99cff;font:800 12px/1 sans-serif;text-transform:uppercase}.game-level strong{font-size:.9rem;text-align:right}.game-xp-track{height:.55rem;border:1px solid #536092;background:#070a17;overflow:hidden}.game-xp-track i{display:block;width:0;height:100%;background:linear-gradient(90deg,#3db8ff,#8b6dff,#ff71c6);box-shadow:0 0 14px #755cff;transition:width .45s ease}.game-xp,.game-stats{margin:.55rem 0;color:#bbc2df;font:700 11px/1.5 sans-serif}.game-badges{display:grid;gap:.3rem;margin:.7rem 0}.game-badges span{font:700 10px/1.3 sans-serif}.game-badges .earned{color:#66e0bd}.game-badges .locked{color:#656d91}.game-hud details{padding:.65rem;border-color:#414b78;background:#0b1023}.game-hud details p{font-size:11px;color:#aeb6d4}.game-mini{padding:.35rem .55rem;border:1px solid #4a5689;background:#0c1126;color:#99d5ff;font:800 10px/1 sans-serif;letter-spacing:.04em;white-space:nowrap}.quest-reward{margin:.2rem 0 .8rem;color:var(--accent);font:800 10px/1.2 sans-serif;letter-spacing:.1em;text-transform:uppercase}.lab-quest-marker{float:right;margin:.1rem 0 0 1rem;padding:.3rem .45rem;border:1px solid var(--line);color:var(--accent);font:800 10px/1 sans-serif;letter-spacing:.05em;text-transform:uppercase}.boss-button{width:100%;margin-top:1rem;padding:.7rem;cursor:pointer}.boss-button[aria-pressed="true"]{border-color:#52d5b1;background:#173e38;color:#8ce8d0}
.level-toast{position:fixed;z-index:100;left:50%;top:14%;min-width:min(28rem,calc(100vw - 2rem));padding:1rem 1.4rem;border:1px solid #8f7aff;background:rgba(10,12,31,.94);color:#fff;box-shadow:0 0 0 1px rgba(142,122,255,.25),0 0 55px rgba(102,77,230,.45);text-align:center;clip-path:polygon(0 0,calc(100% - 1rem) 0,100% 1rem,100% 100%,1rem 100%,0 calc(100% - 1rem));opacity:0;transform:translate(-50%,-1rem) scale(.96);pointer-events:none}.level-toast span{display:block;color:#8fcaff;font:900 11px/1 sans-serif;letter-spacing:.2em}.level-toast strong{display:block;margin-top:.45rem;font-size:1.05rem}.level-toast.show{animation:quest-toast 2.4s ease both}.level-toast.is-level.show{animation:level-reveal 3.8s ease both}.level-toast.is-level{border-color:#e1d9ff;background:radial-gradient(circle at 50%,rgba(75,54,184,.96),rgba(8,10,28,.98));box-shadow:0 0 80px rgba(112,88,255,.72)}
@keyframes rune-pulse{50%{opacity:.45;transform:rotate(52deg) scale(1.06)}}
@keyframes quest-toast{0%{opacity:0;transform:translate(-50%,-1rem) scale(.96)}12%,78%{opacity:1;transform:translate(-50%,0) scale(1)}100%{opacity:0;transform:translate(-50%,-.5rem) scale(.98)}}
@keyframes level-reveal{0%{opacity:0;transform:translate(-50%,1rem) scale(.78)}12%{opacity:1;transform:translate(-50%,0) scale(1.05)}20%,82%{opacity:1;transform:translate(-50%,0) scale(1)}100%{opacity:0;transform:translate(-50%,-1rem) scale(.96)}}

@media(max-width:1040px){.edition-switcher{gap:.2rem}.edition-switcher a{font-size:0;padding:.48rem}.edition-switcher a::first-letter{font-size:11px}.theme-anime .cover,.theme-animals .cover,.theme-levelup .cover{padding-right:38%}.theme-levelup .game-mini{display:none}}
@media(max-width:880px){.edition-switcher{margin-left:auto}.edition-switcher a{font-size:10px;padding:.4rem .5rem}.edition-switcher a::first-letter{font-size:inherit}.theme-anime .cover,.theme-animals .cover,.theme-levelup .cover{min-height:90vh;padding:4rem 1.25rem 44vh;background-position:68% center}.theme-anime .cover h1{max-width:none;font-size:clamp(2.1rem,11vw,3rem)}.theme-levelup .cover h1{max-width:none;font-size:clamp(2.15rem,11.5vw,3.1rem)}.theme-anime .cover::before{background:linear-gradient(180deg,rgba(5,15,37,.96) 0%,rgba(5,15,37,.83) 45%,rgba(5,15,37,.08) 75%)}.theme-levelup .cover::before{background:linear-gradient(180deg,rgba(2,4,14,.98) 0%,rgba(2,4,14,.86) 45%,rgba(2,4,14,.1) 76%)}.theme-animals .cover::before{background:linear-gradient(180deg,rgba(255,250,236,.97) 0%,rgba(255,250,236,.86) 43%,rgba(255,250,236,.05) 73%)}.theme-animals .cover .edition{padding:.75rem .85rem;border:1px solid rgba(62,118,82,.18);border-radius:.8rem;background:rgba(255,250,236,.86);backdrop-filter:blur(10px);color:#465445}.theme-glass aside{top:49px;margin:0;height:calc(100vh - 49px);border-radius:0}.theme-glass .topbar{margin:0;border-radius:0}.theme-glass .part-page{margin:0;border-radius:0}.theme-anime .chapter-header,.theme-animals .chapter-header,.theme-glass .chapter-header,.theme-levelup .chapter-header{padding:1.25rem}.theme-levelup .chapter-header::before{position:static;display:block;margin-bottom:.6rem}.level-toast{top:10%}}
@media(max-width:520px){.edition-switcher a{font-size:0;width:1.9rem;height:1.9rem;padding:0;display:grid;place-items:center}.edition-switcher a::before{font-size:11px}.edition-switcher a[href="anime.html"]::before{content:"A"}.edition-switcher a[href="animals.html"]::before{content:"N"}.edition-switcher a[href="glass.html"]::before{content:"G"}.edition-switcher a[href="level-up.html"]::before{content:"Q"}}
@media(max-width:360px){.topbar{gap:.3rem;padding:.5rem}.topbar #progressText{display:none}.edition-switcher{gap:.16rem}.edition-switcher a{width:1.7rem;height:1.7rem}.topbar button{padding:.4rem .58rem}}
@media(prefers-reduced-motion:reduce){.theme-anime .cover::after,.theme-animals .cover::after,.theme-glass .cover::before,.theme-glass .cover::after,.theme-levelup .cover::after,.level-toast.show{animation:none!important}.level-toast.show{opacity:1;transform:translate(-50%,0)}.theme-anime .project-card,.theme-anime .kind-card,.theme-animals .project-card,.theme-animals .kind-card,.theme-glass .project-card,.theme-glass .kind-card,.theme-levelup .project-card,.game-xp-track i{transition:none!important}}
@media print{body.theme-anime,body.theme-animals,body.theme-glass{--paper:#fff;--ink:#111;--muted:#444;--line:#bbb;--accent:#185f62;--accent-soft:#eef5f3;--panel:#fff;background:#fff!important;font-family:Georgia,"Times New Roman",serif}.edition-switcher{display:none!important}.theme-anime .cover,.theme-animals .cover,.theme-glass .cover{background:#fff!important;color:#111!important;padding-right:1.4cm}.theme-anime .cover::before,.theme-anime .cover::after,.theme-animals .cover::before,.theme-animals .cover::after,.theme-glass .cover::before,.theme-glass .cover::after,.theme-anime .chapter-header::after{display:none!important}.theme-anime .cover h1,.theme-anime .cover .subtitle,.theme-anime .cover .edition,.theme-anime .cover .eyebrow,.theme-animals .cover h1,.theme-animals .cover .subtitle,.theme-animals .cover .edition,.theme-animals .cover .eyebrow,.theme-glass .cover h1{color:#111!important;text-shadow:none;background:none;-webkit-text-fill-color:#111}.theme-anime .chapter-header,.theme-anime .callout,.theme-anime .worked,.theme-anime .chapter-lab,.theme-anime .lab,.theme-anime .project-card,.theme-anime .kind-card,.theme-animals .chapter-header,.theme-animals .callout,.theme-animals .worked,.theme-animals .chapter-lab,.theme-animals .lab,.theme-animals .project-card,.theme-animals .kind-card,.theme-glass .chapter-header,.theme-glass .callout,.theme-glass .worked,.theme-glass .chapter-lab,.theme-glass .lab,.theme-glass .project-card,.theme-glass .kind-card{box-shadow:none;transform:none;border-color:#bbb;background:#fff;backdrop-filter:none}.theme-animals h3::before,.theme-glass .callout::before{display:none}.theme-anime .part-page,.theme-animals .part-page,.theme-glass .part-page{margin:0;border-radius:0;background:none;color:#000;box-shadow:none}}
@media print{body.theme-levelup{--paper:#fff;--ink:#111;--muted:#444;--line:#bbb;--accent:#185f62;--accent-soft:#eef5f3;--panel:#fff;background:#fff!important;color:#111;font-family:Georgia,"Times New Roman",serif}.theme-levelup .cover{background:#fff!important;color:#111!important;padding-right:1.4cm}.theme-levelup .cover::before,.theme-levelup .cover::after,.theme-levelup .chapter-header::before,.theme-levelup .part-page::before,.game-hud,.game-mini,.level-toast,.quest-reward,.lab-quest-marker,.boss-button{display:none!important}.theme-levelup .cover h1,.theme-levelup .cover .subtitle,.theme-levelup .cover .edition,.theme-levelup .cover .eyebrow{color:#111!important;background:none;-webkit-text-fill-color:#111;filter:none}.theme-levelup .chapter-header,.theme-levelup .callout,.theme-levelup .worked,.theme-levelup .chapter-lab,.theme-levelup .lab,.theme-levelup .project-card,.theme-levelup .kind-card{box-shadow:none;transform:none;clip-path:none;border-color:#bbb;background:#fff}.theme-levelup .part-page{background:none;color:#000}}
