/* Only floating conversation windows; no document/page theme modifications. */
.workspace-window.cf-chat-refined{border:1px solid var(--cf-gold)!important;box-shadow:0 10px 28px #0006!important;color:var(--cf-fg)!important;background:transparent!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important}
.workspace-window.cf-chat-refined .w-title{background:linear-gradient(120deg,var(--cf-accent),#241b20)!important;border-bottom:1px solid var(--cf-gold)!important;box-shadow:none!important;gap:4px}
.workspace-window.cf-chat-refined .w-title button{background:transparent!important;border:1px solid transparent!important;box-shadow:none!important;color:#efd5a7!important;min-width:29px;min-height:29px;padding:3px 5px!important}
.workspace-window.cf-chat-refined .w-title button:hover,.workspace-window.cf-chat-refined .w-title button:focus-visible{border-color:var(--cf-gold)!important;background:#ffffff12!important}
.workspace-window.cf-chat-refined .w-title strong{color:var(--cf-title-fg)!important}
.workspace-window.cf-chat-refined .w-body{background:rgba(var(--cf-pane-rgb),var(--cf-alpha))!important;color:var(--cf-fg)!important;font-family:var(--cf-font-family)!important;font-size:var(--cf-font-size)!important;font-weight:var(--cf-weight)!important;line-height:var(--cf-lineheight)!important}
.workspace-window.cf-chat-refined .w-body .w-message,.workspace-window.cf-chat-refined .w-body .w-message p{font:inherit!important;color:inherit!important;line-height:inherit!important}
.workspace-window.cf-chat-refined .w-body .w-message strong{color:var(--cf-name-color)!important;font-family:var(--cf-font-family)!important}
.workspace-window.cf-chat-refined .w-bottom{background:rgba(var(--cf-pane-rgb),var(--cf-alpha))!important;border-top:1px solid var(--cf-gold)!important;color:var(--cf-fg)!important}
.workspace-window.cf-chat-refined .w-body .w-message{background:rgba(var(--cf-card-rgb),var(--cf-card-alpha))!important;border-left:2px solid var(--cf-gold)!important;border-radius:6px!important;box-shadow:none!important}
.workspace-window.cf-chat-refined .w-body .w-message small,.workspace-window.cf-chat-refined .w-body .media-caption{color:var(--cf-muted)!important}
.workspace-window.cf-chat-refined .w-bottom input[type=text]{background:rgba(var(--cf-input-rgb),var(--cf-input-alpha))!important;color:var(--cf-input-fg)!important;border:1px solid var(--cf-gold)!important}
.workspace-window.cf-chat-refined .w-bottom input[type=text]::placeholder{color:color-mix(in srgb,var(--cf-input-fg) 55%, transparent)!important}
.workspace-window.cf-chat-refined .w-bottom .upload-trigger{background:var(--cf-accent)!important;border:1px solid var(--cf-gold)!important;color:#fff0d7!important}
.workspace-window.cf-chat-refined .w-bottom .upload-trigger:hover,.workspace-window.cf-chat-refined .w-bottom .upload-trigger:focus-visible{filter:brightness(1.08)}
.workspace-window.cf-chat-refined .w-bottom .chat-compose button[type=submit]{color:#fff0d7!important}
.workspace-window.cf-chat-refined .w-body .w-message img.chat-upload{border-color:var(--cf-gold)!important}
.workspace-window.cf-chat-refined .cf-jester-notice summary,.workspace-window.cf-chat-refined .cf-jester-notice-copy{color:var(--cf-fg)!important}
.workspace-window.cf-chat-refined .cf-jester-notice summary{background:rgba(var(--cf-pane-rgb),min(1,var(--cf-alpha) + .06))!important}
.workspace-window.cf-chat-refined .cf-jester-notice-copy{background:rgba(var(--cf-card-rgb),max(.08,var(--cf-card-alpha) - .18))!important}

.workspace-window.cf-chat-refined .chat-compose input{font-family:var(--cf-font-family)!important;font-size:var(--cf-font-size)!important}
.workspace-window.cf-chat-refined .w-bottom .chat-compose button{background:var(--cf-accent)!important;border-color:var(--cf-gold)!important}
.workspace-window.cf-chat-refined .w-options[hidden]{display:none!important}
.workspace-window.cf-chat-refined .cf-jester-notice{background:rgba(var(--cf-pane-rgb),var(--cf-alpha))!important;color:var(--cf-fg)!important;border-color:var(--cf-gold)!important}
.workspace-window.cf-chat-refined .cf-preferences-menu{position:absolute;z-index:22;top:43px;right:5px;width:min(290px,calc(100% - 12px));max-height:min(70vh,540px);overflow:auto;padding:12px;background:#251c20;color:#f5e6d4;border:1px solid #b99b71;border-radius:7px;box-shadow:0 10px 28px #000a;font:13px/1.4 system-ui,sans-serif;display:grid;gap:9px}
.workspace-window.cf-chat-refined .cf-preferences-menu[hidden]{display:none!important}
.cf-preferences-menu .cf-pref-heading{display:flex;justify-content:space-between;align-items:center;font-weight:700;color:#f5d7a8}
.cf-preferences-menu label{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap}
.cf-preferences-menu select,.cf-preferences-menu input[type=range]{min-width:100px;max-width:155px;flex:1;accent-color:#c5a071}
.cf-preferences-menu select{color:#f6e8d7;background:#352831;border:1px solid #947d64;padding:5px;border-radius:3px}
.cf-preferences-menu small{color:#d5bca6;line-height:1.35}
.cf-preferences-menu .cf-pref-divider{border-top:1px solid #8e715d66}
.cf-preferences-menu .cf-pref-check{justify-content:flex-start}
.cf-preferences-menu .cf-pref-close{color:#f4d7a8;background:none;border:0;cursor:pointer;font-size:20px}
@media(max-width:700px){.workspace-window.cf-chat-refined .cf-preferences-menu{right:4px;max-height:55vh}}

.cf-preferences-menu .cf-pref-action{min-height:31px;text-align:center;background:#483041!important;color:#f5e5cb!important;border:1px solid #a58a65!important;border-radius:5px!important;cursor:pointer}
.cf-preferences-menu .cf-pref-action:hover,.cf-preferences-menu .cf-pref-action:focus-visible{background:#624057!important}
.cf-preferences-menu .cf-pref-name{width:100%;min-width:100px;max-width:155px;padding:5px;background:#352831;color:#fff0dc;border:1px solid #947d64;border-radius:3px}
.cf-preferences-menu .cf-pref-status:empty{display:none}

/* Preferences are portaled to the page while open, to avoid window clipping. */
body > .cf-preferences-menu{position:fixed;z-index:2147483000;box-sizing:border-box;overflow-y:auto;overscroll-behavior:contain;padding:12px;background:#251c20;color:#f5e6d4;border:1px solid #b99b71;border-radius:7px;box-shadow:0 10px 28px #000a;font:13px/1.4 system-ui,sans-serif;display:grid;gap:9px;min-height:0}
body > .cf-preferences-menu[hidden]{display:none!important}
