/* DP SHOP — dpchat widget. Tuned to the site: dark header like the top nav,
   clean white body, purple only as small accents. */
.dpchat-root{
  --dp-ink:#1d1d1f; --dp-pri:#8b4fc4; --dp-pri2:#BF78EE;
  --dp-line:#ececf1; --dp-soft:#f5f5f7; --dp-mut:#8b8794;
  position:fixed; right:20px; bottom:20px; z-index:99998; font-family:inherit;
}
.dpchat-root *{ box-sizing:border-box; }

.dpchat-fab{
  position:relative;
  width:58px; height:58px; border-radius:50%; border:0; cursor:pointer; padding:0;
  background:var(--dp-ink); color:#fff;
  box-shadow:0 6px 20px rgba(0,0,0,.28);
  display:flex; align-items:center; justify-content:center;
  transition:transform .15s ease, box-shadow .15s ease;
}
.dpchat-fab:hover{ transform:translateY(-2px); box-shadow:0 10px 26px rgba(0,0,0,.34); }
.dpchat-fab:focus{ outline:none; }
.dpchat-fab svg{ width:26px; height:26px; display:block; }
.dpchat-fab .dpchat-fab-dot{ position:absolute; top:12px; right:12px; width:9px; height:9px; border-radius:50%; background:var(--dp-pri2); box-shadow:0 0 0 2px var(--dp-ink); }
/* 12.11: phone checkout — hint instead of opening the full-screen chat */
.dpchat-tip{
  position:absolute; right:0; bottom:68px; white-space:nowrap;
  background:#fff; color:var(--dp-ink); border:1px solid var(--dp-line); border-radius:14px;
  padding:8px 12px; font-size:13px; font-weight:600; line-height:1.2; cursor:pointer;
  box-shadow:0 6px 18px rgba(0,0,0,.18);
}
.dpchat-tip:focus{ outline:none; }

.dpchat-panel{
  position:absolute; right:0; bottom:72px; width:380px; max-width:calc(100vw - 40px);
  height:560px; max-height:calc(100vh - 120px);
  background:#fff; border:1px solid var(--dp-line); border-radius:16px;
  box-shadow:0 18px 50px rgba(0,0,0,.20);
  display:flex; flex-direction:column; overflow:hidden;
  opacity:0; transform:translateY(12px) scale(.98); pointer-events:none;
  transition:opacity .18s ease, transform .18s ease;
}
.dpchat-open .dpchat-panel{ opacity:1; transform:none; pointer-events:auto; }

/* header: dark like the site's top nav, purple only as a thin top accent + status dot */
.dpchat-head{
  position:relative; display:flex; align-items:center; gap:11px; padding:14px 16px;
  background:var(--dp-ink); color:#fff;
}
.dpchat-head-ava{ flex:0 0 auto; width:32px; height:32px; border-radius:50%;
  background:rgba(255,255,255,.12); display:flex; align-items:center; justify-content:center; }
