/* The live whiteboard (public/whiteboard.js): Nova's marks on a canvas layered exactly over the
   writing pad (public/answer-pad.css sizes the pad canvas; the layer follows it). The layer never
   takes pointer events, so writing goes straight to the pad. Mobile-first, logical properties for
   right-to-left pages, 44 px touch targets, Okabe-Ito colours (drawn in whiteboard.js). */
.wb-stage { position: relative; width: 100%; }
.wb-stage > .wp-canvas { position: relative; z-index: 0; }
.wb-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}
.wb-layer[hidden] { display: none; }
.wb-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.6rem;
  margin-block: 0.25rem 0;
  min-width: 0;
}
.wb-status {
  flex: 1 1 12rem;
  min-width: 0;
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.35;
  color: #4a4d6e;
  overflow-wrap: anywhere;
}
.wb-status:empty { display: none; }
.wb-status[data-state="simulated"],
.wb-status[data-state="unavailable"] {
  padding: 0.3rem 0.6rem;
  border-radius: 10px;
  background: #fff4dc;
  color: #6b4500;
  border-inline-start: 4px solid #e69f00;
}
.wb-status[data-state="unsure"],
.wb-status[data-state="retry"] {
  padding: 0.3rem 0.6rem;
  border-radius: 10px;
  background: #fbeaf3;
  color: #5c1f45;
  border-inline-start: 4px dotted #cc79a7;
}
.wb-status[data-state="looking"]::before {
  content: "";
  display: inline-block;
  inline-size: 0.6rem;
  block-size: 0.6rem;
  margin-inline-end: 0.4rem;
  border-radius: 50%;
  background: #0072b2;
  animation: wb-pulse 1.2s ease-in-out infinite;
}
.wb-caption {
  flex: 1 1 100%;
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.4;
  color: #12204f;
  overflow-wrap: anywhere;
}
.wb-caption:empty { display: none; }
.wb-toggle {
  min-height: 44px;
  min-width: 44px;
  padding: 0.35rem 0.75rem;
  border: 2px solid #c9c3e6;
  border-radius: 12px;
  background: #ffffff;
  color: #1d1b3a;
  font: inherit;
  white-space: normal;
  margin-inline-start: auto;
}
.wb-toggle[aria-pressed="true"] { background: #e9e4ff; border-color: #6b5bd6; }
.wb-toggle:focus-visible { outline: 3px solid #6b5bd6; outline-offset: 2px; }
@keyframes wb-pulse { 0%, 100% { opacity: 0.35; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .wb-status[data-state="looking"]::before { animation: none; opacity: 1; }
}
