/* The list on the December guide (/guides/december-school-checklist), and nothing else.
   Colours, fonts and buttons are the site's own, from styles.css. */
.december-list { padding: 28px; border: 1px solid var(--border-strong); border-radius: 20px; background: var(--paper); }
.december-list [hidden] { display: none !important; }
.december-list a:focus-visible,
.december-list button:focus-visible,
.december-list input:focus-visible,
.december-list textarea:focus-visible { outline: 3px solid var(--indigo); outline-offset: 3px; }
.december-list label { font: 600 14px/1.4 var(--text); color: var(--ink); }
.december-list input[type='text'],
.december-list input[type='date'],
.december-list textarea {
  display: block; width: 100%; min-width: 0; min-height: 48px; margin: 6px 0 0; padding: 11px 14px;
  background: var(--cream); border: 1.5px solid var(--chip-border); border-radius: 12px;
  /* 16px or more, so iPhone Safari does not zoom the page when a box is tapped. */
  font: 400 16px/1.3 var(--text); color: var(--ink);
}
.december-list input[type='date'] { -webkit-appearance: none; appearance: none; text-align: left; }
.december-list input::placeholder { color: var(--caption); opacity: 1; }
.dl-school { max-width: 420px; margin: 20px 0 8px; }
.dl-optional { font-weight: 400; color: var(--caption); }

.guide-section .dl-rows { list-style: none; margin: 0; padding: 0; }
.guide-section .dl-row { display: grid; grid-template-columns: minmax(0, 1.25fr) 170px minmax(0, 1.5fr); gap: 8px 16px; align-items: end; margin: 0; padding: 16px 0; border-top: 1px solid var(--divider); }
.guide-section .dl-row:first-child { border-top: 0; }
.dl-item { position: relative; display: flex; align-items: center; gap: 12px; min-height: 48px; }
.dl-item input[type='checkbox'] { flex: none; width: 26px; height: 26px; margin: 0; accent-color: var(--indigo); }
.december-list .dl-item label { flex: 1; padding: 12px 0; font: 700 17px/1.35 var(--text); cursor: pointer; }
.dl-field { position: relative; min-width: 0; }
.dl-first { min-width: 0; }
.dl-first .dl-field { margin-top: 4px; }

.dl-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.dl-actions button { min-height: 48px; font-size: 16px; }
.guide-section .dl-status { margin: 12px 0 0; min-height: 1.6em; font: 600 15px/1.6 var(--text); color: var(--ink); }
.dl-fallback { margin-top: 8px; }
.december-list textarea { min-height: 300px; resize: vertical; }
.guide-section .dl-promise { margin-top: 12px; font-size: 15px; color: var(--ink); }
.guide-section .dl-next { margin-top: 20px; }
.dl-sheet { display: none; }

@media (max-width: 760px) {
  .december-list { padding: 20px; }
  .guide-section .dl-row { grid-template-columns: minmax(0, 1fr); gap: 10px; align-items: stretch; }
  .dl-actions button { flex: 1 1 100%; }
  .guide-section .dl-row { padding: 6px 0; }
  .guide-section .dl-row:has(input[type='checkbox']:checked) { padding-bottom: 18px; }
}
/* On a phone the list starts as eleven short rows. Ticking one opens its date and its note.
   A browser without :has() shows every box, as a wide screen does. */
@supports selector(:has(*)) {
  @media (max-width: 760px) {
    .dl-row:not(:has(input[type='checkbox']:checked)) .dl-field { display: none; }
  }
}

/* On paper: the heading with the school's name, the rows with a square to tick, and one
   line at the foot. Only once there is a row on the list (december-list.js sets the class);
   until then the guide prints as it always has. */
@page { size: A4 portrait; margin: 16mm; }
@media print {
  .dl-has-list body { background: #fff; }
  .dl-has-list body > *:not(main),
  .dl-has-list main > .container > *:not(.december-list),
  .dl-has-list .december-list > *:not(.dl-sheet) { display: none !important; }
  .dl-has-list main > .container { max-width: none; padding: 0; }
  .dl-has-list .december-list { margin: 0; padding: 0; border: 0; background: none; }
  .dl-has-list .dl-sheet { display: block; color: #000; }
  .dl-sheet-title { margin: 0 0 8mm; font: 700 24pt/1.2 var(--display); color: #000; }
  .guide-section .dl-sheet-rows { list-style: none; margin: 0; padding: 0; }
  .guide-section .dl-sheet-row { display: flex; align-items: flex-start; gap: 5mm; margin: 0; padding: 4mm 0; border-bottom: 0.3mm solid #999; font: 400 13pt/1.35 var(--text); color: #000; break-inside: avoid; }
  .dl-sheet-box { flex: none; width: 6mm; height: 6mm; border: 0.5mm solid #000; border-radius: 1mm; }
  .dl-sheet-date { flex: none; width: 30mm; font-weight: 700; }
  .dl-sheet-what { flex: 1; min-width: 0; overflow-wrap: anywhere; }
  .dl-sheet-name { display: block; font-weight: 600; }
  .dl-sheet-note { display: block; }
  .guide-section .dl-sheet-foot { margin: 8mm 0 0; font: 400 9pt/1.4 var(--text); color: #333; }
}
