/* Disciplined motion, with one shared site-level preference. */
.amelia-options{max-height:min(60vh,440px);overflow-y:auto;overscroll-behavior:contain;width:min(320px,calc(100vw - 60px));box-sizing:border-box}
.amelia-preference-row{display:grid!important;grid-template-columns:1fr 1fr;align-items:center;gap:.6rem;margin:.6rem 0}.amelia-preference-row select{width:100%;min-width:0;background:var(--paper,#eee8dc);color:var(--ink,#202027);border:1px solid var(--line,#777);padding:.35rem;font:inherit}.amelia-quick-action{display:block;width:100%;text-align:left;margin:.3rem 0}.amelia-preference-status{font-size:.75rem;line-height:1.4}.profile-rename-notice{border-left:3px solid #7b322a;padding:1rem;margin-bottom:1rem}.profile-saved{animation:lna-v6-saved .18s ease-out}.corpo-terminal:not([hidden]){border-top-color:#7b322a;animation:lna-v6-panel .2s ease-out}.corpo-terminal.is-closing{animation:lna-v6-close .12s ease-in both}.amelia-options:not([hidden]),details[open]>:not(summary){animation:lna-v6-reveal .18s ease-out}.asset-dialog h2,.asset-dialog .dialog-specs{animation:lna-v6-reveal .18s ease-out}button,a,select{transition-property:border-color,outline-color;transition-duration:160ms}button:focus-visible,a:focus-visible,select:focus-visible{outline:2px solid #7b322a;outline-offset:3px}
@keyframes lna-v6-reveal{from{opacity:.35;transform:translateY(3px)}to{opacity:1;transform:none}}@keyframes lna-v6-panel{from{opacity:0;transform:translateY(5px);border-top-color:transparent}to{opacity:1;transform:none;border-top-color:#7b322a}}@keyframes lna-v6-close{to{opacity:0;transform:translateY(3px)}}@keyframes lna-v6-saved{from{opacity:.2}to{opacity:1}}
html[data-website-motion="reduced"] *,html[data-website-motion="reduced"] *::before,html[data-website-motion="reduced"] *::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}
@media(max-width:500px){.amelia-options{max-height:42vh}.amelia-preference-row{font-size:.8rem}}
/* Keep the composer reachable even when the window has been resized. */
.amelia-options{max-height:min(42vh,max(70px,calc(var(--amelia-height,590px) - 280px)))}

/* State belongs to the control; these lines only present the current state. */
[data-filter],[data-game-filter],.grade-control{position:relative}
[data-filter]::after,[data-game-filter]::after,.grade-control::after{content:"";position:absolute;left:0;right:0;bottom:0;height:2px;background:var(--red,#7b322a);transform:scaleX(0);transform-origin:left;transition:transform 180ms ease-out;pointer-events:none}
[data-filter][aria-pressed="true"]::after,[data-game-filter][aria-pressed="true"]::after,.grade-control:focus-within::after{transform:scaleX(1)}
.text-link{text-underline-offset:.22em;transition:text-decoration-color 160ms,border-color 160ms}
.control:active,.corpo-terminal button:active{border-color:var(--red,#7b322a)}
.lna-hero-backdrop{animation:lna-v6-image 240ms ease-out}
.profile-image-field:not([hidden]),.profile-preview:not([hidden]){animation:lna-v6-reveal 180ms ease-out}
/* Web Animations sequences handle these; avoid competing legacy CSS transforms. */
.branch-asset,.system-preview,.asset-dialog h2,.asset-dialog .dialog-specs,details[open]>:not(summary){animation:none}
@keyframes lna-v6-image{from{opacity:0}}
@supports (interpolate-size:allow-keywords){
 html{interpolate-size:allow-keywords}
 details::details-content{height:0;overflow:clip;opacity:0;transition:height 180ms ease-out,opacity 150ms ease-out,content-visibility 180ms allow-discrete}
 details[open]::details-content{height:auto;opacity:1}
}
html[data-theme="dark"] [data-filter]::after,html[data-theme="dark"] [data-game-filter]::after,html[data-theme="dark"] .grade-control::after{background:var(--red-light,#dfada4)}

html[data-website-motion="reduced"] details::details-content{transition:none!important}
@media(prefers-reduced-motion:reduce){html:not([data-website-motion="full"]) details::details-content{transition:none!important}}
