/* Bild-Bingo-Generator (/picture-bingo-generator/, inc/features/picture-bingo.php, assets/js/picture-bingo.js). Gestaltung
   wie Hanging-Planner und Frame-Fit: Papierfläche mit Goldkante, Auswahl links, Vorschau des ersten Plans rechts. */
.vv-bingo {
  box-sizing: border-box;
  max-width: 100%;
  margin-block: var(--wp--preset--spacing--50);
  padding: clamp(1.25rem, 4vw, 2rem);
  background: var(--wp--preset--color--surface);
  border: 1px solid var(--wp--preset--color--line);
  border-top: 3px solid var(--vv-gold);
}
.vv-bingo[hidden] {
  display: none !important;
}
.vv-bingo *,
.vv-bingo *::before,
.vv-bingo *::after {
  box-sizing: border-box;
}
.vv-bingo__title,
.vv-article .wp-block-post-content .vv-bingo__title {
  margin: 0 0 1.25rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.2;
}
.vv-bingo__layout {
  display: grid;
  gap: 1.5rem;
  align-items: start;
}
@media (min-width: 900px) {
  /* Die Textspalte ist 700 px schmal (Vorlage constrained): das Werkzeug bricht mittig auf bis zu 1080 px aus. */
  .vv-article .wp-block-post-content > .vv-bingo {
    --vv-bingo-width: min(1080px, 100vw - 3rem);
    width: var(--vv-bingo-width);
    max-width: none;
    margin-inline: calc((100% - var(--vv-bingo-width)) / 2) !important;
  }
  .vv-bingo__layout {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    gap: 2rem;
  }
  .vv-bingo__board {
    position: sticky;
    top: 1.5rem;
  }
}
.vv-bingo__form {
  display: grid;
  gap: 1rem;
}
.vv-bingo__form p {
  margin: 0;
}
.vv-bingo label,
.vv-bingo legend {
  font-size: var(--wp--preset--font-size--small);
  font-weight: 600;
  color: var(--wp--preset--color--ink);
}
.vv-bingo__group,
.vv-bingo fieldset {
  min-width: 0;
  margin: 0;
  padding: 0.75rem 1rem;
  border: 1px solid var(--wp--preset--color--line);
}
.vv-bingo legend {
  padding: 0 0.35rem;
}
.vv-bingo__row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 9rem), 1fr));
  gap: 1rem;
  align-items: end;
}
.vv-bingo__row fieldset {
  padding: 0;
  border: 0;
}
.vv-bingo__row legend {
  padding: 0;
}
.vv-bingo__row label[for='vv-bingo-count'] {
  display: block;
  margin-bottom: 0.35rem;
}
.vv-bingo input[type='number'] {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.5rem 0.75rem;
  font: inherit;
  color: var(--wp--preset--color--ink);
  background: var(--wp--preset--color--base);
  border: 1px solid var(--wp--preset--color--muted);
  border-radius: 2px;
}
.vv-bingo__choices {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
}
.vv-bingo__choices label,
.vv-bingo label[for='vv-bingo-labels'] {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 2.75rem;
  font-weight: 400;
  font-size: 1rem;
  cursor: pointer;
}
.vv-bingo input[type='radio'],
.vv-bingo input[type='checkbox'] {
  width: 1.15rem;
  height: 1.15rem;
  margin: 0;
  accent-color: var(--wp--preset--color--navy);
}
.vv-bingo__themes {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr));
  gap: 0.5rem;
}
.vv-bingo__theme {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  padding: 0.6rem 0.4rem;
  text-align: center;
  font-weight: 400;
  background: var(--wp--preset--color--base);
  border: 1px solid var(--wp--preset--color--line);
  border-radius: 4px;
  cursor: pointer;
}
.vv-bingo__theme input {
  position: absolute;
  opacity: 0;
}
.vv-bingo__theme:has(input:checked) {
  border-color: var(--wp--preset--color--navy);
  box-shadow: inset 0 0 0 1px var(--wp--preset--color--navy);
  background: var(--wp--preset--color--accent-soft);
}
.vv-bingo__theme:has(input:focus-visible) {
  outline: 2px solid var(--wp--preset--color--accent);
  outline-offset: 2px;
}
.vv-bingo__icons {
  display: flex;
  gap: 0.2rem;
}
.vv-bingo__theme-name {
  font-size: 0.9rem;
  line-height: 1.2;
}
.vv-bingo__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.vv-bingo__create,
.vv-bingo__shuffle {
  min-height: 2.75rem;
  padding: 0.6rem 1.5rem;
  font: inherit;
  font-weight: 600;
  border-radius: 2px;
  cursor: pointer;
}
.vv-bingo__create {
  color: var(--wp--preset--color--night);
  background: var(--vv-gold);
  border: 1px solid var(--vv-gold);
}
.vv-bingo__create:hover {
  background: var(--wp--preset--color--accent-soft);
}
.vv-bingo__create:disabled {
  opacity: 0.6;
  cursor: progress;
}
.vv-bingo__shuffle {
  color: var(--wp--preset--color--ink);
  background: transparent;
  border: 1px solid var(--wp--preset--color--muted);
}
.vv-bingo button:focus-visible,
.vv-bingo input:focus-visible {
  outline: 2px solid var(--wp--preset--color--accent);
  outline-offset: 2px;
}
.vv-bingo__status:not(:empty) {
  padding: 0.6rem 0.9rem;
  background: var(--wp--preset--color--accent-soft);
  border-left: 3px solid var(--wp--preset--color--accent);
}

