/* Printable scavenger hunts: section styles on top of /styles.css. */

.visually-hidden { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Hero */
.hunt-hero { position: relative; padding: clamp(1.4rem, 3.5vw, 2.6rem) 0 clamp(1.2rem, 2.5vw, 1.8rem); }
.hunt-hero .breadcrumbs ol { justify-content: flex-start; }
.hunt-hero .breadcrumbs { margin-bottom: 1rem; text-align: left; }
.hunt-hero h1 { max-width: 15ch; font-size: clamp(2.4rem, 5.4vw, 4.4rem); }
.hunt-hero .page-intro { max-width: 62ch; margin: 0; color: var(--muted); font-size: 1.12rem; }
.hunt-hero .page-intro strong { color: var(--green); font-weight: 750; }
.hunts-theme .hunt-hero h1, .hunts-custom .hunt-hero h1 { max-width: none; font-size: clamp(2rem, 3.8vw, 3rem); }

/* Generator */
.hunt-generator { padding: 0 0 clamp(3rem, 7vw, 5rem); }
.gen-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); gap: clamp(1.5rem, 4vw, 3.5rem); align-items: start; }
.gen-stage { position: sticky; top: 96px; }
.gen-desk { position: relative; padding: clamp(1.2rem, 3vw, 2.4rem); border-radius: 40px 60px 44px 70px / 60px 44px 70px 40px; background: var(--green-soft); }
.gen-desk::after { content: ""; position: absolute; right: -10px; bottom: 22px; width: 92px; height: 70px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 48'%3E%3Cpath d='M10 34c8-1 11-4 13-7V17c0-2 1-3 3-3h6l3-5h12l3 5h5c2 0 3 1 3 3v17c0 2-1 3-3 3H28c-2 0-3-1-3-3m16-17c6 0 9 4 9 8 0 5-4 8-9 8-5 0-8-3-8-8 0-4 3-7 7-7 5 0 7 3 7 6 0 3-2 5-5 5' fill='none' stroke='%234f4f4f' stroke-width='1.3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center / contain; pointer-events: none; }
.gen-sheet { position: relative; width: 100%; max-width: 560px; margin: 0 auto; aspect-ratio: 210 / 297; overflow: hidden; border-radius: 4px; background: white; box-shadow: 0 1px 2px rgba(31,40,35,.12), 0 18px 40px rgba(39,75,61,.18); transform: rotate(-.6deg); }
.gen-sheet[data-paper="letter"] { aspect-ratio: 215.9 / 279.4; }
.gen-sheet[data-orient="landscape"] { aspect-ratio: 297 / 210; }
.gen-sheet[data-orient="landscape"][data-paper="letter"] { aspect-ratio: 279.4 / 215.9; }
.gen-sheet > img, .gen-sheet > svg { display: block; width: 100%; height: 100%; }
.gen-sheet > img { object-fit: cover; }
.gen-empty { display: grid; height: 100%; padding: 2rem; place-items: center; color: var(--muted); text-align: center; }
.gen-pager { display: flex; margin-top: 1rem; align-items: center; justify-content: center; gap: 1rem; color: var(--green); font-weight: 750; }
.pager-btn { width: 44px; height: 44px; border: 2px solid var(--green); border-radius: 50%; background: transparent; color: var(--green); cursor: pointer; font-size: 1.4rem; line-height: 1; }
.pager-btn:disabled { opacity: .35; cursor: default; }
.gen-status { min-height: 1.6em; margin: .8rem 0 0; color: var(--green-mid); font-size: .95rem; text-align: center; }

