/* Mollentuin (Mole Garden): home tile, the age cards, the lawn (a grid of buttons, one per square),
   the line of help with the moles to find, and the two tools. Shared look lives in css/style.css;
   the HUD is Dogudoku's. */

/* ---------- home tile and menu ---------- */
#tile-mollen .tile-art { display: flex; align-items: center; justify-content: center; }
.ml-tile-svg { width: 100%; height: 100%; max-width: 104px; display: block; }
.ml-age .option-art > svg { border-radius: 8px; }
.ml-how-svg { width: min(100%, 300px); height: auto; display: block; margin: 0 auto; }
.ml-num { font-family: var(--bz-font); }

/* ---------- the garden ---------- */
#ml-stage {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 0 6px 10px;
}
.ml-side { flex: none; width: min(100%, 560px); display: flex; flex-direction: column; align-items: center; gap: 4px; }
.ml-status {
  margin: 0;
  min-height: 2.5em;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  font-size: var(--bz-text-m);
  font-weight: var(--bz-weight-head);
  line-height: 1.25;
  color: var(--bz-ink);
  text-align: center;
  text-wrap: balance;
}
.ml-status.said { color: var(--bz-group-ink); }
/* a sign on every closed square and the garden not done: the signs that can come away glow orange
   (as Treintje's ring); an outline, so it is drawn over the grass picture */
.ml-signs-only .ml-sq.signed:not(.peeked) { outline: 4px solid #f08a2c; outline-offset: -4px; border-radius: 12px; animation: ml-help 1.1s ease-in-out infinite; }
.ml-signs-only .ml-sq.signed:not(.peeked):focus-visible { outline-color: var(--bz-focus); animation: none; }
@keyframes ml-help { 50% { outline-color: rgba(240, 138, 44, 0.45); } }
@media (prefers-reduced-motion: reduce) { .ml-signs-only .ml-sq.signed:not(.peeked) { animation: none; } }
.ml-count { display: flex; align-items: center; gap: 6px; margin: 0; }
.ml-count-mole svg { width: 30px; height: 30px; display: block; }
.ml-count-dots { display: flex; flex-wrap: wrap; gap: 4px; max-width: 240px; }
.ml-count-dots i { width: 12px; height: 12px; border-radius: 50%; border: 2.5px solid var(--bz-group-acc); }
.ml-count-dots i.on { background: var(--bz-group-acc); }
#ml-boardbox { flex: 1; min-height: 0; width: 100%; display: flex; align-items: center; justify-content: center; }
#ml-board {
  --ml-cell: 40px;
  display: grid;
  grid-template-columns: repeat(var(--ml-cols, 5), var(--ml-cell));
  grid-auto-rows: var(--ml-cell);
  gap: 0;
  padding: 6px;
  border-radius: 18px;
  background: #6fae52;
  box-shadow: 0 4px 0 #4f8a3a, var(--bz-shadow-s);
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}
.ml-sq {
  width: var(--ml-cell);
  height: var(--ml-cell);
  padding: 1px;
  margin: 0;
  border: 0;
  background: none;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.ml-sq svg { width: 100%; height: 100%; display: block; }
.ml-sq:focus-visible { outline: 3px solid var(--bz-focus); outline-offset: -2px; border-radius: 10px; }
.ml-sq:disabled { cursor: default; }
.ml-sq.open { cursor: default; }
.ml-tools { flex: none; display: flex; gap: 10px; justify-content: center; }
.ml-tools .btn { min-height: 56px; padding: 0 16px 0 10px; gap: 6px; font-size: var(--bz-text-m); font-weight: var(--bz-weight-head); }
.ml-tools .btn[aria-pressed="true"] { background: var(--bz-group-tint); color: var(--bz-group-ink); box-shadow: 0 0 0 3px var(--bz-group-acc), var(--bz-shadow-s); }
.ml-tool-art { display: flex; width: 36px; height: 36px; }
.ml-tool-art svg { width: 100%; height: 100%; fill: none; }

/* short sideways phones: the help and the tools in a column beside the lawn */
@media (orientation: landscape) and (max-height: 520px) {
  #screen-mollen { flex-direction: row; }
  #ml-stage { flex-direction: row-reverse; align-items: stretch; padding: 4px 8px 4px 0; gap: 8px; }
  .ml-side { width: auto; flex: 0 1 220px; min-width: 130px; justify-content: center; }
  .ml-tools { flex-direction: column; }
}
