.word-card{position:fixed;z-index:1400;box-sizing:border-box;width:min(320px,calc(100vw - 24px));max-height:340px;overflow:auto;padding:12px;border:1px solid #cbbd91;border-radius:18px;background:var(--paper,#faf7ee);color:var(--ink,#194d3c);box-shadow:0 10px 35px #102e2826;font-family:UI,Cairo,Arial,sans-serif;line-height:1.7;font-size:14px;overscroll-behavior:contain}
.word-card[hidden]{display:none!important}.word-card header{display:flex;align-items:center;justify-content:space-between;gap:8px}.word-card h2{font-size:15px;margin:0}.word-card button{font:inherit;cursor:pointer;min-height:36px;padding:4px 9px;border:0;border-radius:8px;background:transparent;color:inherit}.word-card .word-close{font-size:26px;line-height:1;border:0!important;box-shadow:none!important;border-radius:0!important;width:40px;min-height:40px}.word-card button:focus-visible{outline:2px solid #ae924b;outline-offset:2px}.word-card nav{display:flex;border-bottom:1px solid #b7b7a54d;gap:5px;margin:8px 0}.word-card nav button{flex:1}.word-card nav [aria-pressed=true]{background:#dfe9df;color:#164d3e}.word-card-content{max-height:150px;overflow:auto;min-height:42px}.word-card-content p{margin:4px 0 8px;white-space:pre-wrap}.word-card-colors{border-top:1px solid #b7b7a54d;margin-top:10px;padding-top:7px;display:flex;align-items:center;gap:3px;flex-wrap:wrap}.word-card .word-swatch{min-width:32px;min-height:36px;padding:6px}.word-swatch span{display:block;width:19px;height:19px;border-radius:50%;background:var(--swatch)}.word-swatch[aria-pressed=true] span{outline:2px solid currentColor;outline-offset:2px}.word-card .word-remove{font-size:12px}.word-card canvas{display:block;max-width:100%;margin:0 auto;height:40px}.word-color-overlay{position:absolute;pointer-events:none!important;z-index:3;mix-blend-mode:multiply;max-width:none!important}.word-color-overlay rect{opacity:.28}.word-card-notice{font-size:12px;margin:3px 0}.word-card details{margin-top:8px}.word-card summary{cursor:pointer}html[data-theme="night"] .word-color-overlay{mix-blend-mode:screen}

.word-card header{padding:0;max-width:none;margin:0}.word-card h2{font-family:UI,sans-serif}.word-card nav{position:static;width:auto;transform:none}.word-card::after{content:"";display:none}

.word-card-word{display:flex;align-items:center;justify-content:center;gap:10px;min-height:40px}.word-card-word canvas{margin:0;min-width:0;object-fit:contain}.word-card .word-hear{flex-shrink:0;background:#e8eee3;font-size:12px;min-height:40px;max-width:140px}.word-card .word-hear[aria-pressed=true]{background:#dce5d5}.word-card .word-hear[hidden]{display:none}html[data-theme="night"] .word-card .word-hear{background:#304439;color:#f3ecd8}

.word-card .word-hear{width:40px;padding:8px;display:grid;place-items:center}.word-hear svg{width:22px;height:22px}.word-hear[data-state=loading] svg{animation:word-audio-spin 1s linear infinite}@keyframes word-audio-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.word-hear[data-state=loading] svg{animation:none}}
.word-card .word-remove span{box-sizing:border-box;background:transparent;border:2px solid #9b987d}.word-card .word-note{width:36px;height:36px;padding:7px;margin-inline-start:auto;display:grid;place-items:center}.word-note svg{width:22px;height:22px}.word-note[data-saved=true]{background:#dfe9df!important}.word-note-input{box-sizing:border-box;width:100%;max-height:90px;resize:vertical;font:inherit;color:inherit;background:transparent;border:1px solid #cbbd91;border-radius:8px;padding:7px}.word-note-actions{display:flex;gap:5px;justify-content:flex-end}.word-note-actions button:first-child{background:#205646;color:#fff}

.word-card .word-note-input{font-size:16px}
