/* Item forms and the final node use the ordinary book seals and parchment trial styles. */
.mastery-legacy{margin:0 0 14px;color:inherit}
.mastery-legacy-branches{display:block;width:100%;height:40px;overflow:visible;fill:none;stroke:#ac9670;stroke-width:1.2;stroke-dasharray:5 4}
#knowledge-root .mastery-legacy .mastery-item-final{width:160px;max-width:100%;margin:0 auto;padding:7px 4px}
.mastery-legacy .mastery-item-final>strong{min-height:0}
#knowledge-root .mastery-heading{display:grid;justify-items:center;align-items:center;gap:7px;padding:3px 0 14px;text-align:center}
#knowledge-root .mastery-heading>span{line-height:1.2}
#knowledge-root .mastery-heading>small{max-width:100%;box-sizing:border-box;font-size:11px;line-height:17px;padding:3px 11px;background:#e0c89226;border-color:#b79b655e;text-align:center}
#knowledge-root .mastery-seal>.mastery-question{position:absolute;inset:0;display:grid;place-items:center;width:auto;height:auto;min-width:0;padding:0;border:0;border-radius:50%;background:none;box-shadow:none;font:700 29px/1 Interface,sans-serif;color:#9b875d;transform:none}
#knowledge-root .mastery-node-lock{position:absolute;right:-5px;bottom:-5px;width:26px;height:32px;padding:0;border:0;border-radius:0;background:none;box-shadow:none;filter:drop-shadow(0 1px 1px #684e2e35)}
#knowledge-root .mastery-node-lock>img{display:block;width:100%;height:100%;object-fit:contain}
#knowledge-root .page-lock-seal>img{width:72px;height:86px;object-fit:contain}
#knowledge-root .mastery-branches{height:34px;stroke:#ad8f536e;stroke-width:1.4;stroke-linecap:round;stroke-linejoin:round}
#knowledge-root .mastery-branches .chosen{stroke:#73875b;stroke-width:1.6;stroke-dasharray:5 7;animation:mastery-ink-flow-20261124 9s linear infinite}
#knowledge-root .mastery-stems{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));justify-items:center;height:18px;gap:7px;padding-inline:4px}
#knowledge-root .mastery-stems>i{width:1.5px;height:18px;border-radius:2px;background:linear-gradient(#bca06b60,#a68b526e);margin:0}
#knowledge-root .mastery-stems>i:after{display:none}
#knowledge-root .mastery-stems>i.chosen{background:linear-gradient(#8c9d6570,#6b8250a0);animation:mastery-ink-breathe-20261124 4s ease-in-out infinite}
#knowledge-root .mastery-legacy .mastery-item-final{width:190px;padding:8px 6px;min-height:110px}
#knowledge-root .mastery-legacy .mastery-item-final>small{font-size:11px;line-height:16px;white-space:nowrap}
.mastery-legacy-branches{stroke:#ad8f537d;stroke-width:1.4;stroke-linecap:round;stroke-linejoin:round}
@keyframes mastery-ink-flow-20261124{to{stroke-dashoffset:-48}}
@keyframes mastery-ink-breathe-20261124{50%{opacity:.5}}
@media(prefers-reduced-motion:reduce){#knowledge-root .mastery-branches .chosen,#knowledge-root .mastery-stems>i.chosen{animation:none}}
.journal-amount-static.journal-dual-critical,.journal-shield.journal-dual-critical{color:#946508;text-shadow:0 0 7px #eab63a85,0 0 13px #eab63a30}
.journal-amount-static.journal-blocked-hit,.journal-shield.journal-blocked-hit{box-shadow:0 2px 7px -3px #5c90ad;background:#a6c3cd24;border-radius:4px;padding:0 3px}
.journal-amount-static.journal-dual-critical.journal-blocked-hit{background:#d8c57b26}

/* Compact sealed steps and passive memory; the two-form switch follows the Phoenix book prototype. */
#app #knowledge-root .mastery-tier>.mastery-node{min-height:0;padding:6px 3px;gap:4px}
#app #knowledge-root .mastery-tier>.mastery-node>strong{min-height:0;margin:0}
#app #knowledge-root .mastery-node.is-sealed{min-height:0;height:auto;padding:5px 2px 6px;gap:3px;justify-content:flex-start}
#app #knowledge-root .mastery-node.is-sealed>strong{min-height:0;margin:0;font-size:10px!important;line-height:14px!important}
#app #knowledge-root .mastery-node.is-sealed>small{min-height:0;margin:0;line-height:13px;font-size:10px}
#app #knowledge-root .mastery-legacy{margin:0 0 9px}
#app #knowledge-root .mastery-legacy-branches{height:24px}
#app #knowledge-root .mastery-legacy .mastery-item-final{min-height:0;height:auto;padding:8px 8px 9px;gap:4px}
#app #knowledge-root .mastery-legacy .mastery-item-final>strong{min-height:0;margin:0;font-size:12px!important;line-height:17px!important}
#app #knowledge-root .mastery-legacy .mastery-item-final>small{min-height:0;margin:0;font-size:12px;line-height:17px;white-space:normal}
/* The active seal and the smaller alternative share the root, as in the Phoenix page. */
.mastery-root-forms{display:grid;justify-items:center;gap:4px;padding-top:16px;text-align:center}
.mastery-root-icons{display:flex;align-items:center;justify-content:center;gap:10px;width:max-content;max-width:100%}
#app #knowledge-root .mastery-root-icons>.mastery-root{width:auto;margin:0;flex:none}
#app #knowledge-root .mastery-root-forms>strong{font:700 19px/23px Interface,sans-serif;color:#28523c}
#app #knowledge-root .mastery-root-forms>small{font:11px/16px Interface,sans-serif;color:#8d7246}
#app #knowledge-root .mastery-form-mini{position:static;display:grid;place-items:center;flex:none;width:42px;height:42px;min-width:0;min-height:0;padding:0;border:0;border-radius:50%;background:none;box-shadow:none}
#app #knowledge-root .mastery-form-mini .mastery-seal{width:38px;height:38px}
#app #knowledge-root .mastery-form-mini:disabled{opacity:.5}
#app #knowledge-root .mastery-form-mini:focus-visible{outline:2px solid #67866b;outline-offset:4px}
#app #knowledge-root .mastery-form-arrow{display:grid;place-items:center;flex:none;width:12px;height:28px;font:24px/1 Interface,sans-serif;color:#957b45;pointer-events:none}
#app #knowledge-root .mastery-node.preview{border:0;box-shadow:inset 0 0 0 1px #a2a16c80,inset 0 0 18px #e6d79540!important;background:#e5d39412;transition:box-shadow .26s,background-color .26s}
#app #knowledge-root .mastery-node.preview .mastery-seal{box-shadow:inset 0 0 0 3px #f7ebcb,0 0 0 2px #82976c22,0 0 15px #d7bf6a42}

#app #knowledge-root .mastery-legacy-status{margin:5px 0 12px;font:12px/1.5 Interface,sans-serif;color:#7e6a43}

#app #knowledge-root .mastery-binding-note{display:grid;justify-items:center;gap:5px;margin:13px 0 3px;padding:11px 10px;border:1px solid #c7ac7473;border-radius:10px;background:linear-gradient(120deg,#fff8e177,#ead2a338);text-align:center;color:#776348}
#app #knowledge-root .mastery-binding-note>small{font:calc(11px)/1.4 Interface,sans-serif;color:#9a7e4c}
#app #knowledge-root .mastery-binding-note>span{font:calc(12px)/1.5 Interface,sans-serif}
#app #knowledge-root .mastery-binding-note>.item-personal-note{display:inline-block;width:auto;min-width:0;height:auto;min-height:0;margin:1px 0 0;padding:3px 8px;border:1px solid #c5ad71;border-radius:5px;background:#fbf3dd;color:#826f49;box-shadow:inset 0 1px #fff9ec;font:calc(11px)/1.3 Interface,sans-serif!important;text-decoration:none;cursor:help}

/* Keep preview audio next to the close seal, never on top of its hit area. */
#app #knowledge-root .knowledge-reader-back:not(.book-listen){right:12px;top:13px;width:30px;height:30px;min-height:30px;z-index:9}
#app #knowledge-root .knowledge-reader-back.book-listen{position:absolute;right:50px;top:13px;width:30px;height:30px;min-height:30px;padding:3px;z-index:8;display:grid;place-items:center}
#app #knowledge-root .book-listen[hidden]{display:none!important}
#app #knowledge-root .book-listen>img{display:block;width:21px;height:21px;object-fit:contain;pointer-events:none}
