/* Shared interactive surfaces. Loaded last so one control has one visual state. */
body.conversation-page{--control-border:#7186bc;--control-hover:#e8eeff}
body.product-page.conversation-page :is(.btn,.library-button,.app-shell-restart,.app-shell-restore,.app-domain-button,.library-filter-toggle){border:1px solid var(--control-border);background:var(--brand-surface);color:var(--brand-primary);font-weight:550;box-shadow:0 2px 3px #15213d06;transition:background-color .15s ease-out,border-color .15s ease-out,box-shadow .15s ease-out}
body.product-page.conversation-page :is(.btn,.library-button,.app-shell-restart,.app-shell-restore,.app-domain-button,.library-filter-toggle):hover:not(:disabled){border-color:var(--brand-primary);background:var(--control-hover);color:var(--brand-primary);box-shadow:0 3px 9px #15213d12}
body.product-page.conversation-page :is(.btn-primary,.library-button.primary,.app-shell-primary){background:var(--brand-primary);color:white;border-color:var(--brand-primary)}
body.product-page.conversation-page :is(.btn-primary,.library-button.primary,.app-shell-primary):hover:not(:disabled){background:var(--brand-hover);border-color:var(--brand-hover);color:white}
body.product-page.conversation-page :is(.btn,.library-button)[aria-pressed=true]{background:var(--brand-selected);border-color:var(--brand-primary);color:var(--brand-primary);box-shadow:inset 0 0 0 1px var(--brand-primary)}
body.product-page.conversation-page :is(button,a,summary):focus-visible{outline:3px solid var(--brand-primary);outline-offset:3px}
body.product-page.conversation-page button:disabled{opacity:.43;box-shadow:none;cursor:default}
body.product-page.conversation-page #stage .game-option{background:white;border-color:var(--brand-strong-line);color:var(--brand-ink);font-weight:500;box-shadow:none}
body.product-page.conversation-page #stage .game-option:hover:not(:disabled){border-color:var(--brand-primary);background:var(--control-hover)}
body.product-page.conversation-page #stage .game-option[aria-pressed=true]{background:var(--brand-selected);border-color:var(--brand-primary);color:var(--brand-primary);box-shadow:inset 0 0 0 1px var(--brand-primary)}
body.product-page.conversation-page #stage .game-action-controls>.btn-secondary{background:white;border:1px solid var(--control-border);color:var(--brand-primary)}
body.product-page.conversation-page #stage .game-action-controls>.btn-secondary:hover:not(:disabled){background:var(--control-hover);border-color:var(--brand-primary)}
body.product-page.conversation-page :is(#stage,#request-panel,.board-library) details:not(.game-request-details)>summary{display:flex;align-items:center;justify-content:space-between;gap:12px;list-style:none;min-height:44px;padding:12px 14px;border:1px solid var(--control-border);border-radius:12px;background:var(--brand-surface);color:var(--brand-primary);font-size:13px;font-weight:550;line-height:1.6;cursor:pointer}
body.product-page.conversation-page details>summary::-webkit-details-marker{display:none}
body.product-page.conversation-page details>summary::marker{content:''}
body.product-page.conversation-page details>summary::before{display:none}
body.product-page.conversation-page :is(#stage,#request-panel,.board-library) details:not(.game-request-details)>summary::after{content:'';flex:none;width:18px;height:18px;border:0;margin:0;transform:rotate(0deg);background:currentColor;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m6 8 4 4 4-4' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat;transition:transform .15s ease-out}
body.product-page.conversation-page :is(#stage,#request-panel,.board-library) details:not(.game-request-details)[open]>summary{background:var(--brand-selected);border-color:var(--brand-primary);color:var(--brand-primary)}
body.product-page.conversation-page :is(#stage,#request-panel,.board-library) details[open]>summary::after{transform:rotate(180deg)}
body.product-page.conversation-page :is(#stage,#request-panel,.board-library) details>summary:hover{background:var(--control-hover);border-color:var(--brand-primary)}
body.product-page.conversation-page details>summary>:is(svg,.i,.evening-chevron){display:none}
body.product-page.conversation-page :is(#stage,#request-panel,.board-library) details:is(.evening-feedback-note,[data-disclosure^="selection-review:"])>summary{display:grid;grid-template-columns:minmax(0,1fr) 18px;gap:2px 12px}
body.product-page.conversation-page :is(#stage,#request-panel,.board-library) details:is(.evening-feedback-note,[data-disclosure^="selection-review:"])>summary>span{grid-column:1;font-size:12px;font-weight:400;color:var(--brand-muted)}
body.product-page.conversation-page :is(#stage,#request-panel,.board-library) details:is(.evening-feedback-note,[data-disclosure^="selection-review:"])>summary::after{grid-column:2;grid-row:1/3;align-self:center}
body.product-page.conversation-page .custom-select-trigger{border-color:var(--control-border);color:var(--brand-primary)}
body.product-page.conversation-page .app-shell-nav a{border:1px solid var(--brand-line);color:var(--brand-primary)}
body.product-page.conversation-page .app-shell-nav a:hover{border-color:var(--brand-primary);background:var(--control-hover)}
body.product-page.conversation-page :is(.library-views,.board-switch) button{color:var(--brand-primary)}
body.product-page.conversation-page :is(.library-views,.board-switch) button[aria-pressed=true]{background:var(--brand-primary);color:white}
body.product-page.conversation-page :is(.library-views,.board-switch) button[aria-pressed=true] span{background:white;color:var(--brand-primary)}
body.product-page.conversation-page #request-panel .request-facts button{border:1px solid var(--control-border);background:white;color:var(--brand-primary)}
body.product-page.conversation-page .library-remove{border:1px solid var(--control-border);background:var(--brand-paper);color:var(--brand-primary)}
body.product-page.conversation-page #stage .game-answer-extras{display:flex;flex-direction:column;gap:10px;margin-top:18px}
body.product-page.conversation-page #stage .game-answer-extra{width:100%;margin:0;min-width:0}
body.product-page.conversation-page #stage .game-answer-extra[open]{padding-bottom:8px}
body.product-page.conversation-page #stage .game-answer-extra[open]>summary{margin-bottom:12px}
body.product-page.conversation-page #stage .game-answer-extra .game-question-options{margin:0;gap:9px}
body.product-page.conversation-page #stage .game-answer-extra .game-field{margin:0}
body.product-page.conversation-page #stage .game-example>summary{padding:12px 14px;color:var(--brand-primary);font-size:13px}
body.product-page.conversation-page .game-card-pending .game-card-actions{align-items:stretch;flex-direction:column}
body.product-page.conversation-page .game-card-pending [data-act=replace-one]{background:var(--brand-primary);border-color:var(--brand-primary);color:white}
body.product-page.conversation-page .game-card-pending [data-act=replace-one]:hover:not(:disabled){background:var(--brand-hover);color:white}
body.product-page.conversation-page .game-title-copy{border-radius:10px;padding:5px 8px;margin-left:-8px}
body.product-page.conversation-page .game-title-copy>svg{padding:3px;width:26px;height:26px;margin-top:0;border:1px solid var(--control-border);border-radius:7px;color:var(--brand-primary);stroke:currentColor;background:var(--brand-paper)}
body.product-page.conversation-page .game-title-copy:hover{background:var(--control-hover)}
body.product-page.conversation-page .game-store-link{display:inline-flex;align-items:center;gap:12px;width:fit-content;padding:10px 13px;border:1px solid var(--control-border);border-radius:12px;min-height:44px;text-decoration:none;color:var(--brand-primary);font-weight:550}
body.product-page.conversation-page .game-store-link:hover{background:var(--control-hover);border-color:var(--brand-primary)}
body.product-page.conversation-page #stage .game-proposal>.game-store-link{padding:10px 13px}
body.product-page.conversation-page .history-selection .library-button{white-space:normal;text-align:center}
body.product-page.conversation-page .history-selection p{overflow-wrap:anywhere}
body.product-page.conversation-page .history-alternatives{margin-top:8px;color:var(--brand-muted);font-size:13px}
@media(prefers-reduced-motion:reduce){body.product-page.conversation-page :is(button,summary,summary::after){transition:none}}

body.product-page .app-shell .game-session-menu>summary{display:flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:8px 14px;border-radius:10px;color:var(--brand-primary);font:550 13px/1.4 Golos,Arial,sans-serif;cursor:pointer;list-style:none}
body.product-page .app-shell .game-session-menu>summary::after{content:'';width:7px;height:7px;margin-top:-4px;border:solid currentColor;border-width:0 1.5px 1.5px 0;transform:rotate(45deg)}
body.product-page .app-shell .game-session-menu[open]>summary::after{margin-top:3px;transform:rotate(225deg)}
body.product-page .app-shell .game-session-menu>summary:hover,body.product-page .app-shell .game-session-menu[open]>summary{background:var(--control-hover)}
body.product-page .app-shell .app-session-actions{position:absolute;right:0;top:calc(100% + 6px);z-index:81;width:max-content;max-width:calc(100vw - 32px);display:grid;gap:6px;padding:8px;border:1px solid var(--brand-line);border-radius:14px;background:var(--brand-surface);box-shadow:0 10px 28px #15213d24}
body.product-page .app-shell .app-session-actions>button{white-space:normal;text-align:center;overflow-wrap:anywhere}
body.product-page .app-shell:has(.game-session-menu) .app-shell-actions{flex-basis:auto;grid-row:2;grid-column:2;justify-content:flex-end}
body.product-page:has([data-first-next])[data-has-summary=false] #picker-workspace>.game-context-panel{display:none}
body.product-page:has([data-first-next])[data-has-summary=false] #picker-workspace{grid-template-columns:minmax(0,1fr);max-width:850px}
body.product-page:has([data-first-next]) #stage .game-back:disabled{display:none}
body.product-page:has([data-first-next]) #stage .game-navigation{margin-bottom:18px}
body.product-page #stage #answer-form:has([data-first-next])>.game-question-options{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:12px 0 0}
body.product-page #stage #answer-form:has([data-first-next])>.game-question-options .game-option{position:relative;min-width:0;min-height:48px;padding:10px 24px 10px 12px;overflow-wrap:anywhere}
body.product-page #stage #answer-form:has([data-first-next])>.game-question-options .game-option-check{position:absolute;right:6px;top:6px;width:14px;height:14px}
body.product-page #stage #answer-form:has(.game-answer-extra[open])>.game-answer-extras{margin-top:14px}
body.product-page #stage #answer-form:has([data-first-next]) .game-answer-extra .game-question-options{
 grid-template-columns:repeat(auto-fit,minmax(min(128px,100%),1fr))
}
body.product-page #stage #answer-form:has([data-first-next]) .game-answer-extra .game-option{
 min-width:0;min-height:44px;padding:9px 10px;font-size:13px;overflow-wrap:anywhere
}
body.product-page #stage #answer-form:has([data-first-next]) .game-answer-extra .game-option-check{flex-shrink:0}
body.product-page:is([data-view=question],[data-view=review]) #stage .game-action-controls{justify-content:flex-start}
body.product-page.conversation-page #stage .game-action-controls>.btn{margin-left:0;max-width:100%;padding:12px 17px;justify-content:center;text-align:center;white-space:normal}
body.product-page.conversation-page #stage .game-draft-hint{flex-basis:100%;text-align:left;margin:0}
body.product-page.conversation-page #stage details:is(.game-result-tools,.evening-rating)>summary{border-color:transparent;background:transparent;justify-content:flex-start;gap:8px;padding:8px 6px}
body.product-page.conversation-page #stage details:is(.game-result-tools,.evening-rating)>summary:hover{background:var(--control-hover)}
body.product-page.conversation-page #stage .game-proposal .game-store-link{min-height:44px;padding:8px 0;border:0;background:transparent;box-shadow:none}
body.product-page.conversation-page #stage .game-proposal .game-store-link:hover{text-decoration:underline;background:transparent}
body.product-page.conversation-page #stage .game-proposal .game-plan-actions [data-act=familiar-mark]{
 border-color:transparent;background:transparent;box-shadow:none
}
body.product-page.conversation-page #stage .game-proposal .game-plan-actions [data-act=familiar-mark]:hover{
 background:var(--control-hover)
}
body.product-page.conversation-page #stage .game-result-tools a.btn{display:inline-flex;align-items:center;min-height:44px;text-decoration:none}
body.product-page #stage .game-result-notes .game-replacement-notice{padding:10px 12px}
body.product-page[data-view=result] #stage .game-navigation{margin-bottom:18px;padding-bottom:0}
body.product-page.library-page .library-cover{min-height:0;height:88px}
body.product-page.library-page .library-cover img{width:100%;height:100%;object-fit:contain}
body.product-page.library-page .library-cover:not(.is-loaded) img{position:absolute;inset:0}
body.product-page.library-page .library-cover.is-loaded>small{display:none}
body.product-page.library-page .library-cover>small{max-width:100%;overflow-wrap:anywhere;text-align:center}
body.product-page.library-page .library-cover.no-cover{min-height:0;padding:6px}
body.product-page.library-page .history-row h2{overflow-wrap:anywhere}
body.product-page.library-page .library-notice{pointer-events:none}
@media(min-width:761px) and (max-width:900px){
 body.product-page .app-domain-short{display:inline;font-size:14px;font-weight:550}
 body.product-page .app-domain-button strong{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
}
@media(max-width:1000px){
 body.product-page:is([data-view=result],[data-view=review]) .game-context-panel[data-context-open=false] :is(#understanding,#request-preview){display:none}
 body.product-page:is([data-view=result],[data-view=review]) .game-context-panel #request-panel .game-context-toggle{display:inline-flex;min-height:44px}
 body.product-page:is([data-view=result],[data-view=review]) .game-context-panel[data-context-open=false] #request-panel .game-context-heading>[data-act=focus-correction]{display:none}
 body.product-page:is([data-view=result],[data-view=review]) .game-context-panel[data-context-open=true] #request-preview{display:none}
 body.product-page:is([data-view=result],[data-view=review]) #request-panel .game-context-heading{margin:0}
}
@media(max-width:760px){
 body.product-page .app-shell .app-session-actions{width:240px}
 body.product-page.conversation-page #stage .game-action-controls{display:flex;flex-direction:column;align-items:stretch;gap:10px}
 body.product-page.conversation-page #stage .game-action-controls>.btn{flex:none;width:100%;min-width:0;max-width:none;min-height:48px}
 body.product-page.conversation-page #stage .game-action-controls>.btn-primary{flex:none}
 body.product-page #stage #answer-form:has([data-first-next])>.game-question-options .game-option{font-size:13px;padding:8px 19px 8px 10px}
 body.product-page #stage #answer-form:has([data-first-next]) textarea{font-size:16px}
 body.product-page.library-page .app-shell .app-shell-actions{display:none}
 body.product-page:is([data-view=result],[data-view=review]) #picker-workspace>.game-context-panel{padding-block:8px}
 body.product-page[data-view=result] #stage .game-navigation{margin-bottom:14px}
 body.product-page[data-view=result] #stage .game-proposal .game-card-layout .game-help{margin:0}
}

/* Answer choices, supplementary fields and navigation share one reading order. */
body.product-page #stage #answer-instruction{display:flex;flex-wrap:wrap;align-items:baseline;gap:2px 10px;margin:12px 0}
body.product-page #stage #answer-instruction strong{color:var(--brand-ink);font-weight:650}
body.product-page #stage .game-question-why{margin:0 0 12px}
body.product-page.conversation-page #stage .game-answer-extras{gap:0;margin:14px 0 0}
body.product-page.conversation-page #stage .game-answer-extra{border-top:1px solid var(--brand-line);padding:0}
body.product-page.conversation-page #stage details.game-answer-extra>summary,
body.product-page.conversation-page #request-panel .request-tools details>summary{
 border:0;border-radius:6px;padding:9px 4px;background:transparent;justify-content:flex-start;gap:8px
}
body.product-page.conversation-page #stage details.game-answer-extra>summary small{font-weight:400;color:var(--brand-muted)}
body.product-page.conversation-page #stage details.game-answer-extra>summary::after,
body.product-page.conversation-page #request-panel .request-tools details>summary::after{margin-inline-start:auto}
body.product-page.conversation-page #stage details.game-answer-extra[open]>summary{margin:0;background:transparent;border-color:transparent}
body.product-page.conversation-page #stage .game-answer-extra-body{
 display:grid;gap:14px;padding:12px 16px 16px;background:var(--brand-paper);border-radius:10px;margin-bottom:8px
}
body.product-page #stage .game-answer-extra-body .game-field small{font-size:12px;color:var(--brand-muted);font-weight:400}
body.product-page #stage .game-answer-avoid{border:0;padding:0;margin:0;min-inline-size:0}
body.product-page #stage .game-answer-avoid legend{padding:0;margin-bottom:8px;font-size:13px}
body.product-page #stage .game-example{font-size:13px}
body.product-page #stage .game-example .input{margin:6px 0 0}
body.product-page #stage .game-search-results:empty{display:none}
body.product-page #stage .game-question-footer{
 display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:8px 20px;
 padding-top:16px;margin-top:16px;border-top:1px solid var(--brand-line)
}
body.product-page #stage .game-question-footer .game-draft-hint{flex-basis:100%;margin:0;font-size:12px;color:var(--brand-muted)}
body.product-page #stage .game-question-footer .btn{min-height:46px;min-width:132px;gap:12px}
body.product-page #stage .game-question-footer .btn svg{width:18px;height:18px}
body.product-page #stage .game-question-secondary{display:flex;flex:1 1 auto;gap:0 16px;flex-wrap:wrap}
body.product-page #stage .game-text-action{
 min-height:44px;padding:4px 0;border:0;background:none;color:var(--brand-primary);
 font:inherit;font-size:13px;font-weight:550;text-align:start;cursor:pointer
}
body.product-page #stage .game-text-action:hover:not(:disabled){text-decoration:underline;text-underline-offset:3px}
body.product-page.conversation-page #stage .game-action-controls>[data-act=focus-correction]{
 border-color:transparent;background:transparent;box-shadow:none
}
body.product-page #stage .game-neutral-status:not([hidden]){margin:8px 0;font-size:13px}
body.product-page.conversation-page #stage .game-processing-mark{
 position:relative;display:grid;place-items:center;width:80px;height:80px;margin-bottom:6px
}
body.product-page.conversation-page #stage .game-processing-mark.inline{width:25px;height:25px;margin:0;flex:none}
body.product-page.conversation-page #stage .game-processing-mark.inline img{filter:brightness(0) invert(1)}
body.product-page.conversation-page #stage .game-processing-mark::after{
 content:"";position:absolute;inset:0;border:2px solid var(--brand-line);border-top-color:var(--brand-primary);
 border-radius:50%;animation:tastiq-loading-ring 1.15s linear infinite
}
@keyframes tastiq-loading-ring{to{transform:rotate(1turn)}}
@media(prefers-reduced-motion:reduce){
 body.product-page.conversation-page #stage .game-processing-mark::after{animation:none}
}

/* The request tools sit below the request facts. Open forms have their own surface. */
body.product-page.conversation-page #request-panel .request-tools{gap:0;border-block:1px solid var(--brand-line)}
body.product-page.conversation-page #request-panel .request-tools>details+details{border-top:1px solid var(--brand-line)}
body.product-page.conversation-page #request-panel .request-tools .game-context-editor form{
 display:grid;gap:12px;margin:0 0 8px;padding:14px 12px;background:var(--brand-paper);border-radius:10px
}
body.product-page.conversation-page #request-panel .game-context-editor form .game-field{margin:0;gap:6px}
body.product-page.conversation-page #request-panel .game-context-editor form .custom-select-trigger{
 background:var(--brand-surface);color:var(--brand-ink)
}
body.product-page.conversation-page #request-panel .game-context-editor form [type=submit]{justify-self:start}
body.product-page #request-panel .request-field-note{margin:0;color:var(--brand-muted);font-size:12px}
body.product-page #request-panel .request-conditions>h3{margin:0 0 8px}

@media(max-width:600px){
 body.product-page #stage .game-question-footer{display:grid;grid-template-columns:minmax(0,1fr);justify-content:stretch;gap:4px}
 body.product-page #stage .game-question-footer .btn{width:100%}
 body.product-page #stage .game-question-secondary{gap:0 14px}
 body.product-page #stage .game-answer-extra-body{padding-inline:12px}
 body.product-page #stage .game-answer-extra-body textarea{font-size:16px}
}


/* One compact row per saved choice. The open row holds the actions and their outcomes. */
body.product-page.library-page .library-evenings{display:grid;gap:10px;max-width:920px}
body.product-page.library-page .library-evening{padding:0;margin:0;overflow:clip;border-color:var(--brand-line)}
body.product-page.conversation-page #library-app details.library-evening>summary{
 display:grid;grid-template-columns:48px minmax(0,1fr) 18px;gap:12px;
 min-height:80px;border:0;border-radius:0;padding:10px 16px;color:var(--brand-ink);background:var(--brand-surface)
}
body.product-page.conversation-page #library-app details.library-evening>summary:hover,
body.product-page.conversation-page #library-app details.library-evening[open]>summary{background:var(--brand-paper)}
body.product-page.conversation-page #library-app details.library-evening>summary::after{grid-column:3;grid-row:1}
body.product-page.conversation-page #library-app details.library-evening>summary:focus-visible{outline-offset:-4px}
body.product-page.library-page .library-evening>summary .library-cover{grid-column:1;grid-row:1;height:60px;border-radius:5px;overflow:hidden}
body.product-page.library-page .library-evening>summary .library-cover img{object-fit:contain}
body.product-page.library-page .library-evening>summary .library-cover small{font-size:10px;line-height:1.1}
body.product-page.library-page .evening-summary-copy{grid-column:2;grid-row:1;display:flex;flex-direction:column;gap:2px;min-width:0}
body.product-page.library-page .evening-summary-copy strong{overflow-wrap:anywhere;color:var(--brand-ink);font-size:16px}
body.product-page.library-page .evening-summary-copy span{color:var(--brand-muted);font-size:12px;font-weight:400}
body.product-page.library-page .evening-content{border-top:1px solid var(--brand-line);padding:16px 20px 20px}
body.product-page.library-page .evening-context{margin:0 0 14px;max-width:65ch;color:var(--brand-muted)}
body.product-page.library-page .evening-card{margin:0}
body.product-page.library-page .evening-card+.evening-card{margin-top:16px;padding-top:16px;border-top:1px solid var(--brand-line)}
body.product-page.library-page .evening-card h2{margin:0 0 10px}
body.product-page.library-page .evening-card .evening-decision>.btn{width:auto}
body.product-page.library-page .evening-card .evening-controls-modern{display:grid;gap:8px;margin:0;max-width:none}
body.product-page .evening-controls-modern .evening-decision,
body.product-page .evening-controls-modern .evening-chosen{display:flex;align-items:center;flex-wrap:wrap;gap:6px 12px;margin:0}
body.product-page.library-page .evening-review{margin-top:4px;padding-top:12px;border-top:1px solid var(--brand-line)}
body.product-page.library-page .evening-fit-prompt{margin:6px 0}
body.product-page.conversation-page #library-app .evening-controls details>summary{
 display:flex;justify-content:flex-start;gap:8px;padding:6px 4px;border-color:transparent;background:transparent
}
body.product-page.conversation-page #library-app .evening-controls details>summary::after{margin-inline-start:auto}
body.product-page.conversation-page #library-app .evening-controls details>summary:hover{background:var(--control-hover)}
body.product-page.library-page .evening-feedback-note .evening-reason{padding:12px;background:var(--brand-paper);border-radius:10px}
@media(max-width:600px){
 body.product-page.library-page .library-views{grid-template-columns:minmax(0,1fr) minmax(0,1fr) minmax(0,1.5fr)}
 body.product-page.library-page .library-views button{white-space:normal;line-height:1.3}
 body.product-page.library-page .evening-content{padding:12px}
}
