/* A conversation belongs to its NPC, separate from the adventurer workspace. */
.quest-dialog{--quest-gold:#d9b777;--quest-border:#586057;color:#eee9dc;background:#152126;width:min(520px,calc(100vw - 32px));max-width:none;max-height:min(670px,calc(100dvh - 40px));padding:0;border:1px solid var(--quest-border);border-top:3px solid var(--quest-gold);border-radius:10px;box-shadow:0 22px 90px #0009;overflow:hidden}
.quest-dialog[open]{display:flex;flex-direction:column}
.quest-dialog::backdrop{background:#08131a45;backdrop-filter:none}
.quest-dialog-header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 22px;border-bottom:1px solid #ffffff16;flex-shrink:0}
.quest-dialog-header>div{display:grid;gap:3px}.quest-dialog-header strong{font-size:18px;color:var(--quest-gold)}.quest-dialog-header span{font-size:13px;color:#b7c2bd}
.quest-dialog .close-dialog{position:static;display:flex;align-items:center;gap:7px;min-width:44px;min-height:44px;padding:8px;color:#ddd6c7;background:transparent;border:1px solid #ffffff22}.quest-dialog .close-dialog svg{width:17px;height:17px}.quest-dialog .close-dialog kbd{font-size:11px}
.quest-dialog .panel-content{padding:0;display:flex;flex-direction:column;min-height:0;overflow:hidden}
.conversation-body{padding:16px 22px;overflow:hidden;min-height:0;display:flex;flex:1;flex-direction:column}
.quest-title .eyebrow{color:var(--quest-gold);font-size:12px}.quest-title h2{font-size:26px;line-height:1.15;margin:7px 0 15px}
.quest-dialog .npc-story{font-size:15px;line-height:1.65;margin:0;padding:0;color:#d6ded7;border:0;background:none}
.quest-greeting{font-size:15px;line-height:1.55;color:#d6ded7;margin:0 0 9px}.quest-dialogue>summary{font-size:12px;color:#b8c3b9;cursor:pointer}.quest-dialogue .npc-story{font-size:14px;margin-top:10px}.quest-dialog .npc-lore h3{margin:0 0 6px}
.quest-dialog .narration-controls{gap:8px;margin:10px 0 0;flex-wrap:wrap}.quest-dialog .narration-controls button{min-height:34px;font-size:12px;padding:5px 9px}.quest-dialog .narration-controls span{font-size:12px}
.quest-objective{margin-top:18px;padding:15px 0 0;border-top:1px solid #ffffff18}.quest-objective h3{font-size:14px;color:var(--quest-gold);margin:0 0 8px}
.quest-objective-line{font-size:14px;line-height:1.55;margin:0}.quest-objective progress,.quest-log-card progress{width:100%;height:5px;accent-color:#d9b777;border:0}
.quest-count{display:flex;justify-content:space-between;gap:12px;font-size:13px;margin:10px 0 5px}.quest-ready-note{color:#aed4af;font-size:13px}
.quest-objectives{list-style:none;margin:0;padding:0;display:grid;gap:10px}.quest-objectives li{display:flex;gap:10px;align-items:flex-start;font-size:14px;color:#bdc8c2;line-height:1.4}.quest-objectives li>span:first-child{width:23px;height:23px;flex-shrink:0;display:grid;place-items:center;border:1px solid #ffffff25;border-radius:50%;font-size:12px}.quest-objectives .current{color:#f2e4c5}.quest-objectives .current>span:first-child{border-color:#d9b777}.quest-objectives .done{color:#9bb6a1}.quest-objectives small{display:block;font-size:11px;opacity:.8}
.quest-rewards{margin:17px 0 0;border-top:1px solid #ffffff18;padding-top:12px}.quest-rewards>summary{font-size:14px;color:var(--quest-gold);cursor:pointer}.quest-dialog .reward{display:flex;flex-wrap:wrap;gap:10px;margin-top:10px;font-size:13px}.quest-dialog .quest-level{display:none}.quest-dialog .quest-gear-reward{padding:7px 10px;background:#ffffff06;border:1px solid #ffffff12;border-radius:5px}.quest-dialog .quest-gear-reward svg{width:40px;height:40px}.quest-dialog .quest-gear-reward small{font-size:11px}
.quest-dialog .npc-lore{margin-top:17px;padding-top:12px;border-top:1px solid #ffffff14}.quest-dialog .npc-lore h3{font-size:12px;font-weight:500;color:#afbab6}.quest-dialog .npc-lore .chronicle{padding:6px 0;margin:0;border:0}.quest-dialog .npc-lore summary{font-size:13px}.quest-dialog .npc-lore blockquote{font-size:14px;line-height:1.55}
.quest-dialog-actions{flex-shrink:0;padding:12px 22px 17px;background:#101b20;border-top:1px solid #ffffff1c}.quest-dialog-actions>div{display:flex;justify-content:flex-end;gap:10px}.quest-dialog-actions button{min-height:44px;font-size:14px;padding:10px 15px}.quest-dialog-actions .primary{color:#1c231f;background:#d9b777;border-color:#d9b777}.quest-dialog-actions [role=status]{font-size:13px;line-height:1.45;color:#e3c49e;margin:0 0 10px}.quest-dialog-actions [role=status]:empty{display:none}.quest-dialog button:disabled{opacity:.55;cursor:wait}.quest-dialog .menu-connection-notice{position:static;margin:0;border-radius:0;padding:10px 22px;font-size:13px}
.quest-log{max-width:840px}.quest-log>section>h3{display:flex;gap:10px;align-items:center}.quest-total{font-size:13px;color:#aaa}.quest-log-card{padding:18px 20px;margin:12px 0;background:#ffffff04;border:1px solid #ffffff12;border-left:3px solid #778b87;border-radius:6px}.quest-log-card.ready{border-left-color:#d9b777}.quest-log-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}.quest-log-heading .eyebrow{font-size:11px}.quest-log-heading button{font-size:13px;min-height:36px}.quest-log-heading button[aria-pressed=true]{color:#d9b777}.quest-log-card h3{font-size:22px;margin:5px 0}.quest-giver{font-size:13px;color:#a9bab3;margin:0 0 12px}.quest-next-step{font-size:15px;color:#e4d1ab}.quest-log-card .chronicle{margin-top:14px}.quest-history{margin-top:24px;border-top:1px solid #ffffff18;padding-top:18px}.quest-history>summary{cursor:pointer}.quest-history>summary span{font-size:13px;color:#aaa;margin-left:8px}
@media(max-width:600px){.quest-dialog{width:calc(100vw - 20px);max-height:calc(100dvh - 24px);border-radius:8px}.quest-dialog-header{padding:11px 16px}.conversation-body{padding:16px}.quest-title h2{font-size:23px}.quest-dialog-actions{padding:11px 16px}.quest-dialog-actions>div{display:grid;grid-template-columns:1fr 1fr}.quest-dialog-actions button:only-child{grid-column:1/-1}.quest-log-card{padding:14px}.quest-dialog .npc-story{font-size:14px}.quest-dialog-header span{font-size:12px}}
@media(prefers-reduced-motion:reduce){.quest-dialog,.quest-dialog *{scroll-behavior:auto}}
.combat-input-feedback[hidden]{display:none}.combat-input-feedback{max-width:350px;margin:0 auto 7px;color:#f4d5af;background:#261f1bea;padding:7px 12px;border-radius:5px;font-size:13px;text-align:center;pointer-events:none}.ability.input-confirmed{outline:2px solid #efdcac;outline-offset:2px;filter:brightness(1.16)}

/* Fixed-size conversation pages keep the action row in view at every step. */
.quest-dialog{height:min(620px,calc(100dvh - 24px));max-height:calc(100dvh - 24px)}
.quest-dialog .panel-content{flex:1}.quest-title{flex-shrink:0}.quest-title h2{margin-bottom:12px}
.quest-reading-nav{display:flex;gap:5px;flex-shrink:0;margin:0 0 14px}.quest-reading-nav button{background:transparent;border:0;border-bottom:2px solid transparent;color:#aebcb6;min-height:36px;padding:6px 10px;font-size:13px}.quest-reading-nav button[aria-pressed=true]{color:#edce92;border-color:#d9b777}
.quest-reader{flex:1;min-height:0;overflow:hidden;overflow-wrap:anywhere}.quest-reader>h3{font-size:13px;line-height:1.3;color:#d9b777;margin:14px 0 8px}.quest-reader>h3:first-child{margin-top:0}.quest-reader>p{margin:0 0 10px}.quest-reader .quest-count{font-size:13px;color:#aec7b5}.quest-reader .reward{margin:0;gap:8px}.quest-reader .quest-gear-reward{max-width:100%}.quest-reader .quest-gear-reward svg{flex-shrink:0}.quest-reader .npc-story{font-size:15px;line-height:1.7}
.quest-page-nav{display:flex;justify-content:space-between;align-items:center;min-height:32px;flex-shrink:0;gap:12px}.quest-page-nav:has(button[hidden]){min-height:8px}.quest-page-nav button{font-size:12px;min-height:32px;padding:4px 8px}.quest-page-nav span{font-size:12px;color:#a7b7af}.quest-page-nav [hidden]{display:none}
.quest-voice-slot{flex-shrink:0;min-height:38px}.quest-dialog .narration-controls{margin:2px 0 0;gap:6px;flex-wrap:nowrap;align-items:center}.quest-dialog .narration-controls button{white-space:nowrap}.quest-dialog .narration-controls span{font-size:11px;line-height:1.3}
@media(max-height:620px){.quest-dialog-header{padding:7px 16px}.quest-dialog-header strong{font-size:16px}.quest-dialog-header span{font-size:11px}.quest-dialog-header .close-dialog{min-height:36px;height:36px}.conversation-body{padding:10px 16px}.quest-title h2{font-size:20px;margin:3px 0 7px}.quest-title .eyebrow{font-size:10px}.quest-reading-nav{margin-bottom:8px}.quest-reading-nav button{min-height:30px;padding:4px 8px}.quest-dialog-actions{padding:8px 16px}.quest-dialog-actions button{min-height:38px;padding:8px 12px}.quest-reader .npc-story{font-size:14px;line-height:1.55}.quest-voice-slot{min-height:34px}.quest-dialog .quest-gear-reward{padding:5px 8px}}
