/* Emotibears colour by numbers — self-contained styles, matching jigsaw.css / wordsearch.css. */
.eb-cbn {
  --eb-charcoal: var(--ink, #3A342E);
  --eb-heading: var(--navy, #3A342E);
  --eb-btn: var(--coral-btn, #CE491A);
  --eb-btn-shadow: var(--coral-btn-shadow, #A93C15);
  --eb-sky: #4FB6E0;
  --eb-sunshine: #FFC845;
  --eb-board: var(--cream-2, #F3E7D6);
  --eb-line: #E2D2BC;
  font-family: "Nunito Sans", system-ui, sans-serif;
  color: var(--eb-charcoal);
  max-width: 760px;
  margin: 0 auto;
  padding: 0 0 32px;
}
.eb-cbn *, .eb-cbn *::before, .eb-cbn *::after { box-sizing: border-box; }

.eb-cbn__palette { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 0 0 12px; }
.eb-cbn button {
  font: inherit; font-weight: 700; min-height: 44px; min-width: 44px; padding: 8px 18px;
  border-radius: 999px; border: 2px solid var(--eb-charcoal); background: #fff; color: var(--eb-charcoal); cursor: pointer;
}
.eb-cbn button:hover { background: var(--eb-board); }
.eb-cbn button:focus-visible, .eb-cbn__canvas:focus-visible { outline: 3px solid var(--eb-sky); outline-offset: 3px; }
.eb-cbn button.eb-cbn__swatch { display: inline-flex; align-items: center; gap: 8px; padding: 5px 14px 5px 5px; }
.eb-cbn button.eb-cbn__swatch[aria-pressed="true"] { background: var(--eb-sunshine); box-shadow: 0 0 0 2px var(--eb-charcoal); }
.eb-cbn__chip {
  display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  border: 2px solid rgba(0,0,0,.25); font-weight: 800; color: #3A342E; text-shadow: 0 0 3px #fff;
}
.eb-cbn__chip.is-dark { color: #fff; text-shadow: 0 0 3px #000; }
.eb-cbn__controls { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 6px; }
.eb-cbn button.eb-cbn__primary { background: var(--eb-btn); border-color: var(--eb-btn); color: #fff; box-shadow: 0 4px 0 var(--eb-btn-shadow); }
.eb-cbn__status { text-align: center; font-weight: 700; margin: 4px 0; min-height: 1.5em; }
.eb-cbn__progress { text-align: center; margin: 0 0 10px; font-size: .9rem; color: #665c4c; }
.eb-cbn__canvas {
  display: block; width: 100%; height: auto; margin: 0 auto;
  border-radius: 18px; border: 2px solid var(--eb-line); background: #fff; cursor: pointer;
  touch-action: manipulation;
}
.eb-cbn__help { font-size: .85rem; color: #665c4c; margin: 12px 0 0; text-align: center; }
.eb-cbn__win { margin: 18px auto 0; max-width: 420px; text-align: center; background: #fff; border: 3px solid var(--eb-sunshine); border-radius: 18px; padding: 18px; }
.eb-cbn__win[hidden] { display: none; }
.eb-cbn__win h3 { color: var(--eb-heading); font-family: "Baloo 2", "Nunito Sans", sans-serif; font-size: 1.8rem; margin: 0 0 6px; }
.eb-cbn__win p { margin: 0 0 12px; }
/* Phones: numbered circles only (each button keeps its colour name for screen readers), so the
   picture stays close to the colours. */
@media (max-width: 520px) {
  .eb-cbn__palette { gap: 6px; }
  .eb-cbn button.eb-cbn__swatch { padding: 4px; }
  .eb-cbn__name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}
