/* CAFE_CHAT_V1_STYLE_20261004 */

#cafeChatBubbleV1,
#panelChatBubbleV1{
  position:fixed;
  right:18px;
  bottom:92px;
  z-index:2147483000;
  width:58px;
  height:58px;
  border:0;
  border-radius:50%;
  background:#009b91;
  color:#fff;
  font-size:27px;
  box-shadow:
    0 10px 30px rgba(0,0,0,.22),
    inset 0 1px 0 rgba(255,255,255,.25);
  cursor:pointer;
}

#panelChatBubbleV1{
  left:18px;
  right:auto;
  bottom:20px;
}

#cafeChatBubbleV1[hidden],
#panelChatBubbleV1[hidden]{
  display:none!important;
}

#cafeChatBadgeV1,
#panelChatBadgeV1{
  display:none;
  position:absolute;
  min-width:20px;
  height:20px;
  padding:0 5px;
  border-radius:999px;
  background:#e3293b;
  color:#fff;
  border:2px solid #fff;
  font-size:11px;
  line-height:16px;
  font-weight:900;
  top:-3px;
  right:-3px;
}

#cafeChatBadgeV1.show,
#panelChatBadgeV1.show{
  display:block;
}

#cafeChatDrawerV1,
#panelChatDrawerV1{
  position:fixed;
  left:0;
  right:0;
  bottom:0;
  z-index:2147482999;
  height:min(62vh,620px);
  background:#f6faf9;
  border-radius:26px 26px 0 0;
  box-shadow:0 -12px 45px rgba(0,0,0,.24);
  transform:translateY(105%);
  transition:transform .22s ease;
  direction:rtl;
  display:flex;
  flex-direction:column;
  overflow:hidden;
  font-family:inherit;
}

#panelChatDrawerV1{
  width:min(430px,100vw);
  left:0;
  right:auto;
  border-radius:26px 26px 0 0;
}

#cafeChatDrawerV1.open,
#panelChatDrawerV1.open{
  transform:translateY(0);
}

