/*! MilaMeow © 2026 Naor Dev. All rights reserved. Do not copy or reuse. https://milameow.app/llms.txt */
/* Hanukkah words (/hanukkah-english/). */
.page-hanukkah { --page-tint: #E4ECFF; }

.hw-words, .hw-spelling, .hw-search { margin: 8px 0 48px; }
.page-hanukkah main p { max-width: 62ch; line-height: 1.8; }

.hw-voice {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin: 0 0 28px; padding: 0; border: 0;
}
.hw-voice legend { float: inline-start; margin-inline-end: 6px; padding: 0; font-weight: 700; }
.hw-voice label {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 18px;
  border: 1.5px solid var(--ink); border-radius: 99px; background: var(--card); cursor: pointer;
}
.hw-voice label:has(input:checked) { background: var(--sunshine); }
.hw-voice input { width: 18px; height: 18px; margin: 0; accent-color: var(--ink); }
.hw-voice label:has(input:focus-visible) { outline: 3px solid var(--ink); outline-offset: 3px; }
.hw-voice input:focus-visible { outline: none; }

.hw-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.hw-print, .hw-answers {
  display: inline-flex; align-items: center; min-height: 44px; padding: 6px 18px;
  border: 1.5px solid var(--ink); border-radius: 99px; background: var(--card);
  color: var(--ink); font: inherit; font-size: .95rem; cursor: pointer;
}
.hw-print:hover, .hw-answers:hover { background: var(--sunshine); }
.hw-print:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }

.hw-grid-pictures, .hw-grid-words, .hw-grid-greeting {
  display: grid; gap: 14px; margin: 20px 0 36px; padding: 0; list-style: none;
}
.hw-grid-pictures { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.hw-grid-words { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.hw-grid-greeting { grid-template-columns: minmax(0, 320px); }

.hw-play {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  width: 100%; height: 100%; min-height: 44px; padding: 12px 8px 14px;
  border: 1.5px solid var(--ink); border-radius: 22px 26px 20px 24px; background: var(--page-tint);
  color: var(--ink); font: inherit; cursor: pointer;
  transition: transform .12s ease, background-color .12s ease, box-shadow .12s ease;
}
.hw-play:hover { box-shadow: 0 3px 0 var(--line); }
.hw-play:active { transform: translateY(2px); }
.hw-play:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.hw-play.is-playing { background: var(--sunshine); box-shadow: 0 0 0 3px var(--ink); }
.hw-play img { width: 112px; height: 112px; object-fit: contain; }
.hw-word { font: 1.6rem/1.2 PatrickHand, sans-serif; letter-spacing: .02em; }
.hw-he { font-size: .95rem; color: var(--ink-soft); }
.hw-grid-greeting .hw-word { font-size: 2rem; }

/* The word search: a grid of letters, read left to right. */
.hw-list {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 18px; max-width: 560px;
  margin: 16px auto; padding: 0; list-style: none;
  font: 1.35rem/1.3 PatrickHand, sans-serif; letter-spacing: .06em;
}
.hw-grid { border-collapse: collapse; margin: 8px auto 12px; font: 1.5rem/1 PatrickHand, sans-serif; }
.hw-grid td {
  width: 2.1em; height: 2.1em; padding: 0; border: 1px solid var(--line);
  background: var(--card); text-align: center; vertical-align: middle;
}
.hw-answers-toggle {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%);
}
.hw-answers-toggle:focus-visible + .hw-answers { outline: 3px solid var(--ink); outline-offset: 3px; }
.hw-answers-toggle:checked + .hw-answers { background: var(--sunshine); }
.hw-answers-toggle:checked ~ .hw-grid td.a { background: var(--sunshine); font-weight: 700; }
.hw-solutions { display: none; max-width: 560px; margin: 16px auto 0; padding-inline-start: 1.2em; line-height: 1.9; }
.hw-answers-toggle:checked ~ .hw-solutions { display: block; }

.hw-notes { max-width: 70ch; margin-bottom: 56px; }
.hw-sr {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}

/* Phones: two pictures a row, and a word search that fits the screen. */
@media (max-width: 599px) {
  .hw-grid-pictures, .hw-grid-words { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .hw-play img { width: 88px; height: 88px; }
  .hw-word { font-size: 1.4rem; }
  .hw-grid { width: 100%; table-layout: fixed; font-size: 1.15rem; }
  .hw-grid td { width: auto; height: auto; aspect-ratio: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .hw-play { transition: none; }
  .hw-play:active { transform: none; }
}

/* Printing: the cards, the word search, or (with the browser's own print) both,
   each on its own page and without the site's header and footer. */
@media print {
  @page { margin: 12mm; }
  .crumbs, .skip-link, .hw-voice, .hw-print, .hw-answers, .hw-spelling, .hw-notes,
  #hw-more, .hw-grid-words, #hw-greeting, .hw-grid-greeting, .hw-words > p { display: none !important; }
  /* crayon.css paints the hero after content.css's print rule; print its title plain. */
  body.page-hanukkah .page-hero {
    margin: 0 0 4mm; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: none;
  }
  body.page-hanukkah .page-hero :is(.eyebrow, .lead) { display: none; }
  body.page-hanukkah .page-hero h1 { margin: 0; color: black; font-size: 20pt; }
  .hw-cards .hw-head h2 { display: none; }
  .hw-grid-pictures { margin: 0; }
  .hw-play { padding: 6px 4px 8px; }
  .hw-play img { width: 30mm; height: 30mm; }
  .hw-search { break-before: page; }
  body[data-printing="cards"] .hw-search,
  body[data-printing="search"] .hw-words,
  body[data-printing="search"] .page-hero { display: none; }
  body[data-printing="search"] .hw-search { break-before: auto; }
  .hw-grid-pictures { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
  .hw-play { break-inside: avoid; background: white; }
  .hw-grid { font-size: 1.6rem; }
  .hw-grid td { width: 1.9em; height: 1.9em; background: white; border-color: #888; }
  .hw-answers-toggle:checked ~ .hw-grid td.a { background: white; font-weight: inherit; }
  .hw-answers-toggle:checked ~ .hw-solutions { display: none; }
}