/* Vorschau des ersten Plans – so, wie er gedruckt wird. */
.vv-bingo__board {
  --vv-bingo-grid: 5;
  padding: 1rem;
  background: #fff;
  border: 1px solid var(--wp--preset--color--line);
  box-shadow: 0 6px 18px rgb(17 26 49 / 8%);
}
.vv-bingo__board-title {
  margin: 0 0 0.5rem;
  text-align: center;
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--wp--preset--color--navy);
}
.vv-bingo__head,
.vv-bingo__grid {
  display: grid;
  grid-template-columns: repeat(var(--vv-bingo-grid), 1fr);
}
.vv-bingo__head span {
  text-align: center;
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--vv-gold);
}
.vv-bingo__grid {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 3px solid var(--wp--preset--color--navy);
}
.vv-bingo__grid li {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
  min-width: 0;
  padding: 0.2rem;
  margin: 0;
  border: 0.5px solid var(--wp--preset--color--navy);
  font-size: clamp(0.5rem, 1.3vw, 0.72rem);
  font-weight: 700;
  line-height: 1.05;
  overflow-wrap: anywhere;
  text-align: center;
  color: var(--wp--preset--color--navy);
  overflow: hidden;
}
.vv-bingo__grid img {
  width: 62%;
  height: auto;
}
.vv-bingo__board--nolabels .vv-bingo__grid img {
  width: 78%;
}
.vv-bingo__free {
  color: var(--vv-gold) !important;
  font-size: clamp(0.7rem, 2vw, 0.95rem) !important;
}

/* Hinweis auf Spiele im Shop und Newsletter darunter. */
.vv-bingo-more {
  margin-block: var(--wp--preset--spacing--50);
  padding: clamp(1.25rem, 4vw, 2rem);
  background: var(--wp--preset--color--accent-soft);
  border-left: 3px solid var(--wp--preset--color--accent);
}
.vv-bingo-more__title,
.vv-article .wp-block-post-content .vv-bingo-more__title {
  margin: 0 0 0.5rem;
  font-size: clamp(1.3rem, 2.4vw, 1.6rem);
}
.vv-bingo-more__products,
.vv-bingo-more__shops {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  margin: 0.75rem 0 0;
  padding: 0;
  list-style: none;
}
.vv-bingo-more__products li {
  flex: 1 1 10rem;
  max-width: 14rem;
}
.vv-bingo-more__products a {
  display: grid;
  gap: 0.4rem;
  font-weight: 600;
}
.vv-bingo-more__products img {
  width: 100%;
  height: auto;
}
.vv-bingo-more__shop {
  font-weight: 600;
}
