/* Free templates (POP-116) — printable artifact, email-gate modal, hub grid.
   Reuses styles.css tokens + core recipe. No inline CSS. */

/* ── Hub grid ── */
.res-hero { padding: 48px 0 8px; }
.res-hero h1 { font-family: var(--disp); font-weight: 800; font-size: clamp(32px, 5vw, 50px); letter-spacing: -.03em; margin: 16px 0 12px; }
.res-hero .res-intro { font-size: 18px; color: var(--g500); font-weight: 600; max-width: 640px; }
.res-grid-sec { padding: 32px 0 80px; }
.res-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.res-card { background: #fff; border: var(--bd); border-radius: 16px; padding: 24px; box-shadow: var(--sh); transition: transform .12s, box-shadow .12s; }
.res-card:hover { transform: translate(-2px, -2px); box-shadow: var(--sh-lg); }
.res-tag { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; background: var(--lime); border: var(--bd); border-radius: 8px; padding: 3px 8px; box-shadow: 2px 2px 0 var(--ink); margin-bottom: 14px; }
.res-card h2 { font-family: var(--disp); font-weight: 800; font-size: 20px; letter-spacing: -.02em; margin-bottom: 8px; }
.res-card h2 a { color: var(--ink); text-decoration: none; }
.res-card p { color: var(--g500); font-size: 15px; font-weight: 500; line-height: 1.5; margin: 0; }

/* ── Template page ── */
.tpl-wrap { max-width: 820px; }
.tpl-dl { margin-top: 20px; }
.tpl-sec { padding-top: 0; }
.tpl-howto { max-width: 760px; margin: 32px auto 0; color: var(--g700); font-size: 16px; line-height: 1.7; }
.tpl-howto a { color: var(--coral); font-weight: 600; }

/* The printable artifact sheet */
.tpl { background: #fff; border: var(--bd); border-radius: 16px; box-shadow: var(--sh-lg); padding: 36px; }
.tpl-head { border-bottom: var(--bd); padding-bottom: 16px; margin-bottom: 22px; }
.tpl-head h2 { font-family: var(--disp); font-weight: 800; font-size: 24px; letter-spacing: -.02em; }
.tpl-head p { color: var(--g500); font-size: 14px; font-weight: 600; margin-top: 4px; }

.tpl-group { margin-bottom: 22px; }
.tpl-group > .tpl-gh { display: block; font-family: var(--disp); font-weight: 800; font-size: 16px; margin-bottom: 12px; }

.tpl-field { margin-bottom: 16px; }
.tpl-field .tpl-label { display: block; font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--g500); margin-bottom: 6px; }
.tpl-field .tpl-line { display: block; width: 100%; border: 1.5px dashed var(--g400); border-radius: 8px; min-height: 40px; padding: 8px 10px; color: var(--ink); font-family: var(--body); font-size: 13px; font-weight: 600; background: #fff; }
.tpl-field .tpl-line::placeholder { color: var(--g400); }
.tpl-field textarea.tpl-line { resize: vertical; line-height: 1.5; }
.tpl-field .tpl-line:focus { outline: none; box-shadow: 3px 3px 0 var(--coral); }

/* Two-column do / don't */
.tpl-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.tpl-col { border: var(--bd); border-radius: 12px; padding: 16px; }
.tpl-col.tpl-do { background: rgba(203, 242, 78, .18); }
.tpl-col.tpl-dont { background: rgba(255, 86, 48, .08); }
.tpl-col h4 { font-family: var(--disp); font-weight: 800; font-size: 15px; margin-bottom: 10px; }
.tpl-col ul { margin: 0; padding-left: 18px; }
.tpl-col li { font-size: 14px; color: var(--g700); font-weight: 600; margin-bottom: 8px; }

/* Checklist */
.tpl-check { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 10px; font-size: 15px; color: var(--g700); font-weight: 600; }
.tpl-check .tpl-box { flex: none; width: 20px; height: 20px; border: var(--bd); border-radius: 6px; margin-top: 1px; }

/* ── Email-gate modal ── */
.rm-modal { position: fixed; inset: 0; z-index: 300; display: none; align-items: center; justify-content: center; padding: 20px; background: rgba(26, 21, 16, .55); }
.rm-modal.is-open { display: flex; }
.rm-card { background: var(--paper); border: var(--bd); border-radius: 18px; box-shadow: var(--sh-lg); padding: 28px; max-width: 420px; width: 100%; }
.rm-card h3 { font-family: var(--disp); font-weight: 800; font-size: 22px; letter-spacing: -.02em; margin-bottom: 6px; }
.rm-card p { color: var(--g500); font-size: 14px; font-weight: 600; margin-bottom: 18px; }
.rm-card .rm-email { width: 100%; border: var(--bd); border-radius: 12px; padding: 12px 14px; font-family: var(--body); font-size: 15px; font-weight: 600; background: #fff; box-shadow: var(--sh-sm); }
.rm-card .rm-email:focus { outline: none; box-shadow: 3px 3px 0 var(--coral); }
.rm-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.rm-err { color: var(--coral); font-size: 13px; font-weight: 700; min-height: 18px; margin-top: 8px; }
.rm-actions { display: flex; gap: 10px; margin-top: 8px; }
.rm-actions .btn { flex: 1; justify-content: center; }

/* ── Print: isolate the artifact ── */
@media print {
    nav, footer, .hero, .tpl-hero, .final, .rm-modal, .tpl-howto, [data-download], .res-hero, .cookie-consent { display: none !important; }
    body { background: #fff; }
    main, .wrap, .tpl-wrap { margin: 0; padding: 0; max-width: none; }
    .tpl { border: 1.5px solid #000; border-radius: 0; box-shadow: none; padding: 24px; }
    .tpl-field .tpl-line { color: #000; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
    .tpl-col { break-inside: avoid; }
    .tpl-group, .tpl-field, .tpl-check { break-inside: avoid; }
}

@media (max-width: 720px) {
    .res-grid { grid-template-columns: 1fr; }
    .tpl-2col { grid-template-columns: 1fr; }
    .tpl { padding: 24px; }
}
