/* Yiyuan Ceramics — on-site chat widget */
.yyc-launch,
.yyc-panel,
.yyc-panel * { box-sizing: border-box; }

.yyc-launch {
  position: fixed;
  right: 24px;
  bottom: 88px;
  z-index: 10010;
  width: 54px;
  height: 54px;
  border: 0;
  border-radius: 50%;
  background: #E2541D;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(0, 0, 0, .22);
  transition: transform .18s ease, background .18s ease;
}
.yyc-launch:hover { background: #C94714; transform: translateY(-2px); }
.yyc-launch svg { display: block; }
.yyc-launch .yyc-dot {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #4CAF50;
  border: 2px solid #fff;
}

.yyc-panel {
  position: fixed;
  right: 24px;
  bottom: 154px;
  z-index: 10020;
  width: 372px;
  max-width: calc(100vw - 32px);
  height: 540px;
  max-height: calc(100vh - 190px);
  background: #fff;
  border: 1px solid #DFDFDA;
  border-radius: 4px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, .18);
  display: none;
  flex-direction: column;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  color: #1C1B19;
}
.yyc-panel.is-open { display: flex; }

.yyc-head {
  background: #1C1B19;
  color: #fff;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.yyc-head .yyc-mark {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #E2541D;
  color: #fff;
  font: 700 12px/30px Georgia, serif;
  text-align: center;
  flex: 0 0 30px;
}
.yyc-head b { display: block; font-size: 14px; font-weight: 600; letter-spacing: .01em; }
.yyc-head span { display: block; font-size: 11.5px; color: #B9B8B2; margin-top: 2px; }
.yyc-close {
  margin-left: auto;
  background: none;
  border: 0;
  color: #CFCEC8;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 4px;
}
.yyc-close:hover { color: #fff; }

.yyc-body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 16px 14px 8px;
  background: #F7F7F5;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.yyc-msg {
  max-width: 84%;
  padding: 10px 13px;
  border-radius: 3px;
  font-size: 13.5px;
  line-height: 1.5;
  white-space: pre-wrap;
  word-wrap: break-word;
}
.yyc-msg.in {
  align-self: flex-start;
  background: #fff;
  border: 1px solid #E4E3DE;
  color: #2C2B28;
}
.yyc-msg.out {
  align-self: flex-end;
  background: #E2541D;
  color: #fff;
}
.yyc-msg.sys {
  align-self: center;
  background: transparent;
  border: 0;
  color: #9A9992;
  font-size: 11.5px;
  padding: 2px 8px;
  text-align: center;
}
.yyc-msg a { color: inherit; text-decoration: underline; }

.yyc-who {
  font-size: 10.5px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #9A9992;
  margin: 2px 0 -6px 2px;
}

.yyc-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 14px 8px;
  background: #F7F7F5;
}
.yyc-quick button {
  border: 1px solid #D8D7D1;
  background: #fff;
  color: #33322F;
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  cursor: pointer;
}
.yyc-quick button:hover { border-color: #E2541D; color: #E2541D; }

.yyc-lead {
  padding: 10px 14px 12px;
  background: #F7F7F5;
  border-top: 1px dashed #E0DFD9;
  display: none;
  gap: 6px;
  flex-wrap: wrap;
}
.yyc-lead.on { display: flex; }
.yyc-lead input {
  flex: 1 1 46%;
  min-width: 0;
  border: 1px solid #D8D7D1;
  background: #fff;
  padding: 8px 10px;
  font-size: 12.5px;
  font-family: inherit;
  color: #1C1B19;
  border-radius: 2px;
}
.yyc-lead button {
  flex: 1 1 100%;
  border: 0;
  background: #1C1B19;
  color: #fff;
  padding: 9px 12px;
  font-size: 12.5px;
  letter-spacing: .04em;
  cursor: pointer;
  border-radius: 2px;
}
.yyc-lead button:hover { background: #2C2925; }

.yyc-foot {
  border-top: 1px solid #E4E3DE;
  background: #fff;
  padding: 10px 12px;
  display: flex;
  gap: 8px;
  align-items: flex-end;
}
.yyc-foot textarea {
  flex: 1 1 auto;
  resize: none;
  border: 1px solid #D8D7D1;
  border-radius: 2px;
  padding: 9px 10px;
  font: 13.5px/1.4 inherit;
  font-family: inherit;
  color: #1C1B19;
  max-height: 96px;
  min-height: 40px;
}
.yyc-foot textarea:focus { outline: 2px solid #E2541D; outline-offset: -1px; }
.yyc-send {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 2px;
  background: #E2541D;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.yyc-send:disabled { opacity: .5; cursor: default; }

.yyc-note {
  font-size: 10.5px;
  color: #9A9992;
  padding: 0 12px 8px;
  background: #fff;
    text-align: center;
}
.yyc-note a { color: #9A9992; }

@media (max-width: 760px) {
  .yyc-launch { right: 16px; bottom: 84px; width: 50px; height: 50px; }
  .yyc-panel {
    right: 8px;
    left: 8px;
    bottom: 8px;
    width: auto;
    height: auto;
    top: 72px;
    max-height: none;
    padding-bottom: env(safe-area-inset-bottom);
  }
}