.gen-panel { min-width: 0; }
.gen-title { margin-bottom: 1.2rem; font-size: clamp(1.7rem, 3vw, 2.3rem); }
.gen-controls { display: grid; gap: 1.1rem; }
.gen-controls fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.gen-controls legend, .gen-controls label:not(.chip):not(.check):not(.item-points):not(.item-icon) { display: block; margin-bottom: .4rem; color: var(--green); font-size: .92rem; font-weight: 800; }
.field { min-width: 0; }
.field-row { display: flex; flex-wrap: wrap; gap: 1rem 1.2rem; align-items: flex-end; }
.field-row > .field { flex: 1 1 140px; }
.field-row > fieldset.field { flex: 0 1 auto; }
.field-row > .field-narrow { flex: 0 1 130px; }
.field-row > .field-grow { flex: 2 1 200px; }
.gen-controls input[type="text"], .gen-controls input[type="number"], .gen-controls select, .gen-controls textarea, .add-item input { width: 100%; min-height: 46px; padding: .6rem .8rem; border: 1.5px solid #cdbfa9; border-radius: 12px; background: var(--paper); color: var(--ink); }
.gen-controls textarea { min-height: 0; resize: vertical; font: inherit; line-height: 1.5; }
.gen-example { position: relative; height: 100%; }
.gen-example svg { opacity: .42; filter: grayscale(.4); }
.gen-example p { position: absolute; left: 50%; top: 50%; width: min(80%, 22rem); margin: 0; padding: .8rem 1rem; border-radius: 14px; background: var(--paper); box-shadow: 0 6px 20px rgba(39,75,61,.16); color: var(--green); font-weight: 750; text-align: center; transform: translate(-50%, -50%); }
.gen-controls input:focus-visible, .gen-controls select:focus-visible, .gen-controls textarea:focus-visible, .add-item input:focus-visible { border-color: var(--orange); outline: 3px solid rgba(232,121,66,.35); outline-offset: 1px; }
.help { margin: .35rem 0 0; color: var(--muted); font-size: .88rem; }

.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip > span { display: flex; min-height: 44px; padding: .55rem .95rem; flex-direction: column; justify-content: center; border: 1.5px solid #cdbfa9; border-radius: 14px; background: var(--paper); color: var(--green); font-weight: 800; line-height: 1.2; }
.chip small { margin-top: .15rem; color: var(--muted); font-size: .78rem; font-weight: 600; }
.chip input:checked + span { border-color: var(--green); background: var(--green); color: white; }
.chip input:checked + span small { color: rgba(255,255,255,.8); }
.chip input:focus-visible + span { outline: 3px solid var(--orange); outline-offset: 2px; }
.chips-layout .chip { flex: 1 1 150px; }
.chips-small { flex-wrap: nowrap; }
.chips-small .chip > span { padding: .5rem .8rem; white-space: nowrap; }
.chips-stack { flex-direction: column; }
.chips-stack .chip > span { white-space: normal; }
.gen-controls input[type="file"] { padding: .45rem; font: inherit; }

.checks { display: flex; flex-wrap: wrap; gap: .4rem 1.4rem; }
.check { display: inline-flex; min-height: 40px; align-items: center; gap: .55rem; cursor: pointer; font-weight: 650; }
.check input { width: 1.2rem; height: 1.2rem; accent-color: var(--green); }
.range { display: flex; min-height: 46px; align-items: center; gap: .6rem; color: var(--muted); font-size: .86rem; }
.range input { flex: 1; accent-color: var(--orange); }
.row-buttons { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1rem; }

.group { border: 1.5px solid var(--cream-deep); border-radius: 18px; background: rgba(255,250,243,.6); }
.group summary { display: flex; min-height: 52px; padding: .75rem 1rem; align-items: center; gap: .5rem; color: var(--green); cursor: pointer; font-weight: 800; list-style: none; }
.group summary::-webkit-details-marker { display: none; }
.group summary::after { content: "+"; margin-left: auto; font-size: 1.3rem; transition: transform .2s; }
.group[open] summary::after { transform: rotate(45deg); }
.group-meta { color: var(--muted); font-weight: 650; }
.group-body { display: grid; padding: 0 1rem 1rem; gap: 1rem; }

.item-editor { display: grid; max-height: 420px; margin: 0; padding: 0 .25rem 0 0; overflow-y: auto; gap: .4rem; list-style: none; counter-reset: item; }
.item-row { display: flex; align-items: center; gap: .4rem; counter-increment: item; }
.item-row::before { content: counter(item); width: 1.6rem; flex: none; color: var(--muted); font-size: .8rem; font-weight: 750; text-align: right; }
.item-row .item-text { flex: 1 1 auto; min-height: 40px !important; padding: .4rem .6rem !important; }
.item-points input { width: 3.6rem !important; min-height: 40px !important; padding: .4rem !important; text-align: center; }
.item-pic { display: grid; width: 44px; height: 44px; flex: none; place-items: center; padding: 0; border: 1.5px solid #cdbfa9; border-radius: 12px; background: var(--paper); color: var(--muted); cursor: pointer; font-size: .9rem; font-weight: 800; }
.item-pic.is-empty { border-style: dashed; }
.item-pic img { width: 30px; height: 30px; }
.item-pic:hover { border-color: var(--green-mid); }
.item-pic:focus-visible, .pic-tile:focus-visible, .pic-close:focus-visible { outline: 3px solid rgba(232,121,66,.45); outline-offset: 2px; }
.pics-help { margin: 0 0 .1rem; color: var(--muted); font-size: .86rem; line-height: 1.45; }
.pic-dialog { width: min(720px, calc(100vw - 2rem)); max-height: min(84vh, 760px); padding: 0; border: 0; border-radius: 24px; background: var(--paper); color: var(--ink); box-shadow: 0 24px 60px rgba(39,75,61,.28); }
.pic-dialog[open] { display: flex; flex-direction: column; }
.pic-dialog::backdrop { background: rgba(31,40,35,.42); }
.pic-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.25rem .2rem; }
.pic-head h3 { margin: 0; color: var(--green); font-size: 1.3rem; line-height: 1.25; }
.pic-close { width: 40px; height: 40px; flex: none; border: 0; border-radius: 10px; background: transparent; color: var(--muted); cursor: pointer; font-size: 1.5rem; }
.pic-close:hover { background: var(--cream-deep); color: var(--green); }
.pic-help { margin: 0 1.25rem .6rem; color: var(--muted); font-size: .88rem; line-height: 1.45; }
.pic-search { margin: 0 1.25rem .6rem; width: auto !important; min-height: 46px; padding: .6rem .8rem; border: 1.5px solid #cdbfa9; border-radius: 12px; background: #fff; color: var(--ink); font: inherit; }
.pic-search:focus-visible { border-color: var(--orange); outline: 3px solid rgba(232,121,66,.35); outline-offset: 1px; }
.pic-body { flex: 1 1 auto; padding: 0 1.25rem 1.25rem; overflow-y: auto; overscroll-behavior: contain; }
.pic-sub { margin: 1rem 0 .5rem; color: var(--green); font-size: .9rem; font-weight: 800; }
.pic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: .5rem; }
.pic-tile { display: grid; min-height: 96px; justify-items: center; align-content: start; gap: .3rem; padding: .55rem .3rem .45rem; border: 1.5px solid transparent; border-radius: 14px; background: #fff; color: var(--ink); cursor: pointer; font: inherit; font-size: .78rem; line-height: 1.2; text-align: center; overflow-wrap: anywhere; }
.pic-tile img { width: 44px; height: 44px; }
.pic-tile:hover { border-color: var(--green-soft); background: var(--cream); }
.pic-tile[aria-pressed="true"] { border-color: var(--green); background: var(--green-soft); }
.pic-none { grid-column: span 2; grid-template-columns: auto 1fr; align-items: center; align-content: center; justify-items: start; min-height: 64px; padding: .5rem .8rem; border: 1.5px dashed #cdbfa9; text-align: left; }
.pic-num { display: grid; width: 40px; height: 40px; place-items: center; border: 2px solid var(--muted); border-radius: 50%; color: var(--muted); font-size: 1.05rem; font-weight: 800; }
.pic-empty { margin: 1rem 0 0; color: var(--muted); }
.item-remove { width: 40px; height: 40px; flex: none; border: 0; border-radius: 10px; background: transparent; color: var(--muted); cursor: pointer; font-size: 1.4rem; }
.item-remove:hover { background: var(--cream-deep); color: var(--orange-dark); }
.add-item { display: flex; gap: .5rem; }
.paste-field textarea { min-height: 150px; }

.gen-actions { display: flex; margin: 1.4rem 0 0; flex-wrap: wrap; gap: .6rem; }
.gen-actions .gen-primary { flex: 1 1 100%; min-height: 56px; font-size: 1.08rem; }
.gen-actions .button-secondary { flex: 1 1 0; }
.button[aria-busy="true"] { opacity: .65; cursor: progress; }
.gen-sticky { position: fixed; right: 0; bottom: 0; left: 0; z-index: 90; padding: .75rem 1rem calc(.75rem + env(safe-area-inset-bottom)); background: rgba(247,240,230,.95); box-shadow: 0 -6px 20px rgba(39,75,61,.12); }
.gen-sticky .button { width: 100%; }
@media (min-width: 901px) { .gen-sticky { display: none; } }

.play-panel { position: relative; margin-top: 1.6rem; padding: 1.5rem 1.5rem 1.3rem; border-radius: 26px; background: var(--green); color: rgba(255,255,255,.86); }
.play-panel h2 { margin-bottom: .5rem; color: white; font-size: 1.55rem; }
.play-panel p { font-size: .98rem; }
.play-panel .store-buttons { margin-top: .4rem; }
.play-panel .button { border-color: var(--yellow); background: var(--yellow); color: var(--green); }
.play-panel .button:hover { background: white; border-color: white; }
.play-doodle { position: absolute; top: 1rem; right: 1.2rem; color: rgba(255,255,255,.55); }
.play-note { margin: .9rem 0 0; font-size: .86rem !important; opacity: .85; }

/* Ideas list */
.ideas-head { max-width: 760px; margin-bottom: 2rem; }
.ideas-head p { color: var(--muted); }
.ideas-groups { columns: 3 280px; column-gap: 2.5rem; }
.idea-group { margin-bottom: 2rem; break-inside: avoid; }
.idea-group h3 { margin-bottom: .6rem; font-size: 1.25rem; }
.idea-group ul { margin: 0; padding: 0; list-style: none; }
.idea-group li { display: flex; min-height: 40px; padding: .3rem 0; align-items: center; gap: .7rem; border-bottom: 1px dashed var(--cream-deep); }
.idea-group li img { flex: none; }
.idea-dot { width: 28px; height: 28px; flex: none; border: 1.5px solid #9aa79f; border-radius: 8px; }
.idea-text { flex: 1; }
.idea-level { flex: none; padding: .1rem .5rem; border-radius: 999px; background: var(--green-soft); color: var(--green); font-size: .74rem; font-weight: 800; white-space: nowrap; }
.idea-level.d2 { background: #fbe5c4; color: #7a4b07; }
.idea-level.d3 { background: #f9d3c0; color: #8a3610; }

/* How to */
.howto-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(2rem, 5vw, 4rem); }
.howto h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); }
.howto h3 { margin-top: 1.8rem; font-size: 1.3rem; }
.facts { display: grid; margin: 1.5rem 0; grid-template-columns: repeat(2, 1fr); gap: .7rem; }
.facts div { padding: .8rem 1rem; border-radius: 16px; background: var(--paper); }
.facts dt { color: var(--muted); font-size: .8rem; font-weight: 800; }
.facts dd { margin: 0; color: var(--green); font-weight: 800; }
.pin-image { width: min(100%, 320px); margin-top: 1.5rem; border-radius: 8px; box-shadow: 0 14px 34px rgba(39,75,61,.16); }

.tip-grid, .format-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.1rem; }
.tip-grid article, .format-grid article { padding: 1.5rem; border: 1px solid var(--cream-deep); border-radius: 22px; background: var(--paper); }
.section-tint .tip-grid article, .section-tint .format-grid article { border-color: transparent; }
.tip-grid h3, .format-grid h3 { font-size: 1.25rem; }
.tip-grid p, .format-grid p { margin: 0; color: var(--muted); }

.hunt-compare .compare-table td:last-child { color: var(--green); font-weight: 650; }

/* Hub */
.hub-hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(1.5rem, 4vw, 4rem); align-items: center; }
.hub-hero .hero-actions { display: flex; margin: 1.6rem 0; flex-wrap: wrap; gap: .8rem; }
.feature-list { display: grid; margin: 0; padding: 0; gap: .55rem; list-style: none; }
.feature-list li { display: flex; align-items: center; gap: .7rem; font-weight: 650; }
.feature-list svg { flex: none; color: var(--orange-dark); }
.hub-stack { position: relative; min-height: 420px; }
.hub-stack img { position: absolute; width: 58%; border-radius: 4px; box-shadow: 0 16px 36px rgba(39,75,61,.2); }
.hub-stack .stack-1 { z-index: 3; top: 4%; left: 22%; transform: rotate(-3deg); }
.hub-stack .stack-2 { z-index: 2; top: 12%; left: 0; transform: rotate(-9deg); }
.hub-stack .stack-3 { z-index: 1; top: 10%; right: 0; transform: rotate(6deg); }
.row-head { display: flex; margin-bottom: 1.2rem; flex-wrap: wrap; align-items: baseline; gap: .4rem 1rem; }
.row-head h2 { margin: 0; font-size: clamp(1.7rem, 3vw, 2.3rem); }
.row-head p { margin: 0; color: var(--muted); }
.catalog-group { margin: 2.2rem 0 1rem; font-size: 1.45rem; }
.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.1rem; }
.theme-card { display: flex; overflow: hidden; flex-direction: column; border: 1px solid var(--cream-deep); border-radius: 22px; background: var(--paper); color: var(--ink); text-decoration: none; transition: transform .18s, border-color .18s; }
.theme-card:hover { border-color: var(--orange); transform: translateY(-3px); }
.theme-card .thumb { display: block; padding: 1rem 1.2rem 0; background: var(--cream-deep); }
.theme-card .thumb img { width: 100%; aspect-ratio: 600 / 848; object-fit: cover; object-position: top; border-radius: 3px 3px 0 0; box-shadow: 0 6px 18px rgba(39,75,61,.14); }
.theme-card .card-body { display: flex; padding: 1rem 1.2rem 1.2rem; flex-direction: column; gap: .2rem; }
.theme-card strong { color: var(--green); font-family: ui-serif, Georgia, serif; font-size: 1.3rem; }
.theme-card .count { color: var(--orange-dark); font-size: .86rem; font-weight: 800; }
.theme-card .samples { color: var(--muted); font-size: .9rem; }
.theme-card-custom .custom-art { display: grid; padding: 1.4rem 0 .4rem; place-items: center; background: var(--cream-deep); }
.hunt-steps { display: grid; margin: 0; padding: 0; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; list-style: none; }
.hunt-steps li > span { display: grid; width: 44px; height: 44px; margin-bottom: .8rem; place-items: center; border-radius: 50%; background: var(--orange-strong); color: white; font-weight: 800; }
.hunt-steps h3 { font-size: 1.25rem; }
.hunt-steps p { color: var(--muted); }
.hunt-steps-stacked { grid-template-columns: 1fr; }
.bingo-card { display: flex; padding: 1.4rem 1.6rem; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; border: 1.5px dashed #cdbfa9; border-radius: 22px; color: var(--ink); text-decoration: none; }
.bingo-card strong { color: var(--green); }
.bingo-card b { color: var(--orange-dark); }
.bingo-card:hover { border-color: var(--orange); }

/* Handoff */
.handoff-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.handoff-list { padding: 1.6rem; border-radius: 26px; background: var(--paper); box-shadow: var(--shadow); }
.handoff-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.handoff-head h2 { font-size: 1.7rem; }
.handoff-head span { color: var(--muted); font-weight: 700; }
.handoff-list ol { margin: 0 0 1.4rem; padding-left: 1.6rem; columns: 2 220px; column-gap: 2rem; }
.handoff-list li { padding: .25rem 0; break-inside: avoid; }
.handoff-steps h2 { font-size: 1.7rem; }

@media (max-width: 900px) {
    .gen-grid, .howto-grid, .hub-hero-grid, .handoff-grid { grid-template-columns: 1fr; }
    .gen-stage { position: static; }
    .gen-sheet { max-width: 440px; }
    .hub-stack { min-height: 300px; max-width: 460px; }
    .hunt-steps { grid-template-columns: repeat(2, 1fr); }
    .hunt-generator { padding-bottom: 5rem; }
}
@media (max-width: 560px) {
    .hunt-steps { grid-template-columns: 1fr; }
    .facts { grid-template-columns: 1fr 1fr; }
    .gen-desk { padding: 1rem; border-radius: 28px; }
    .gen-desk::after { width: 60px; height: 46px; right: -4px; }
    .pic-grid { grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); }
    .pic-none { grid-column: 1 / -1; }
    .play-doodle { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    .theme-card, .gen-sheet { transition: none; transform: none; }
    .theme-card:hover { transform: none; }
}
@media print {
    .site-header, .site-footer, .tilesy, .cookie-banner, .gen-sticky { display: none !important; }
}
