/* ============================================================
   MEZEN HOMEPAGE WIDGET — Standalone CSS
   Include this when embedding #mhw-root outside homepage.html
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700&display=swap');

/* CSS custom properties scoped to the widget root */
#mhw-root {
  --ink:   #111118;
  --slate: #6B6C75;
  --linen: #F2F0EB;
  --rule:  #E2E0DB;
  --teal:  #00BEB2;

  width: 100%;
  max-width: 760px;
  height: 540px;
  border-radius: 16px;
  border: 1px solid var(--rule);
  background: #fff;
  box-shadow: 0 4px 32px rgba(0,0,0,0.07), 0 1px 4px rgba(0,0,0,0.04);
  display: flex; flex-direction: column; overflow: hidden;
  font-family: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.mhw-messages {
  flex: 1;
  overflow-y: auto;
  padding: 24px 20px 12px;
  display: flex; flex-direction: column; gap: 10px;
  scroll-behavior: smooth;
}
.mhw-messages::-webkit-scrollbar { width: 4px; }
.mhw-messages::-webkit-scrollbar-track { background: transparent; }
.mhw-messages::-webkit-scrollbar-thumb { background: #E2E0DB; border-radius: 2px; }

.mhw-msg {
  max-width: 82%;
  padding: 11px 15px;
  border-radius: 3px 14px 14px 14px;
  font-size: 15px; line-height: 1.6; font-weight: 400;
  animation: mhw-fade-in 180ms ease both;
}
.mhw-msg--ai {
  align-self: flex-start;
  background: #F4F5F7;
  color: var(--ink);
  text-align: left;
}
.mhw-msg--muted {
  color: var(--slate);
  background: #F7F8FA;
}
.mhw-msg--user {
  align-self: flex-end;
  background: #EAECEF;
  color: var(--ink);
  border-radius: 14px 14px 3px 14px;
}

.mhw-typing {
  align-self: flex-start;
  display: flex; align-items: center; gap: 4px;
  padding: 12px 15px;
  background: #F4F5F7;
  border-radius: 3px 14px 14px 14px;
  animation: mhw-fade-in 180ms ease both;
}
.mhw-typing span {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--slate); opacity: 0.5;
  animation: mhw-dot 1.2s infinite both;
}
.mhw-typing span:nth-child(2) { animation-delay: 0.2s; }
.mhw-typing span:nth-child(3) { animation-delay: 0.4s; }

.mhw-bottom {
  flex-shrink: 0;
  border-top: 1px solid var(--rule);
  background: #fff;
  overflow: hidden;
}

.mhw-card-header {
  display: flex; align-items: flex-start;
  justify-content: space-between; gap: 12px;
  padding: 13px 20px 10px;
  border-bottom: 1px solid #F0F0EE;
}
.mhw-card-q {
  font-size: 13.5px; font-weight: 600;
  color: var(--ink); flex: 1; line-height: 1.4;
}
.mhw-card-nav {
  font-size: 11px; font-weight: 500;
  color: var(--slate); white-space: nowrap;
  flex-shrink: 0; padding-top: 2px;
  letter-spacing: 0.03em;
}