.dpchat-head-ava svg{ width:18px; height:18px; display:block; }
.dpchat-head-t{ display:flex; flex-direction:column; line-height:1.25; flex:1 1 auto; min-width:0; }
.dpchat-head-t b{ font-size:14.5px; font-weight:600; }
.dpchat-head-t span{ font-size:11.5px; color:#b9b6c2; display:flex; align-items:center; gap:5px; }
.dpchat-head-t span:before{ content:""; width:7px; height:7px; border-radius:50%; background:#3ec46d; display:inline-block; }
.dpchat-close{ border:0; background:transparent; color:#cfccd6; font-size:24px; line-height:1; cursor:pointer; padding:0 2px; }
.dpchat-close:hover{ color:#fff; }

.dpchat-msgs{
  flex:1 1 auto; overflow-y:auto; overscroll-behavior:contain; -webkit-overflow-scrolling:touch;
  padding:16px; background:#fafafa; display:flex; flex-direction:column; gap:11px;
}
.dpchat-m{ display:flex; flex-direction:column; max-width:100%; }
.dpchat-m-user{ align-items:flex-end; }
.dpchat-m-bot{ align-items:flex-start; }
.dpchat-bubble{ max-width:86%; padding:10px 13px; border-radius:14px; font-size:13.5px; line-height:1.5; word-wrap:break-word; }
.dpchat-m-user .dpchat-bubble{ background:var(--dp-ink); color:#fff; border-bottom-right-radius:5px; }
.dpchat-m-bot .dpchat-bubble{ background:#fff; color:var(--dp-ink); border:1px solid var(--dp-line); border-bottom-left-radius:5px; }

.dpchat-cards{ display:flex; flex-direction:column; gap:8px; margin-top:8px; width:86%; }
.dpchat-card{
  display:flex; gap:8px; align-items:center; padding:8px; background:#fff; border:1px solid var(--dp-line);
  border-radius:12px; transition:box-shadow .15s ease, border-color .15s ease;
}
.dpchat-card:hover{ box-shadow:0 6px 16px rgba(0,0,0,.08); border-color:#ddd6ea; }
.dpchat-card-main{ flex:1 1 auto; min-width:0; display:flex; align-items:center; gap:10px; text-decoration:none !important; }
.dpchat-card-add{
  flex:0 0 auto; width:38px; height:38px; border-radius:10px; background:var(--dp-soft); color:var(--dp-pri);
  display:flex; align-items:center; justify-content:center; text-decoration:none !important; position:relative;
  transition:background .15s ease, color .15s ease;
}
.dpchat-card-add:hover{ background:var(--dp-pri); color:#fff; }
.dpchat-card-add svg{ width:19px; height:19px; display:block; }
.dpchat-card-add .dpchat-ic-cart, .dpchat-card-add .dpchat-ic-ok{ display:inline-flex; align-items:center; }
.dpchat-card-add .dpchat-ic-ok{ display:none; }
.dpchat-card-add.dp-added{ background:#2e9e5b; color:#fff; }
.dpchat-card-add.dp-added .dpchat-ic-cart{ display:none; }
.dpchat-card-add.dp-added .dpchat-ic-ok{ display:inline-flex; }
.dpchat-card-add.dp-loading{ pointer-events:none; }
.dpchat-card-add.dp-loading .dpchat-ic-cart, .dpchat-card-add.dp-loading .dpchat-ic-ok{ opacity:0; }
.dpchat-card-add.dp-loading:after{ content:""; position:absolute; width:16px; height:16px; border:2px solid rgba(139,79,196,.3); border-top-color:var(--dp-pri); border-radius:50%; animation:dpspin .6s linear infinite; }
@keyframes dpspin{ to{ transform:rotate(360deg); } }
.dpchat-card-img{ width:52px; height:52px; flex:0 0 auto; border-radius:9px; background:var(--dp-soft) center/cover no-repeat; }
.dpchat-card-b{ display:flex; flex-direction:column; min-width:0; gap:2px; }
.dpchat-card-n{ font-size:12.5px; color:var(--dp-ink); line-height:1.25; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.dpchat-card-p{ font-size:13px; font-weight:700; color:var(--dp-pri); }
.dpchat-card-p i{ font-weight:400; color:var(--dp-mut); font-style:normal; }

.dpchat-dots{ display:inline-flex; gap:4px; padding:2px 0; }
.dpchat-dots i{ width:6px; height:6px; border-radius:50%; background:#c9c9cf; animation:dpchatb 1s infinite ease-in-out; }
.dpchat-dots i:nth-child(2){ animation-delay:.15s; } .dpchat-dots i:nth-child(3){ animation-delay:.3s; }
@keyframes dpchatb{ 0%,60%,100%{ transform:translateY(0); opacity:.5; } 30%{ transform:translateY(-4px); opacity:1; } }

.dpchat-form{ display:flex; gap:8px; padding:11px; border-top:1px solid var(--dp-line); background:#fff; }
.dpchat-input{ flex:1 1 auto; border:1px solid #e4e4e8; border-radius:22px; padding:10px 15px; font-size:13.5px; outline:none; background:var(--dp-soft); color:var(--dp-ink); }
.dpchat-input:focus{ border-color:var(--dp-pri2); background:#fff; }
.dpchat-send{ flex:0 0 auto; width:42px; height:42px; border-radius:50%; border:0; cursor:pointer; font-size:16px;
  background:var(--dp-pri); color:#fff; display:flex; align-items:center; justify-content:center; transition:background .15s ease; }
.dpchat-send:hover{ background:var(--dp-pri2); }
.dpchat-send:focus{ outline:none; }

/* ===== mobile: full-screen so scrolling stays inside the chat, not the page ===== */
@media (max-width:767px){
  .dpchat-root{ right:16px; bottom:16px; }
  .dpchat-panel{
    position:fixed; inset:0; top:0; left:0; right:0; bottom:0;
    width:100%; max-width:100%; height:100%; max-height:100%;
    border:0; border-radius:0;
  }
  .dpchat-open .dpchat-fab{ display:none; }        /* fullscreen: hide the bubble */
  .dpchat-head{ padding-top:16px; }
  .dpchat-msgs{ padding:14px; }
}
/* lock the page behind the fullscreen chat so touch-scroll can't leak to the site */
html.dpchat-locked, body.dpchat-locked{ overflow:hidden !important; }