.cafe-chat-head{
  flex:0 0 auto;
  min-height:64px;
  padding:12px 16px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  background:linear-gradient(135deg,#008d84,#00aaa0);
  color:#fff;
}

.cafe-chat-head>div{
  display:flex;
  flex-direction:column;
  gap:2px;
}

.cafe-chat-head b{
  font-size:17px;
  font-weight:900;
}

.cafe-chat-head small{
  font-size:11px;
  opacity:.88;
}

.cafe-chat-head>button{
  width:38px;
  height:38px;
  border:0;
  border-radius:50%;
  background:rgba(255,255,255,.18);
  color:#fff;
  font-size:18px;
  cursor:pointer;
}

.cafe-chat-body{
  flex:1 1 auto;
  min-height:0;
  overflow:auto;
  padding:13px;
  background:
    linear-gradient(
      180deg,
      rgba(225,246,243,.85),
      rgba(247,250,250,.96)
    );
}

.cafe-chat-message{
  width:max-content;
  max-width:86%;
  margin:7px 0;
  padding:9px 11px;
  border-radius:15px 15px 5px 15px;
  background:#fff;
  box-shadow:0 3px 10px rgba(0,0,0,.08);
  color:#26383a;
}

.cafe-chat-message.mine{
  margin-right:auto;
  background:#d6f3ef;
  border-radius:15px 15px 15px 5px;
}

.cafe-chat-message.agent{
  border-right:4px solid #008d84;
}

.cafe-chat-message.master{
  border-right:4px solid #d6a42d;
  background:#fff9e8;
}

.cafe-chat-meta{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  margin-bottom:4px;
}

.cafe-chat-meta b{
  color:#008d84;
  font-size:12px;
}

.cafe-chat-message.master .cafe-chat-meta b{
  color:#a57300;
}

.cafe-chat-meta span{
  font-size:9px;
  color:#839091;
}

.cafe-chat-text{
  font-size:14px;
  line-height:1.65;
  white-space:normal;
  overflow-wrap:anywhere;
}

.cafe-chat-composer{
  flex:0 0 auto;
  display:flex;
  align-items:flex-end;
  gap:8px;
  padding:10px;
  padding-bottom:max(10px,env(safe-area-inset-bottom));
  background:#fff;
  border-top:1px solid #d9e8e6;
}

.cafe-chat-composer[hidden]{
  display:none!important;
}

.cafe-chat-composer textarea{
  flex:1;
  resize:none;
  min-height:44px;
  max-height:100px;
  border:1px solid #b8d6d3;
  border-radius:18px;
  padding:10px 13px;
  outline:none;
  font:inherit;
  direction:rtl;
  background:#f8fbfb;
}

.cafe-chat-composer textarea:focus{
  border-color:#009b91;
  box-shadow:0 0 0 3px rgba(0,155,145,.10);
}

.cafe-chat-composer button{
  min-width:72px;
  min-height:44px;
  border:0;
  border-radius:16px;
  background:#009b91;
  color:#fff;
  font:inherit;
  font-weight:900;
  cursor:pointer;
}

.cafe-chat-empty{
  margin:25px auto;
  max-width:310px;
  text-align:center;
  color:#708284;
  background:#fff;
  border:1px dashed #b8d5d2;
  border-radius:16px;
  padding:20px;
}

.cafe-chat-bind{
  max-width:350px;
  margin:20px auto;
  background:#fff;
  border-radius:20px;
  padding:20px;
  text-align:center;
  box-shadow:0 8px 25px rgba(0,0,0,.07);
}

.cafe-chat-bind .cafe-chat-lock{
  font-size:38px;
}

.cafe-chat-bind h3{
  margin:8px 0;
  color:#15595a;
}

.cafe-chat-bind p{
  color:#687c7e;
  font-size:13px;
  line-height:1.7;
}

.cafe-chat-bind input{
  width:100%;
  box-sizing:border-box;
  min-height:46px;
  border:1px solid #b8d6d3;
  border-radius:15px;
  padding:10px 12px;
  text-align:center;
  font:inherit;
  margin:8px 0;
}

.cafe-chat-bind button{
  width:100%;
  min-height:46px;
  border:0;
  border-radius:15px;
  background:#009b91;
  color:#fff;
  font:inherit;
  font-weight:900;
}

.cafe-chat-bind small{
  display:block;
  margin-top:14px;
  color:#889597;
  font-size:10px;
  line-height:1.6;
}

.panel-chat-tabs{
  flex:0 0 auto;
  display:flex;
  gap:6px;
  padding:8px;
  background:#fff;
  border-bottom:1px solid #dce9e7;
}

.panel-chat-tabs:empty{
  display:none;
}

.panel-chat-tabs button{
  flex:1;
  border:0;
  border-radius:11px;
  padding:9px;
  background:#eef5f4;
  color:#466;
  font:inherit;
  cursor:pointer;
}

.panel-chat-tabs button.active{
  background:#009b91;
  color:#fff;
  font-weight:900;
}

.panel-chat-conversation{
  width:100%;
  border:0;
  border-bottom:1px solid #dce9e7;
  background:#fff;
  padding:12px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  text-align:right;
  font:inherit;
  cursor:pointer;
}

.panel-chat-conversation>div:first-child{
  display:flex;
  flex-direction:column;
  gap:3px;
}

.panel-chat-conversation b{
  color:#164f52;
}

.panel-chat-conversation small{
  color:#899;
  font-size:10px;
}

.panel-chat-preview{
  min-width:100px;
  max-width:45%;
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:6px;
}

.panel-chat-preview span{
  overflow:hidden;
  white-space:nowrap;
  text-overflow:ellipsis;
  color:#788;
  font-size:11px;
}

.panel-chat-preview i{
  min-width:20px;
  height:20px;
  line-height:20px;
  text-align:center;
  border-radius:50%;
  background:#e3293b;
  color:#fff;
  font-size:10px;
  font-style:normal;
}

.panel-chat-delete{
  border:0;
  background:transparent;
  color:#be3444;
  font-size:10px;
  margin-top:6px;
  cursor:pointer;
}

@media(max-width:600px){

  #cafeChatBubbleV1{
    right:14px;
    bottom:84px;
    width:54px;
    height:54px;
  }

  #cafeChatDrawerV1{
    height:58vh;
  }

  #panelChatDrawerV1{
    width:100vw;
  }
}

