﻿/* Storefront conversation widget and mobile-friendly operator inbox. */
#site-chat [hidden],.chat-window [hidden],#chat-panel [hidden]{display:none!important}
.site-contact-dock{position:fixed;right:24px;bottom:calc(24px + env(safe-area-inset-bottom));z-index:45;display:flex;gap:8px;align-items:center;padding:6px;background:#fff;border:1px solid #dfebef;border-radius:999px;box-shadow:0 6px 28px #173c4d24}
.site-contact-dock a,.site-contact-dock button{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:46px;padding:10px 17px;border:0;border-radius:999px;font:600 14px/1.4 Arial,sans-serif;text-decoration:none;cursor:pointer}
.site-contact-dock .chat-launch{background:#146a80;color:#fff}.site-contact-dock .dock-whatsapp{background:#eaf6ef;color:#236347}
#chat-unread{min-width:21px;padding:2px 5px;border-radius:20px;background:#fff;color:#146a80;font-size:12px}
.chat-window{position:fixed;right:24px;bottom:calc(100px + env(safe-area-inset-bottom));z-index:46;width:390px;max-width:calc(100vw - 24px);height:620px;max-height:calc(100dvh - 130px);display:flex;flex-direction:column;background:#fff;border:1px solid #d9e6eb;border-radius:18px;box-shadow:0 16px 70px #143e5430;overflow:hidden;color:#283b45;font:15px/1.6 Arial,sans-serif}
.chat-window .chat-header{display:flex;align-items:center;justify-content:space-between;flex-shrink:0;background:#155c70;color:#fff;padding:16px 20px;gap:16px}
.chat-header strong{font-size:20px;font-weight:600}.chat-header p{font-size:12px;margin:3px 0 0;color:#e6f4f8}.chat-header button{border:0;background:#ffffff18;color:#fff;width:40px;height:40px;font-size:28px;border-radius:50%;cursor:pointer}
.chat-service-note{font-size:12px;line-height:1.65;background:#f2f8fa;color:#425e6a;margin:0;padding:12px 18px;border-bottom:1px solid #e1edf0;flex-shrink:0}
#chat-notice{font-size:13px;color:#70501e;margin:0;padding:8px 18px;flex-shrink:0}#chat-notice:empty{display:none}
.chat-start{padding:20px;overflow:auto;display:grid;gap:12px}.chat-start label{margin:0;font-size:14px}.chat-start input{width:100%;margin:0;padding:12px;border:1px solid #cbdce3;border-radius:8px;font-size:16px;min-width:0}
.chat-start button,.chat-compose>button{background:#146a80;color:#fff;border:1px solid #146a80;padding:12px 16px;border-radius:8px;font:600 14px/1.5 Arial,sans-serif;cursor:pointer;min-height:44px}.chat-start .chat-secondary{color:#335f6e;background:#fff;border-color:#cfdee5}
.chat-help{font-size:12px;line-height:1.65;color:#536b77;margin:0}.chat-thread{flex:1;min-height:80px;overflow-y:auto;overscroll-behavior:contain;padding:18px;display:flex;flex-direction:column;gap:12px;scrollbar-gutter:stable;background:#fafcfd}
.chat-bubble{max-width:88%;padding:10px 13px;border-radius:12px;overflow-wrap:anywhere;flex-shrink:0;box-sizing:border-box}.chat-bubble p{white-space:pre-wrap;margin:0;line-height:1.65;font-size:15px}.chat-bubble a{text-decoration:underline;text-underline-offset:3px}.chat-bubble time{display:block;font-size:11px;margin-top:7px;opacity:.8}.chat-mine{align-self:flex-end;background:#e2f0f5;color:#204b5c;border-bottom-right-radius:3px}.chat-theirs{align-self:flex-start;background:#fff;color:#283b45;border:1px solid #e0e9ed;border-bottom-left-radius:3px}
.chat-compose{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;background:#fff;padding:12px 16px;border-top:1px solid #e1eaee;flex-shrink:0}.chat-compose textarea{resize:vertical;min-width:0;max-width:100%;min-height:50px;max-height:130px;padding:10px;border:1px solid #cbdce3;border-radius:8px;font:16px/1.5 Arial,sans-serif;margin:0}.chat-compose>button{align-self:start}.chat-compose .chat-help{grid-column:1/-1}
.chat-bottom{display:flex;gap:16px;justify-content:center;align-items:center;flex-wrap:wrap;padding:10px 16px;border-top:1px solid #edf2f4;font-size:12px;flex-shrink:0}.chat-bottom button{font:inherit;border:0;background:transparent;text-decoration:underline;color:#536b77;cursor:pointer;padding:4px}
#site-chat :is(button,a,input,textarea):focus-visible,#chat-panel :is(button,a,input,select,textarea):focus-visible{outline:3px solid #62abc1;outline-offset:3px}
#site-chat button:disabled,#chat-panel button:disabled{opacity:.55;cursor:default}
.chat-admin-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:18px}.chat-admin-heading h2{margin:0;font-size:24px}.chat-admin-heading p{font-size:13px;margin:8px 0 0}.chat-admin-heading>span{font-size:12px;color:#416576;white-space:nowrap}
.chat-settings{display:flex;gap:12px;align-items:center;flex-wrap:wrap;padding:18px;background:#fff;border:1px solid #dce5e8;border-radius:10px}.chat-settings label{margin:0}.chat-settings select{margin:0;max-width:100%;width:auto;min-height:44px;font-size:16px}.chat-settings button{min-height:44px}.chat-settings>span{font-size:13px;color:#39654d}
.chat-admin-layout{display:grid;grid-template-columns:minmax(240px,.8fr) minmax(0,1.6fr);height:min(760px,80dvh);min-height:520px;border:1px solid #dbe5e9;background:#fff;border-radius:12px;overflow:hidden}
.chat-inbox{min-width:0;display:flex;flex-direction:column;border-right:1px solid #dbe5e9;overflow:hidden}.chat-inbox form{display:flex;gap:8px;padding:14px;border-bottom:1px solid #e4ecef}.chat-inbox input{min-width:0;margin:0;font-size:16px;flex:1;padding:10px}.chat-inbox button{min-height:44px}
#chat-conversations{overflow-y:auto;flex:1;min-height:0}#chat-conversations>p{padding:20px;font-size:14px}.chat-conversation{width:100%;display:block;text-align:left;border:0;border-bottom:1px solid #e6edef;background:#fff;padding:16px;cursor:pointer;border-radius:0;overflow-wrap:anywhere}.chat-conversation:hover{background:#f4f9fa}.chat-conversation.is-selected{background:#eaf5f8;box-shadow:inset 3px 0 #16738a}.chat-conversation strong{font-size:14px}.chat-conversation p{font-size:13px;color:#4d6571;margin:6px 0;overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}.chat-conversation small{font-size:11px;color:#577480}.chat-list-pages{display:flex;align-items:center;justify-content:space-between;padding:10px;gap:8px;border-top:1px solid #e1eaee;font-size:12px}.chat-list-pages button{padding:8px}
.chat-admin-detail{min-width:0;min-height:0;display:flex;flex-direction:column}.chat-admin-toolbar{padding:16px 20px;border-bottom:1px solid #e1eaee;min-width:0;overflow-wrap:anywhere}.chat-admin-toolbar p{font-size:12px;margin:6px 0}.chat-admin-toolbar a{font-size:12px;text-decoration:underline}#chat-back{display:none}#chat-older{align-self:center;font-size:12px;border:0;background:transparent;text-decoration:underline;padding:10px}.chat-source{display:block;font-size:11px;margin-top:7px}.chat-admin-detail .chat-compose{padding:16px}#chat-admin-error{margin:0;padding:0 16px 10px;color:#a13c2c;font-size:13px}#chat-admin-error:empty{display:none}
@media(max-width:900px){.chat-admin-layout{grid-template-columns:minmax(210px,.8fr) minmax(0,1.2fr)}.chat-admin-heading{align-items:start;flex-direction:column;gap:8px}}
@media(max-width:700px){.chat-admin-layout{display:block;height:72dvh;min-height:520px}.chat-inbox{height:100%;border:0}.chat-admin-detail{display:none;height:100%}.chat-admin-layout.detail-open .chat-inbox{display:none}.chat-admin-layout.detail-open .chat-admin-detail{display:flex}#chat-back{display:inline-flex;min-height:44px;align-items:center;background:transparent;border:0;color:#146a80;padding:0;margin-bottom:8px}.chat-settings{padding:14px;gap:10px}.chat-settings select{width:100%;white-space:normal}.chat-settings button{width:100%}.chat-admin-detail .chat-compose{padding:12px}.chat-admin-toolbar{padding:12px 16px}}
@media(max-width:600px){.site-contact-dock{right:12px;bottom:calc(12px + env(safe-area-inset-bottom));max-width:calc(100vw - 24px)}.site-contact-dock a,.site-contact-dock button{min-height:44px;font-size:13px;padding:10px 13px}.chat-window{right:12px;bottom:calc(85px + env(safe-area-inset-bottom));width:calc(100vw - 24px);max-height:calc(100dvh - 105px);height:600px;border-radius:14px}.chat-service-note{font-size:11px;padding:10px 14px}.chat-thread{padding:14px}.chat-compose{padding:10px 12px}.chat-start{padding:16px}.chat-bubble{max-width:92%}.chat-header{padding:12px 16px}.admin-sidebar{overflow-y:auto}.chat-admin-layout{min-height:480px}}
@media(prefers-reduced-motion:reduce){.chat-thread{scroll-behavior:auto}}
/* Reset generic page-header styles inside the floating conversation window. */
.chat-window .chat-header{margin:0;height:auto;min-height:76px;border-bottom:0;width:100%}
[data-chat-open][hidden]{display:none!important}
@media(max-width:600px){.chat-window .chat-header{padding:12px 16px;min-height:70px}}
.chat-product-context{margin:0;padding:10px 18px;background:#fff;border-bottom:1px solid #e1edf0;color:#425e6a;font-size:12px;line-height:1.5;overflow-wrap:anywhere;flex-shrink:0}
.admin-nav button[data-panel=chat-panel]{display:flex;align-items:center;justify-content:space-between;gap:8px}
#chat-badge[hidden]{display:none!important}
#chat-badge.has-unread{background:#df3838;color:#fff;box-shadow:0 0 0 3px #df383822}
.chat-conversation.has-unread strong::before{content:'';display:inline-block;width:8px;height:8px;border-radius:50%;background:#df3838;margin-right:8px;vertical-align:middle}
.chat-ended-note{margin:0;padding:10px 18px;background:#fff7e8;color:#73571e;font-size:13px;flex-shrink:0}
.chat-admin-toolbar>button:not(#chat-back){margin-top:10px;min-height:40px;padding:8px 14px;border:1px solid #ccdce3;border-radius:7px;background:#fff;color:#425e6a}
.email-notify-settings{margin:20px 0;padding:18px;background:#fff;border:1px solid #dce5e8;border-radius:10px}.email-notify-settings summary{cursor:pointer;font-weight:600}.email-notify-settings .admin-form{margin-top:18px;max-width:680px}.email-notify-settings input:not([type=checkbox]),.email-notify-settings textarea,.email-notify-settings select{width:100%;min-width:0;font-size:16px;min-height:44px}.email-notify-settings button{min-height:44px}#email-notify-recent{overflow-wrap:anywhere}
