/* The seven toolkit tools made by site/tools/toolkit-more.mjs (hand-written). The site's tokens from style.css. */
.tk-app{margin:24px 0 8px;padding:20px 18px;border-radius:22px;background:var(--card);box-shadow:var(--shadow-paper)}
.tk-app:empty{display:none}
.tk [hidden]{display:none!important}
.tk-app h2,.tk-app h3{font-size:22px;margin:22px 0 10px}
.tk-app h2:first-child,.tk-app h3:first-child{margin-top:0}
.tk-app p{margin:8px 0}
.tk-app label{font-weight:600}
.tk-app input[type=text],.tk-app input[type=date],.tk-app input[type=time],.tk-app textarea,.tk-app select{width:100%;min-height:52px;padding:10px 12px;border:2px solid var(--line);border-radius:12px;background:#fff;color:var(--ink);font:inherit;font-size:17px;box-sizing:border-box}
.tk-app textarea{min-height:84px;resize:vertical;line-height:1.4}
.tk-app input:focus-visible,.tk-app textarea:focus-visible,.tk-app select:focus-visible{outline:3px solid var(--lamp);outline-offset:2px;border-color:var(--night)}
.tk-app fieldset{margin:14px 0;padding:0;border:0;min-width:0}
.tk-app legend{font-weight:700;font-size:17px;margin-bottom:6px;padding:0}
.tk-row{display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin:14px 0}
.tk-row>.btn{flex:1 1 auto}
.tk-f{margin:12px 0}
.tk-f>label{display:block;margin-bottom:6px}
.tk-hint{font-size:15px;color:var(--muted);margin:6px 0 0}
.tk-msg{margin:10px 0 0;font-weight:700}
.tk-msg:empty{display:none}
.tk .btn{border:0;cursor:pointer;font-family:inherit}
.tk .btn[disabled]{opacity:.45;cursor:default}
.btn-soft{background:var(--paper-2);color:var(--ink)}
.btn-soft:hover{box-shadow:0 0 0 4px rgba(27,35,64,.08)}
.tk-chip{min-height:48px;padding:0 16px;border:2px solid var(--line);border-radius:999px;background:#fff;color:var(--ink);font:inherit;font-weight:700;font-size:16px;cursor:pointer}
.tk-chip[aria-pressed="true"]{background:var(--night);border-color:var(--night);color:var(--night-ink)}
.tk-chips{display:flex;flex-wrap:wrap;gap:8px}
.tk-radio label,.tk-check label{display:flex;align-items:center;gap:12px;min-height:48px;font-size:17px;cursor:pointer}
.tk-radio input,.tk-check input{width:24px;height:24px;accent-color:var(--night);flex:none;margin:0}
.tk-steps li{margin-bottom:10px}
.tk-foot{margin-top:28px}
/* picture card buttons */
.tk-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(104px,1fr));gap:10px;margin:10px 0;padding:0;list-style:none}
.tk-pick{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:4px;width:100%;min-height:118px;padding:10px 6px;border:3px solid var(--line);border-radius:16px;background:#fff;color:var(--ink);font:inherit;font-weight:700;font-size:15px;line-height:1.2;text-align:center;cursor:pointer}
.tk-pick img{width:64px;height:64px}
.tk-pick[aria-pressed="true"]{border-color:var(--night);background:var(--paper);box-shadow:inset 0 0 0 2px var(--night)}
.tk-pick[aria-pressed="true"]::after{content:"\2713";display:block;font-size:18px;line-height:1;color:var(--night)}
.tk-pick:focus-visible{outline:3px solid var(--lamp);outline-offset:2px}
/* dialogs */
.tk-dialog{width:min(640px,calc(100vw - 24px));max-height:calc(100vh - 40px);padding:18px;border:0;border-radius:20px;background:var(--card);color:var(--ink);box-shadow:var(--shadow-night)}
.tk-dialog::backdrop{background:rgba(11,15,42,.6)}
.tk-dialog h2{font-size:22px;margin:0 0 8px}
.tk-dialog .tk-grid{max-height:60vh;overflow:auto}
.tk-dialog h3{font-size:17px;margin:14px 0 4px;color:var(--muted)}
/* full screen boards */
.tk-full{position:fixed;inset:0;z-index:1000;display:flex;flex-direction:column;background:var(--paper);color:var(--ink);overflow:auto}
.tk-full[hidden]{display:none}
.tk-full-bar{display:flex;gap:10px;justify-content:space-between;align-items:center;padding:12px 16px}
.tk-full-bar .btn{min-height:52px;padding:0 18px}
body.tk-locked{overflow:hidden}
/* the visual timer */
.tk-timer{display:grid;gap:8px;justify-items:center;margin:10px 0}
.tk-face{width:min(220px,56vw)}
.tk-face svg{display:block;width:100%;height:auto}
.tk-left{margin:0;font-weight:700;min-height:1.5em}
.tk-picks{display:flex;flex-wrap:wrap;gap:8px;justify-content:center}
.tk-ends{border:0;padding:0;display:flex;flex-wrap:wrap;gap:4px 16px;justify-content:center;margin:4px 0 0}
.tk-ends legend{width:100%;text-align:center;font-size:15px;color:var(--muted)}
.tk-ends label{display:flex;align-items:center;gap:8px;min-height:44px;font-weight:600;cursor:pointer}
.tk-ends input{width:22px;height:22px;accent-color:var(--night);margin:0}
.tk-timer-box summary{min-height:48px;display:flex;align-items:center;font-weight:700;cursor:pointer}

/* ---- what to expect ---- */
.tk-page{margin:14px 0;padding:14px;border:2px solid var(--line);border-radius:16px;background:var(--paper)}
.tk-page>label{display:block;font-weight:700;margin-bottom:6px}
.tk-pic-row{display:flex;flex-wrap:wrap;align-items:center;gap:10px;margin-top:10px}
.tk-thumb{width:72px;height:72px;border-radius:12px;background:#fff;border:2px solid var(--line);object-fit:contain;flex:none}
.tk-thumb.is-photo{object-fit:cover}
.tk-pic-row .tk-chip{min-height:44px}
.tk-file{position:relative;overflow:hidden}
.tk-file input{position:absolute;inset:0;opacity:0;cursor:pointer;width:100%;height:100%}
.tk-file:focus-within{outline:3px solid var(--lamp);outline-offset:2px}
.tk-reader{flex:1;display:flex;overflow-x:auto;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch}
.tk-reader:focus-visible{outline:3px solid var(--lamp);outline-offset:-3px}
.tk-rpage{flex:0 0 100%;scroll-snap-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:18px;padding:12px 24px 24px;box-sizing:border-box;text-align:center}
.tk-rpage img{width:min(60vw,46vh,320px);height:min(60vw,46vh,320px);object-fit:contain;border-radius:20px;background:#fff;box-shadow:var(--shadow-paper)}
.tk-rpage img.is-photo{object-fit:cover}
.tk-rpage p{margin:0;max-width:22ch;font-family:var(--display);font-weight:700;font-size:clamp(26px,6.4vw,40px);line-height:1.2}
.tk-rpage.is-cover p{font-size:clamp(32px,8vw,52px)}
.tk-rnav{display:flex;gap:10px;justify-content:center;align-items:center;padding:12px 16px 20px}
.tk-rnav .btn{min-width:120px}
.tk-rcount{min-width:5em;text-align:center;font-weight:700}
@media (prefers-reduced-motion:no-preference){.tk-reader{scroll-behavior:smooth}}

/* ---- whose turn ---- */
.tk-names{list-style:none;margin:10px 0;padding:0;display:grid;gap:8px}
.tk-names li{display:flex;gap:8px;align-items:center}
.tk-names input{flex:1}
.tk-icon{min-width:48px;min-height:48px;border:2px solid var(--line);border-radius:12px;background:#fff;font:inherit;font-weight:800;font-size:20px;color:var(--ink);cursor:pointer}
.tk-icon[disabled]{opacity:.35;cursor:default}
.tk-turn{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;padding:16px;text-align:center}
.tk-turn .tk-your{margin:0;font-family:var(--display);font-weight:800;font-size:clamp(28px,7vw,48px)}
.tk-turn .tk-who{margin:0;font-family:var(--display);font-weight:800;font-size:clamp(56px,17vw,140px);line-height:1;word-break:break-word}
.tk-turn .tk-then{margin:0;font-size:20px;font-weight:700;opacity:.8}
.tk-turn .tk-timer{margin-top:6px}
.tk-turn-nav{display:flex;gap:12px;padding:12px 16px 22px}
.tk-turn-nav .btn{flex:1;min-height:72px;font-size:22px}

/* ---- waiting ---- */
.tk-wait-card{display:flex;align-items:center;justify-content:center;min-height:260px;margin:14px 0;padding:24px 18px;border-radius:22px;background:var(--night);color:var(--night-ink);text-align:center;box-shadow:var(--shadow-night)}
.tk-wait-card p{margin:0;font-family:var(--display);font-weight:800;font-size:clamp(28px,7.4vw,42px);line-height:1.18;max-width:20ch}
.tk-wait-kind{display:block;font-family:var(--body);font-weight:700;font-size:15px;letter-spacing:.06em;text-transform:uppercase;color:var(--lamp);margin-bottom:12px}
.tk-big{width:100%;min-height:72px;font-size:22px}

/* ---- two homes ---- */
.tk-homes{display:grid;gap:12px}
.tk-home{display:grid;grid-template-columns:auto 1fr;gap:10px;align-items:center;padding:12px;border-radius:16px;background:var(--paper)}
.tk-home .tk-swatch{width:44px;height:44px;border-radius:12px;border:2px solid var(--ink)}
.tk-home .tk-chips{grid-column:1/-1}
.tk-home .tk-chips .tk-chip{padding:0 8px;min-width:56px}
.tk-home .tk-chips img{width:32px;height:32px;display:block}
.tk-paint .tk-chip{display:inline-flex;align-items:center;gap:8px}
.tk-paint .tk-dot{width:18px;height:18px;border-radius:50%;border:2px solid var(--ink);flex:none}
.tk-cal{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px;margin:12px 0}
.tk-cal .tk-dow{font-size:13px;font-weight:700;text-align:center;color:var(--muted)}
.tk-day{min-height:62px;padding:4px 2px;border:2px solid var(--line);border-radius:10px;background:#fff;color:var(--ink);font:inherit;font-size:13px;line-height:1.15;cursor:pointer;display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:2px;overflow:hidden}
.tk-day b{font-size:17px}
.tk-day span{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:700}
.tk-day.has-home{border-color:var(--ink)}
.tk-day:focus-visible{outline:3px solid var(--lamp);outline-offset:1px}
.tk-hand{display:grid;gap:10px;margin:10px 0;padding:0;list-style:none}
.tk-hand li{padding:12px;border-radius:14px;background:var(--paper)}
.tk-hand .tk-hand-f{display:grid;grid-template-columns:1fr 1.6fr;gap:8px;margin-top:8px}
.tk-dayview{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;padding:16px;text-align:center}
.tk-dayview img{width:min(56vw,40vh,280px);height:auto;border-radius:22px;background:#fff;padding:12px;box-sizing:border-box}
.tk-dayview .tk-dv-date{margin:0;font-size:22px;font-weight:700}
.tk-dayview .tk-dv-home{margin:0;font-family:var(--display);font-weight:800;font-size:clamp(40px,11vw,80px);line-height:1.05}
.tk-dayview .tk-dv-hand{margin:0;font-size:20px;font-weight:700}

/* ---- thank-you card / present plan previews ---- */
.tk-tabs{display:flex;gap:8px;margin-bottom:12px}
.tk-tabs .tk-chip{flex:1}
.tk-draw{position:relative;width:100%;max-width:520px;margin:0 auto}
.tk-draw canvas{display:block;width:100%;aspect-ratio:1;border:3px solid var(--ink);border-radius:16px;background:#fff;touch-action:none;cursor:crosshair}
.tk-swatches{display:flex;flex-wrap:wrap;gap:8px;margin:10px 0}
.tk-swatch-b{width:48px;height:48px;border-radius:50%;border:3px solid #fff;box-shadow:0 0 0 2px var(--line);cursor:pointer}
.tk-swatch-b[aria-pressed="true"]{box-shadow:0 0 0 3px var(--ink)}
.tk-preview{display:block;width:100%;max-width:420px;height:auto;margin:14px auto;border-radius:16px;box-shadow:var(--shadow-paper)}
.tk-preview[hidden]{display:none}

/* ---- printing: only the print root ---- */
.tk-print{display:none}
@media print{
  body>*:not(.tk-print){display:none!important}
  body{background:#fff!important}
  .tk-print{display:block;color:#000}
  .tk-print img{max-width:100%}
  .tk-sheet{box-sizing:border-box;display:flex;break-after:page;page-break-after:always;overflow:hidden}
  .tk-sheet:last-child{break-after:auto;page-break-after:auto}
  .tk-half{flex:1 1 50%;box-sizing:border-box;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8mm;padding:12mm;text-align:center;font-family:var(--display);font-weight:700;font-size:20pt;line-height:1.25}
  .tk-half+.tk-half{border-left:1px dashed #bbb}
  .tk-half img{width:62mm;height:62mm;object-fit:contain}
  .tk-half img.is-photo{object-fit:cover;border-radius:4mm}
  .tk-half.is-cover{font-size:28pt}
  .tk-half.is-back{font-size:10pt;font-family:var(--body);font-weight:400;color:#555;justify-content:flex-end}
  .tk-print-img{display:block;width:100%;max-width:170mm;margin:0 auto}
  .tk-print table{width:100%;border-collapse:collapse;font-family:var(--body);font-size:11pt}
  .tk-print th,.tk-print td{border:1px solid #333;padding:2mm;vertical-align:top;text-align:left}
  .tk-print h1{font-size:20pt;margin:0 0 4mm}
  .tk-print-note{font-size:9pt;color:#555;margin-top:4mm}
}
.tk-full .tk-turn-nav,.tk-full .tk-rnav{position:sticky;bottom:0;background:inherit}
.tk-full>div{background:inherit}

/* Room kept for the tool before its script draws it (audit WHX-04, 14 Nov). The page marks <html class="js"> just before the
   tool's empty box; with scripts on, the box keeps the tool's own first height, unseen (site/tools/toolkit-more.mjs sets
   --tk-h for phones and --tk-hw for wider screens), so the words under it don't jump down when the tool appears. With
   scripts off the empty box stays out of the page, as above. */
.js .tk-app:empty{display:block;visibility:hidden;box-sizing:border-box;min-height:var(--tk-h,0)}
@media (min-width:600px){.js .tk-app:empty{min-height:var(--tk-hw,0)}}
