.toolbar .chat-brand { display:inline-flex;align-items:center;min-height:44px;font-family:Georgia,'Times New Roman',serif;font-size:2.05rem;font-style:italic;font-weight:400;letter-spacing:-.07em;line-height:.9;color:var(--green);text-decoration:none;white-space:nowrap; }
.sophie-chat .toolbar { position:relative;gap:10px; }
.sophie-chat .chat-identity { display:flex;align-items:center;gap:9px;min-width:0;margin-right:auto; }
.sophie-chat .toolbar-note { display:none; }
#chat-voice-toggle { display:grid;place-items:center;flex:none;width:40px;height:40px;padding:5px;border:1px solid var(--green);border-radius:50%;background:var(--green);color:white; }
#chat-voice-toggle svg { width:28px;height:28px;fill:none;stroke:currentColor;stroke-width:2.4;stroke-linecap:round; }
#chat-voice-toggle[aria-pressed="true"] { background:#163b2e;box-shadow:inset 0 0 0 2px #d1e2cd; }
/* The same two-line button, paper colour and serif navigation as the website. */
.chat-menu { flex-shrink:0;color:#24211e; }
.chat-menu-toggle { width:44px;height:44px;display:grid;place-content:center;gap:6px;padding:0;border:1px solid currentColor;border-radius:0;background:transparent;color:inherit; }
.chat-menu-toggle span { display:block;width:18px;height:1px;background:currentColor;transition:transform .2s ease; }
.chat-menu-toggle[aria-expanded="true"] span:first-child { transform:translateY(3.5px) rotate(45deg); }
.chat-menu-toggle[aria-expanded="true"] span:last-child { transform:translateY(-3.5px) rotate(-45deg); }
.chat-menu-content { position:absolute;z-index:30;right:10px;top:100%;width:min(380px,calc(100vw - 40px));max-height:calc(100dvh - 90px);padding:12px 24px 24px;border:1px solid rgba(36,33,30,.16);border-radius:0;background:#f7f2e9;box-shadow:0 14px 32px #24211e20;overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable; }
.chat-menu-actions { display:grid;padding-bottom:10px;margin-bottom:2px;border-bottom:1px solid rgba(36,33,30,.16); }
.chat-menu-actions>button { display:block;width:100%;min-height:44px;padding:10px 0;text-align:left;background:none;color:inherit;border:0;font-family:Georgia,'Times New Roman',serif;font-size:1.25rem;line-height:1.35; }
.chat-site-nav ul { list-style:none;margin:0;padding:0; }
.chat-site-nav a { display:block;min-height:44px;padding:15px 0;border-bottom:1px solid rgba(36,33,30,.16);color:inherit;font-family:Georgia,'Times New Roman',serif;font-size:1.6rem;line-height:1.25;text-decoration:none;overflow-wrap:anywhere; }
.chat-site-nav .chat-site-submenu { margin-top:8px;padding-left:12px;border-left:2px solid rgba(36,33,30,.16); }
.chat-site-submenu a { padding:10px 12px;border:0;font-family:Inter,'Avenir Next',Avenir,'Helvetica Neue',Arial,sans-serif;font-size:1rem;line-height:1.4; }
.chat-site-nav a[aria-current="page"],.chat-site-nav a:hover,.chat-menu-actions>button:not(:disabled):hover { color:#7c2332; }
.chat-menu-content a:focus-visible,.chat-menu-content button:focus-visible { outline:2px solid #7c2332;outline-offset:2px; }
.chat-cart-count { display:inline-flex;align-items:center;justify-content:center;min-width:1.5em;padding:2px 6px;border-radius:20px;background:#7c2332;color:#fff;font-size:.8em; }
.chat-menu-content .modes { margin-top:16px; }
.voice-actions { flex-shrink:0;display:flex;justify-content:flex-end;padding:4px 12px; }
.voice-actions #voice-stop { min-height:44px;padding:8px 14px;border:1px solid var(--green);border-radius:9px;color:var(--green);background:#edf2e9;font-size:13px; }
@media(prefers-reduced-motion:reduce) { .chat-menu-toggle span { transition:none; } }
.sophie-chat[data-mode="chat"] #status[data-quiet="true"],.sophie-chat.is-thinking #status[data-quiet="true"],.sophie-chat .is-thinking #status[data-quiet="true"] { display:none; }
.account-proposal { margin:12px 0;padding:14px;border:1px solid #abc3a8;border-radius:12px;background:#f3f7ee;color:#214c3e;font-size:14px; }
.account-proposal small { font-size:11px;line-height:1.4; }.account-proposal h3 { margin:8px 0;font-size:17px; }
.account-proposal dl { display:grid;grid-template-columns:auto 1fr;gap:5px 12px; }.account-proposal dt { font-size:12px; }.account-proposal dd { margin:0;overflow-wrap:anywhere; }
.account-proposal-actions { display:flex;gap:8px; }.account-proposal button { min-height:44px;padding:8px 12px;background:#214c3e;color:white;border:1px solid #214c3e;border-radius:8px; }
.account-proposal button+button { background:white;color:#214c3e; }.account-proposal p:empty { display:none; }
.sophie-chat .wine-affiliate { font-size:11px;line-height:1.4;color:#6d7564;white-space:normal;margin:5px 0 12px; }
@media(min-width:761px) and (max-width:1000px) {
  .sophie-chat .toolbar { padding:6px 10px;gap:7px; }
  .sophie-chat .toolbar .version { font-size:10px;padding:3px 5px; }
  .sophie-chat .modes button { padding:7px 9px;font-size:12px; }
}
@media(max-width:760px) {
  .sophie-chat .shell { padding:0;gap:0;height:100%; }
  .sophie-chat .conversation { border:0;border-radius:0; }
  .sophie-chat .toolbar { min-height:48px;padding:2px 10px;gap:10px;padding-top:env(safe-area-inset-top,0px); }
  .sophie-chat .toolbar .chat-brand { font-size:1.8rem; }
  .sophie-chat .chat-menu-content { right:0;width:min(420px,100%);padding:8px 24px max(24px,env(safe-area-inset-bottom,0px)); }
  .sophie-chat .chat-menu-content .modes [data-mode="chat"],.sophie-chat .chat-menu-content .modes [data-mode="voice"] { display:none; }
  .sophie-chat .toolbar .version,.sophie-chat .toolbar-note { display:none; }
  .sophie-chat .messages { padding:10px 12px;scroll-behavior:auto; }
  .sophie-chat .message .text { line-height:1.4; }
  .sophie-chat .message { margin-bottom:12px;gap:7px; }
  .sophie-chat .welcome { margin:12px auto; }.sophie-chat .welcome h1 { font-size:34px; }
  .sophie-chat .composer-area { padding:5px 8px max(6px,env(safe-area-inset-bottom,0px));border-top:1px solid var(--line);background:#fffefa; }
  .sophie-chat .composer { padding:3px;gap:4px;border-radius:12px;min-height:46px; }
  .sophie-chat .composer textarea { padding:8px 7px;height:38px;min-height:38px;max-height:82px;line-height:22px;font-size:16px;resize:none;overflow-y:auto; }
  .sophie-chat #send { width:38px;height:38px;min-width:38px;border-radius:9px; }
  .sophie-chat #status { margin:3px 4px 6px;font-size:12px;min-height:0; }
  .sophie-chat .thinking-indicator { min-height:0;margin:0 0 5px;padding:5px 9px;font-size:12px; }
  .sophie-chat .voice-panel { padding:5px 10px; }.sophie-chat .voice-panel p { display:none; }.sophie-chat .wave { height:22px; }.sophie-chat .wave i:nth-child(3) { height:22px; }
  .sophie-chat .message.assistant:has(.wine-card-grid)>.badge { display:none; }
  .sophie-chat .message.assistant>.body:has(.wine-card-grid) { width:100%;max-width:100%; }
  .sophie-chat .wine-card-grid.sophie-unified-grid { display:flex!important;gap:10px;max-width:100%;overflow-x:auto;scroll-snap-type:x mandatory;overscroll-behavior-x:contain;padding:3px 0 10px;scroll-padding-left:0;align-items:stretch!important; }
  .sophie-chat .wine-card-grid.sophie-unified-grid>.sophie-unified-card { flex:0 0 calc(100% - 28px);width:calc(100% - 28px);max-width:380px;scroll-snap-align:start;grid-template-columns:62px minmax(0,1fr)!important;gap:8px;padding:10px!important;height:auto; }
  .sophie-chat .sophie-unified-card .wine-card-media { width:62px!important;height:155px!important; }
  .sophie-chat .sophie-unified-card .wine-card-body { min-height:0; }
  .sophie-chat .sophie-unified-card .wine-card-title { min-height:0;line-height:1.25!important;font-size:14px!important; }
  .sophie-chat .sophie-unified-card .wine-card-description { display:none!important; }
  .sophie-chat .sophie-unified-card .wine-card-price { margin:6px 0!important;padding:0; }
  .sophie-chat .sophie-unified-card .wine-card-unit { min-height:0;font-size:10px; }
  .sophie-chat .sophie-unified-card .wine-card-unit:empty { display:none!important; }
  .sophie-chat .sophie-unified-card .wine-card-number { width:19px;height:19px;font-size:11px;margin-bottom:4px; }
  .sophie-chat .sophie-unified-card .wine-card-button,.sophie-chat .sophie-unified-card .sp-wine-details,.sophie-chat .sophie-unified-card .sp-heart { min-height:40px!important;font-size:11px!important; }
}

/* Wine search suggestions wrap on desktop and remain stacked on small screens. */
#welcome .suggestions { flex-wrap:wrap; }
#welcome .suggestions button { max-width:100%;white-space:normal;overflow-wrap:anywhere; }

.chat-cart-shortcut{display:none}
@media(max-width:760px){.sophie-chat .chat-cart-shortcut{display:inline-flex;align-items:center;justify-content:center;gap:3px;min-width:44px;min-height:44px;color:#214c3e;text-decoration:none;flex-shrink:0}.sophie-chat .chat-cart-shortcut:focus-visible{outline:3px solid #3f7958;outline-offset:2px}.sophie-chat .chat-menu{margin-left:0}.sophie-chat .toolbar{gap:6px}.sophie-chat .wine-card-grid.sophie-unified-grid>.sophie-unified-card{flex-basis:calc(100% - 42px);width:calc(100% - 42px)}}