.mhw-opt-list {
  overflow-y: auto;
  max-height: 176px;
}
.mhw-opt-list::-webkit-scrollbar { width: 3px; }
.mhw-opt-list::-webkit-scrollbar-thumb { background: #E2E0DB; border-radius: 2px; }

.mhw-opt {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 20px;
  border-bottom: 1px solid #F4F4F2;
  cursor: pointer;
  transition: background 80ms;
  animation: mhw-fade-in 140ms ease both;
}
.mhw-opt:last-child { border-bottom: none; }
.mhw-opt:hover { background: var(--linen); }
.mhw-opt--selected { background: var(--linen); cursor: default; }
.mhw-opt--disabled { pointer-events: none; opacity: 0.38; }

.mhw-opt-num {
  width: 24px; height: 24px; border-radius: 50%;
  background: #EDEDEB;
  font-size: 11.5px; font-weight: 600; color: var(--ink);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.mhw-opt-text {
  flex: 1; font-size: 13.5px; color: var(--ink); line-height: 1.4;
}
.mhw-opt-arrow {
  color: var(--slate); opacity: 0;
  font-size: 14px; flex-shrink: 0;
  transition: opacity 80ms;
}
.mhw-opt:hover .mhw-opt-arrow { opacity: 1; }

.mhw-other-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 20px;
  border-top: 1px solid #F0F0EE;
  background: #FAFAF8;
  cursor: text;
}
.mhw-other-icon { color: var(--slate); flex-shrink: 0; }
.mhw-other-inp {
  flex: 1; border: none; background: transparent; outline: none;
  font-family: 'Manrope', sans-serif;
  font-size: 13.5px; color: var(--ink);
}
.mhw-other-inp::placeholder { color: #B0B3BC; }
.mhw-other-send {
  padding: 5px 12px; border-radius: 7px; border: none;
  background: var(--teal); color: #fff;
  font-family: 'Manrope', sans-serif;
  font-size: 13px; font-weight: 600;
  cursor: pointer; display: none;
}
.mhw-other-send:hover { background: #009D92; }

.mhw-starter-row {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 20px;
}
.mhw-starter-icon { color: var(--slate); flex-shrink: 0; }
.mhw-starter-inp {
  flex: 1; border: none; background: transparent; outline: none;
  font-family: 'Manrope', sans-serif;
  font-size: 14px; color: var(--ink);
}
.mhw-starter-inp::placeholder { color: #B0B3BC; }
.mhw-starter-cta {
  padding: 7px 16px; border-radius: 8px; border: none;
  background: var(--teal); color: #fff;
  font-family: 'Manrope', sans-serif;
  font-size: 13px; font-weight: 600;
  cursor: pointer; white-space: nowrap;
  transition: background 120ms; flex-shrink: 0;
}
.mhw-starter-cta:hover { background: #009D92; }

.mhw-cta-btn {
  display: block; width: 100%; padding: 13px 20px;
  border: none; background: var(--teal); color: #fff;
  font-family: 'Manrope', sans-serif;
  font-size: 14px; font-weight: 600;
  cursor: pointer; transition: background 120ms;
  text-align: center;
}
.mhw-cta-btn:hover:not(:disabled) { background: #009D92; }
.mhw-cta-btn:disabled { opacity: 0.6; cursor: default; }

.mhw-value-insert {
  align-self: stretch;
  background: #F0F9F8;
  border: 1px solid #C4EAE8;
  border-radius: 12px;
  padding: 18px 20px;
  animation: mhw-fade-in 220ms ease both;
}
.mhw-vi-title {
  font-size: 13.5px; font-weight: 700;
  color: var(--ink); margin-bottom: 10px;
  letter-spacing: -0.01em;
}
.mhw-vi-body { font-size: 13px; color: #4B4C54; line-height: 1.65; }
.mhw-vi-body p { margin: 0; }
.mhw-vi-body p + p { margin-top: 9px; }
.mhw-vi-ul {
  margin: 8px 0 0; padding: 0; list-style: none;
}
.mhw-vi-ul li {
  padding: 3px 0 3px 16px;
  position: relative; font-size: 13px; color: #4B4C54;
}
.mhw-vi-ul li::before {
  content: '•'; position: absolute; left: 0;
  color: var(--teal); font-weight: 700;
}

@keyframes mhw-fade-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes mhw-dot {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.3; }
  40%            { transform: scale(1);   opacity: 1; }
}

@media (max-width: 640px) {
  #mhw-root { height: 480px; }
  .mhw-msg { font-size: 14px; }
  .mhw-opt-text { font-size: 13px; }
  .mhw-card-q { font-size: 13px; }
}
