/* Disclosure follow-on (2026-10-22): the footer's disclosure links, their short topic dialogs and the /about/recipes
   page (lib/disclosures.js). Scoped to disclosure-* classes; text colors inherit from the page and site.css. Sizes are
   rem/em so 200% text reflows, every link and control is at least 44px, and nothing assumes more than 320px. */

.disclosure-footer p { margin: 0; overflow-wrap: anywhere; }
.disclosure-links { display: flex; flex-wrap: wrap; column-gap: 1rem; }
.disclosure-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  min-width: 44px;
  vertical-align: middle;
  font-weight: 600;
}

.disclosure-dialog {
  box-sizing: border-box;
  width: min(32rem, calc(100% - 2rem));
  max-width: none;
  max-height: calc(100% - 2rem);
  padding: 0;
  border: 0;
  border-radius: 16px;
  background: var(--surface, #FFFDF8);
  color: var(--text-primary, #211B14);
  font-size: 1rem;
  text-align: start;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.disclosure-dialog::backdrop { background: rgb(0 0 0 / 0.45); }
/* The body carries the padding, so a click whose target is the dialog element itself is a backdrop click. */
.disclosure-dialog-body { padding: 1.25rem 1.25rem 1.5rem; }
.disclosure-dialog-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 0.75rem;
  position: sticky;
  top: 0;
  z-index: 1;
  margin-bottom: 0.75rem;
  background: var(--surface, #FFFDF8);
}
.disclosure-dialog-heading form { margin: 0; }
.disclosure-dialog h2 { margin: 0; font-size: 1.25rem; line-height: 1.3; overflow-wrap: anywhere; }
.disclosure-dialog h2:focus { outline: none; }
.disclosure-dialog p { margin: 0 0 0.75rem; line-height: 1.5; overflow-wrap: anywhere; }
.disclosure-dialog-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-top: 1rem;
}
.disclosure-dialog-actions form { margin: 0; }
.disclosure-close {
  min-height: 44px;
  min-width: 44px;
  padding: 0 1.25rem;
  border: 1px solid currentColor;
  border-radius: 999px;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
/* Phone widths: a bottom sheet. */
@media (max-width: 40rem) {
  .disclosure-dialog {
    width: 100%;
    max-height: 85%;
    margin: auto 0 0;
    border-radius: 16px 16px 0 0;
  }
}

.disclosures { max-width: 40rem; margin: 0 auto; }
.disclosure-section { border-bottom: 1px solid rgb(128 128 128 / 0.35); }
/* the native list-item marker stays (no display change); padding + line-height give the 44px row */
.disclosure-section summary {
  box-sizing: border-box;
  min-height: 44px;
  padding: 0.625rem 0;
  font-weight: 600;
  line-height: 1.5;
  cursor: pointer;
}
.disclosure-section-body p { margin: 0 0 1rem; line-height: 1.5; overflow-wrap: anywhere; }

.disclosure-footer .meta { font-size: .75rem; }
.disclosures h1 { font-size: 2rem; overflow-wrap: anywhere; }

/* Keep the topic heading readable when large text leaves little inline space. */
@media (max-width: 480px) {
  .disclosure-dialog-heading { grid-template-columns: minmax(0, 1fr); }
  .disclosure-dialog-heading form { grid-row: 1; justify-self: end; }
  .disclosure-dialog-heading h2 { grid-row: 2; }
}
