/*
 mamapapa -- questions.css: Xiao Chen's question badge + question card
 (task #2135; SPEC sec.0 and the Xiao Chen "Asking good questions" rules:
 one question at a time, 2-3 big answers plus 'Not sure - ask Joseph',
 say back what changed). Kept OUT of app.css on purpose: an open design
 row owns that file. mp_head() loads this on every page after app.css.
 Colours come from the app's own tokens; no raw hex added.
*/

/* the 小陈 circle hosts the badge (it is the button's only stable child) */
.xc-circle { position: relative; }

/* red '1' badge while a question is open (data-q="1" on #xc-btn) */
.xc-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 28px;
  height: 28px;
  padding: 0 7px;
  border-radius: 14px;
  background: var(--c-bad);
  border: 3px solid var(--card);
  box-sizing: border-box;
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  line-height: 22px;
  text-align: center;
  animation: xc-q-pulse 2.4s ease-in-out infinite;
}
/* a gentle pulse only; phones that ask for reduced motion get none */
@keyframes xc-q-pulse {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.1); }
  100% { transform: scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .xc-badge { animation: none; }
}

/* the open question is the last Xiao Chen bubble, full width so its
   answer buttons have room (SPEC sec.0: big buttons, words, one question) */
.xc-msg.xc-xc .xc-bubble.xc-qcard {
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
}
.xc-qtext { font-size: 22px; }
.xc-qzh {
  margin-top: 4px;
  font-size: 19px;
  color: var(--ink-soft);
}
.xc-qopts {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}
.xc-qopt {
  display: block;
  width: 100%;
  min-height: 64px;
  padding: 12px 16px;
  border: 2px solid var(--line);
  border-radius: 14px;
  background: var(--card);
  color: var(--ink);
  font-family: inherit;
  font-size: 22px;
  line-height: 1.3;
  font-weight: 600;
  text-align: left;
  box-sizing: border-box;
}
.xc-qopt:active { background: var(--line); }
.xc-qopt[disabled] { opacity: 0.5; }
/* lang=both: the Chinese line sits under the English words on one button */
.xc-qopt .xc-qopt-zh {
  display: block;
  margin-top: 2px;
  font-size: 19px;
  font-weight: 400;
  color: var(--ink-soft);
}