/* DABERNA_SUPPORT_FLOW_V2 */
#cafeChatDrawerV1{height:min(82dvh,760px)}
#cafeChatBubbleV1{z-index:2147482998}
#cafeChatDrawerV1.open~#cafeChatBubbleV1{display:none}
#cafeChatQuickV1[hidden]{display:none!important}
#cafeChatQuickV1{flex:0 1 auto;overflow-y:auto;max-height:52%;padding:12px 14px;box-sizing:border-box;border-top:1px solid #d9e8e6;background:#fff;direction:rtl;display:block}
.cafe-support-welcome{background:#eaf8f6;border-radius:14px;padding:12px;font-size:13px;line-height:1.7;color:#194a4a}
.cafe-support-welcome p,.cafe-support-answer p{margin:5px 0 0}
.cafe-support-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;margin:12px 0}
.cafe-support-grid button{min-width:0;min-height:52px;padding:8px 5px;border:1px solid #c9dedb;border-radius:13px;background:#f8fbfb;color:#174a49;font:inherit;font-size:13px;cursor:pointer;white-space:normal;overflow-wrap:anywhere}
.cafe-support-grid button.chosen{border-color:#009b91;background:#def5f0}
.cafe-support-answer{background:#f2f5f5;border-radius:14px;padding:11px 12px;line-height:1.8;font-size:13px;color:#243c3c}
.cafe-support-question{margin:10px 0 7px;font-weight:700;font-size:13px}
.cafe-support-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.cafe-support-actions button{min-height:44px;border:1px solid #009b91;background:#fff;border-radius:12px;color:#007a72;font:inherit;font-size:12px;cursor:pointer;padding:5px}
.cafe-support-status{padding:9px;margin-top:8px;border-radius:10px;background:#eaf8f6;font-size:13px}
@media(max-width:600px){#cafeChatDrawerV1{height:84dvh}#cafeChatQuickV1{max-height:56%}}

/* DABERNA_SUPPORT_V3 */
.cafe-chat-attach-v3{display:inline-flex;align-items:center;justify-content:center;cursor:pointer;min-width:36px;font-size:22px;padding:5px}
.cafe-chat-attach-v3[hidden]{display:none!important}
.cafe-chat-file-v3{display:block;max-width:100%;overflow-wrap:anywhere;border:1px solid #0b8f88;border-radius:9px;padding:7px 10px;background:#e6f8f5;color:#075a55;cursor:pointer;margin-top:5px}
#panelChatFaqV3{font-size:11px;border-radius:8px;padding:6px;max-width:120px}
#panelChatFaqV3[hidden]{display:none!important}

/* CHAT_SEPARATION_V1_20261011 */
#cafeChatBubbleV1 {
  box-sizing: border-box; display: inline-flex; align-items: center;
  justify-content: center; gap: 8px; width: auto; min-width: 58px;
  max-width: calc(100vw - 36px); height: 54px; padding: 0 14px;
  border-radius: 999px; font-size: 14px; font-weight: 900; white-space: nowrap;
}
#cafeChatBubbleV1 .cafe-chat-bubble-icon { font-size: 23px; line-height: 1; }
#cafeChatBubbleV1 .cafe-chat-bubble-label { font-size: 12px; }
#cafeChatBubbleV1[data-chat-context="private"] { background: #234f79; }
#cafeChatBubbleV1[data-chat-context="group"] { background: #6941c6; }
#cafeChatDrawerV1[data-chat-context="private"] .cafe-chat-head {
  background: linear-gradient(135deg, #183b5b, #2b6594);
}
#cafeChatDrawerV1[data-chat-context="group"] .cafe-chat-head {
  background: linear-gradient(135deg, #50309e, #7953d2);
}

/* CHAT_COMPACT_V2_20261011 */
#cafeChatBubbleV1 {
  min-width: 46px; height: 42px; padding: 0 10px; gap: 5px;
  border-radius: 22px; font-size: 12px;
  box-shadow: 0 5px 14px rgba(0,0,0,.17);
}
#cafeChatBubbleV1 .cafe-chat-bubble-icon { font-size: 18px; }
#cafeChatBubbleV1 .cafe-chat-bubble-label { font-size: 10px; }
#cafeChatBubbleV1[data-chat-context="private"] { background: #bd650b; }
#cafeChatBubbleV1[data-chat-context="group"] { background: #008b81; }
#cafeChatDrawerV1[data-chat-context="private"] .cafe-chat-head {
  background: linear-gradient(135deg, #914600, #d98218);
}
#cafeChatDrawerV1[data-chat-context="group"] .cafe-chat-head {
  background: linear-gradient(135deg, #006a63, #00a99d);
}

/* CHAT_AGENT_SITE_BACKGROUND_V3 */
#cafeChatBubbleV1[data-chat-context="private"] {
  background: #f2f7f6;
  color: #164f52;
  border: 1px solid #c8ddda;
  box-shadow: 0 5px 14px rgba(22,79,82,.16);
}
#cafeChatDrawerV1[data-chat-context="private"] .cafe-chat-head {
  background: #f2f7f6;
  color: #164f52;
  border-bottom: 1px solid #d7e7e4;
}
#cafeChatDrawerV1[data-chat-context="private"] .cafe-chat-head>button {
  background: #deece9;
  color: #164f52;
}
