.fx-keys { display: grid; gap: 18px; }
.fx-keys .fx-keys-how { margin: 0; padding: 14px; color: var(--fx-ink); font-size: 16px; line-height: 1.5; }
.fx-keys .fx-keys-how ol { margin: 0; padding-left: 24px; }
.fx-keys .fx-keys-how li + li { margin-top: 6px; }
.fx-keys .fx-keys-goal { margin: 0; color: var(--fx-ink); font-size: 16px; line-height: 1.5; }
.fx-keys .fx-keys-controls { min-width: 0; margin: 0; padding: 0 0 5px; border: 0; color: var(--fx-ink); }
.fx-keys .fx-keys-controls legend { padding: 0; margin-bottom: 12px; font-size: 16px; font-weight: 700; line-height: 1.5; }
.fx-keys .fx-keys-keyboard { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.fx-keys .fx-keys-key { box-sizing: border-box; display: flex; align-items: center; justify-content: center; min-width: 0; min-height: 76px; margin: 0; padding: 12px; border: 2px solid var(--fx-ink); border-radius: 10px; background: var(--fx-paper); color: var(--fx-ink); box-shadow: 0 5px 0 var(--fx-ink); font-size: 16px; line-height: 1.4; text-align: center; white-space: normal; cursor: pointer; transform: none; }
.fx-keys .fx-keys-key:has(input:checked) { background: var(--fx-mint-pale); color: var(--fx-ink); box-shadow: inset 0 3px 0 var(--fx-muted); transform: none; }
.fx-keys .fx-keys-key:active { transform: none; }
.fx-keys .fx-keys-key:has(input:focus-visible) { outline: 3px solid var(--fx-ink); outline-offset: 3px; }
.fx-keys .fx-keys-stage { box-sizing: border-box; min-width: 0; height: 360px; padding: 10px; }
.fx-keys .fx-keys-paper { box-sizing: border-box; width: 100%; height: 100%; padding: 16px; border: 1px solid var(--fx-muted); border-radius: 3px; background: var(--fx-paper); color: var(--fx-ink); box-shadow: 0 3px 0 var(--fx-muted); font-size: 16px; }
.fx-keys .fx-keys-paperhead { display: grid; gap: 10px; margin-bottom: 18px; }
.fx-keys .fx-keys-paperhead > b { font-size: 18px; line-height: 1.4; }
.fx-keys .fx-keys-tag { justify-self: start; padding: 6px 8px; border-left: 3px solid var(--fx-coral); background: var(--fx-sun-pale); font-size: 12px; line-height: 1.5; }
.fx-keys .fx-keys-mark { text-decoration-line: underline; text-decoration-color: var(--fx-coral); text-decoration-thickness: 3px; text-underline-offset: 3px; }
.fx-keys .fx-keys-letter { display: grid; align-items: start; font-size: 16px; line-height: 1.6; }
.fx-keys .fx-keys-inline, .fx-keys .fx-keys-broken { grid-area: 1 / 1; min-width: 0; }
.fx-keys .fx-keys-letter p { margin: 0; }
.fx-keys .fx-keys-broken { visibility: hidden; }
.fx-keys .fx-keys-join { white-space: nowrap; }
.fx-keys .fx-keys-gap { display: inline-block; width: 0; }
.fx-keys:has(#fx-keys-tab:checked) .fx-keys-gap { width: 1.25em; }
.fx-keys:has(#fx-keys-enter:checked) .fx-keys-inline { visibility: hidden; }
.fx-keys:has(#fx-keys-enter:checked) .fx-keys-broken { visibility: visible; }
.fx-keys:has(#fx-keys-tab:checked) .fx-keys-new { text-indent: 1.25em; }
.fx-keys:has(#fx-keys-extra:checked) .fx-keys-new { margin-top: 1.6em; }
.fx-keys .fx-keys-result { min-width: 0; color: var(--fx-ink); font-size: 16px; }
.fx-keys .fx-keys-resultlabel { display: block; margin-bottom: 10px; line-height: 1.5; }
.fx-keys .fx-keys-messages { display: grid; }
.fx-keys .fx-keys-message { box-sizing: border-box; grid-area: 1 / 1; min-width: 0; margin: 0; padding: 14px; color: var(--fx-ink); font-size: 16px; line-height: 1.5; visibility: hidden; }
.fx-keys:has(#fx-keys-enter:not(:checked)):has(#fx-keys-tab:not(:checked)):has(#fx-keys-extra:not(:checked)) .fx-keys-s000, .fx-keys:has(#fx-keys-enter:checked):has(#fx-keys-tab:not(:checked)):has(#fx-keys-extra:not(:checked)) .fx-keys-s100, .fx-keys:has(#fx-keys-enter:not(:checked)):has(#fx-keys-tab:checked):has(#fx-keys-extra:not(:checked)) .fx-keys-s010, .fx-keys:has(#fx-keys-enter:not(:checked)):has(#fx-keys-tab:not(:checked)):has(#fx-keys-extra:checked) .fx-keys-s001, .fx-keys:has(#fx-keys-enter:not(:checked)):has(#fx-keys-tab:checked):has(#fx-keys-extra:checked) .fx-keys-s011, .fx-keys:has(#fx-keys-enter:checked):has(#fx-keys-tab:checked):has(#fx-keys-extra:not(:checked)) .fx-keys-s110, .fx-keys:has(#fx-keys-enter:checked):has(#fx-keys-tab:not(:checked)):has(#fx-keys-extra:checked) .fx-keys-s101, .fx-keys:has(#fx-keys-enter:checked):has(#fx-keys-tab:checked):has(#fx-keys-extra:checked) .fx-keys-s111 { visibility: visible; }
.fx-keys:has(#fx-keys-enter:not(:checked)):has(#fx-keys-tab:not(:checked)):has(#fx-keys-extra:checked) .fx-keys-extra { animation: fx-keys-flash 0.6s 1; }
@keyframes fx-keys-flash { 0% { background: var(--fx-sun); } 50% { background: var(--fx-coral-pale); } 100% { background: var(--fx-mint-pale); } }
@container (max-width: 480px) { .fx-keys .fx-keys-keyboard { grid-template-columns: 1fr; } .fx-keys .fx-keys-key { min-height: 64px; } .fx-keys .fx-keys-stage { height: 420px; padding: 8px; } .fx-keys .fx-keys-paper { padding: 12px; } }
@media (prefers-reduced-motion: reduce) { .fx-keys .fx-keys-key { animation: none; transition: none; } }