/* ==========================================================================
   Resources (/resources/) — extends the shared page kit (page.css). Wrap: <div class="pg res-page">.
   Sections: hero (page.css) → 01 guides → 02 checklists → 03 tools → 04 ask → 05 newsletter → pg-close.
   Plan: design-runs/2026-09-28-site-v3/pages/00-plan.md §4
   ========================================================================== */

/* ==========================================================================
   Round 2 (chatgpt review, 2026-09-29): design-runs/2026-09-28-site-v3/review/resources/
   {chatgpt,triage}.md. Less card UI, denser Tools, one conversion section (Ask me),
   no newsletter/closing-CTA on this page. The .pg-crumbs 44px fix is now in the kit
   (page.css) — the old local override here is gone.
   ========================================================================== */

/* ---- Hero: tighter copy column + compact fact rows + custom CTA row ------------------ */

.res-page .pg-hero__lede { max-width: 520px; }

/* .pg-facts (page.css) rows measured ~50px; target ~36–42px. Padding only — body text
   stays 16px on phones (gate), so the row shrinks from breathing room, not type size. */
.res-page .pg-facts li { padding-block: 7px; }

.res-hero__actions .why-btn--whatsapp { border-color: var(--slate-300); }
.res-hero__down { transition: transform var(--t-base) var(--ease-out); }
.res-hero__actions .why-btn--primary:hover .res-hero__down { transform: translateY(3px); }

/* Round 3 (chatgpt re-review): mobile hero still too tall before the resources. Portrait
   panel ~18% shorter (page.css default is min(80%,320px) at <1200px; before that, the
   640–1199 tier is min(56%,400px)), tighter media padding, and facts forced 2×2 even
   under page.css's own 560px breakpoint — text size stays 16px throughout (gate). */
/* (Portrait size: the kit's hero stage since the owner's 2026-09-29 feedback — full seated
   figure, crop 1, centred, with the page's recommended tools around it.) */

@media (max-width: 559.98px) {
  .res-page .pg-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 14px; }
}

/* ---- 01 Guides: tone-coloured cards linking to /blog/{slug}/ ------------------------ */

.res-guides { background: var(--paper); scroll-margin-top: calc(var(--bar-h) + 16px); }
.res-dots--guides { --dots-at: 85% 15%; }

.res-guides__grid {
  display: grid;
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Round 2: 10–15% less padding, the title carries the card. */
.res-guide {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 22px 20px 20px;
  border: 1px solid var(--tone-line);
  border-radius: var(--r-xl);
  background: var(--tone-bg);
  color: inherit;
  text-decoration: none;
  transition: transform var(--t-base) var(--ease-out), box-shadow var(--t-base) var(--ease-out), border-color var(--t-fast) var(--ease-out);
}

.res-guide:hover { transform: translateY(-4px); border-color: var(--tone-edge); box-shadow: var(--shadow-panel); }
.res-guide:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 3px; }

.res-guide__body { display: flex; flex: 1; flex-direction: column; min-width: 0; }

.res-guide__icon {
  display: grid;
  flex-shrink: 0;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 16px;
  border: 1px solid var(--tone-edge);
  border-radius: 50%;
  background: var(--paper);
  color: var(--tone-mark);
}

.res-guide__topic {
  margin: 0 0 6px;
  color: var(--tone-ink);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.res-guide__title {
  display: block;
  color: var(--ink-900);
  font-family: var(--font-serif);
  font-size: 1.375rem;
  font-weight: 600;
  line-height: 1.25;
}

.res-guide__excerpt {
  display: block;
  flex: 1;
  margin-top: 8px;
  color: var(--slate-700);
  font-size: 1rem;
  line-height: 1.5;
}

.res-guide__read {
  margin-top: 16px;
  color: var(--tone-ink);
}

.res-guide:hover .res-guide__read svg { transform: translateX(3px); }

/* Round 2 (chatgpt review): one clear entry point — the first guide is featured: full
   width, horizontal layout, a bigger serif title carrying the section. */
.res-guides__featured { grid-column: 1 / -1; }

.res-guide--featured {
  flex-direction: row;
  align-items: flex-start;
  gap: 22px;
  padding: 26px 28px;
}

.res-guide--featured .res-guide__icon { width: 52px; height: 52px; margin-bottom: 0; }
.res-guide--featured .res-guide__body { display: flex; flex-direction: column; min-width: 0; }
.res-guide--featured .res-guide__title { font-size: 1.75rem; }
.res-guide--featured .res-guide__excerpt { max-width: 46rem; }

@media (max-width: 639.98px) {
  .res-guide--featured { flex-direction: column; }
}

/* Round 3 (chatgpt re-review): the featured card already spans the full row; the other
   two must split the SAME full width 50/50, not sit 2-of-3 with an empty cell. So this
   stays a 2-column grid at every width from 640px up — never 3. */
@media (min-width: 640px) {
  .res-guides__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1024px) {
  .res-guides__grid { gap: 22px; }
}

/* ---- 02 Checklists: print-friendly <details>, real checkboxes, zero-JS-required tick -- */

/* Round 2 (chatgpt review): "the checklist itself should provide the density, not the
   container" — panel padding 20–24px, header 56–64px, rows 48–56px, section 72–88px. */
.res-checklists.pg-section { padding-block: clamp(64px, 6vw, 88px); background: var(--warm-50); }

.res-check-grid {
  display: grid;
  gap: 18px;
  margin: 0;
  padding: 0;
}

.res-check {
  border: 1px solid var(--tone-line);
  border-radius: var(--r-lg);
  background: var(--paper);
}

.res-check summary {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 20px;
  align-items: center;
  gap: 14px;
  min-height: 44px;
  padding: 13px 20px;
  color: var(--ink-900);
  list-style: none;
  cursor: pointer;
}

.res-check summary::-webkit-details-marker { display: none; }
.res-check summary:focus-visible { outline: 2px solid var(--color-focus); outline-offset: -2px; border-radius: var(--r-lg); }

.res-check__icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--tone-edge);
  border-radius: 50%;
  background: var(--tone-bg);
  color: var(--tone-mark);
}

.res-check__icon svg { width: 18px; height: 18px; }

.res-check__head { display: grid; gap: 1px; }
.res-check__head strong { font-size: 1rem; font-weight: 700; line-height: 1.3; }
.res-check__head span { color: var(--slate-600); font-size: 0.8125rem; }

.res-check__chev { color: var(--slate-500); transition: transform var(--t-base) var(--ease-out); }
.res-check[open] .res-check__chev { transform: rotate(180deg); }

.res-check__list {
  margin: 0;
  padding: 0 20px 16px;
  list-style: none;
  border-top: 1px solid var(--slate-200);
}

.res-check__list li { border-bottom: 1px solid var(--slate-200); }
.res-check__list li:last-child { border-bottom: 0; }

.res-check__list label {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: start;
  gap: 12px;
  min-height: 44px;
  padding: 11px 0;
  cursor: pointer;
}

.res-check__list input[type="checkbox"] {
  width: 22px;
  height: 22px;
  margin-top: 1px;
  accent-color: var(--tone-mark);
}

.res-check__list input[type="checkbox"]:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 3px; }

.res-check__text {
  color: var(--slate-800);
  font-size: 1rem;
  line-height: 1.5;
  text-wrap: pretty;
}

/* Tick a box: no JS required (public/js/resources.js only persists the state). */
.res-check__list li:has(input:checked) .res-check__text {
  color: var(--slate-500);
  text-decoration: line-through;
  text-decoration-color: var(--slate-400);
}

/* Round 3 (chatgpt re-review): items past #7 sit behind a native nested <details> — no
   JS needed to reveal them; resources.js still finds every [data-check-item] regardless
   of whether this is open, so ticking/localStorage work on hidden items too. */
.res-check__more-row { padding: 0; border-bottom: 0 !important; }

.res-check__reveal summary {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding-block: 10px;
  color: var(--tone-ink);
  font-size: 1rem;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}

.res-check__reveal summary::-webkit-details-marker { display: none; }
.res-check__reveal summary:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; border-radius: 6px; }
.res-check__reveal[open] summary .res-check__chev { transform: rotate(180deg); }
.res-check__reveal .res-check__chev { width: 16px; height: 16px; }

.res-check__list--nested { margin: 0; padding: 0; border-top: 0; }

.res-check__print-only { display: none; }

@media (min-width: 1024px) {
  .res-check-grid { gap: 22px; }
  .res-check__list { padding-inline: 24px; }
  .res-check summary { padding-inline: 24px; }
}

/* ---- 03 Tools I recommend: a dense editorial directory, not product cards (round 2) -- */

.res-tools.pg-section { padding-block: clamp(56px, 6vw, 88px); background: var(--paper); }

.res-tools__groups {
  display: grid;
  gap: clamp(28px, 3.5vw, 40px);
  margin-top: clamp(8px, 2vw, 16px);
}

.res-tools__group-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 16px;
  color: var(--ink-900);
  font-size: 1.0625rem;
  font-weight: 700;
}

.res-tools__group-title svg { color: var(--blue-600); }

/* Round 3 (chatgpt re-review): mobile gets a visible break between categories — a rule
   plus a little extra room — instead of the groups just running together. */
@media (max-width: 767.98px) {
  .res-tools__group:not(:first-child) { padding-top: 18px; border-top: 1px solid var(--slate-200); }
}

/* Round 3: flex-wrap, not a fixed-column grid — a short category (Website: 2 tools)
   stretches to fill the row instead of leaving an implied-missing 3rd/4th slot, and a
   longer category's last, partial row stretches too rather than trailing off into blank
   cells. flex-basis ~260px settles near 4 columns at 1440px, 2 at tablet, 1 on phones. */
.res-tools__grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.res-tools__grid > li { flex: 1 1 300px; min-width: 0; }

/* Round 2 (chatgpt review): rows, not product cards — no border box, no pricing pill,
   no boxed logo tile. ~64–72px each; the whole page's tool count reads as one working
   toolbox instead of a SaaS directory. */
.res-tool {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  border: 0;
  border-bottom: 1px solid var(--slate-200);
  border-radius: 0;
  background: none;
  color: inherit;
  text-decoration: none;
  transition: background-color var(--t-fast) var(--ease-out);
}

.res-tool:hover { background: var(--warm-50); }
.res-tool:hover .res-tool__name { color: var(--blue-700); }
.res-tool:focus-visible { outline: 2px solid var(--color-focus); outline-offset: -2px; border-radius: 6px; }

.res-tool__logo {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
}

.res-tool__logo svg { width: 22px; height: 22px; }

.res-tool__body { display: grid; gap: 1px; min-width: 0; }

.res-tool__name {
  display: block;
  color: var(--ink-900);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.3;
  transition: color var(--t-fast) var(--ease-out);
}

.res-tool__tag {
  margin-left: 2px;
  color: var(--slate-500);
  font-size: 0.8125rem;
  font-weight: 600;
  white-space: nowrap;
}

.res-tool__use {
  color: var(--slate-600);
  font-size: 1rem;
  line-height: 1.35;
}

.res-tool__ext { flex-shrink: 0; color: var(--slate-400); }

@media (min-width: 640px) {
  .res-tools__grid { gap: 0 28px; }
}

@media (min-width: 1024px) {
  .res-tools__grid { gap: 0 24px; }
}

/* ---- 04 Ask me: free 15-minute call, never a PDF ------------------------------------- */

/* Round 2 (chatgpt review): this is the page's one real conversion section — compressed
   to ~360–420px on desktop, not competing with a closing CTA or newsletter any more. */
.res-ask.pg-section { padding-block: clamp(44px, 5vw, 64px); background: var(--warm-50); }
.res-dots--ask { --dots-at: 90% 20%; }

.res-ask__grid { display: grid; gap: 36px; align-items: start; }

.res-ask__actions { margin-top: 24px; }

.res-ask__steps {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--slate-200);
}

.res-ask__steps li {
  position: relative;
  display: grid;
  grid-template-columns: 26px 38px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding-block: 12px;
  border-bottom: 1px solid var(--slate-200);
  color: var(--ink-900);
  font-size: 1rem;
  line-height: 1.4;
}

.res-ask__num {
  color: var(--slate-400);
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  font-variant-numeric: tabular-nums;
}

.res-ask__icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid #D6E3FB;
  border-radius: 50%;
  background: #EAF1FE;
  color: var(--blue-600);
}

.res-ask__icon svg { width: 18px; height: 18px; }

/* Round 3 (chatgpt re-review): on phones this should read as a decisive closing block,
   not another content section — section padding −~25%, a tighter 2-button group, and
   step rows down to ~52–56px (icon 38→32, padding 12→9). */
@media (max-width: 767.98px) {
  .res-ask.pg-section { padding-block: 34px; }
  .res-ask__actions { gap: 8px; margin-top: 20px; }
  .res-ask__steps li { grid-template-columns: 22px 32px minmax(0, 1fr); gap: 10px; padding-block: 9px; }
  .res-ask__icon { width: 32px; height: 32px; }
  .res-ask__icon svg { width: 16px; height: 16px; }
}

@media (min-width: 1024px) {
  .res-ask__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 0.85fr); gap: 56px; }
}

/* ---- 05 Newsletter band (same honesty rule as the footer) ---------------------------- */

.res-newsletter { background: var(--paper); }

.res-newsletter__grid { display: grid; gap: 24px; align-items: center; }

.res-newsletter__field {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 6px 6px 18px;
  border: 1.5px solid var(--slate-300);
  border-radius: var(--r-lg);
  background: var(--warm-50);
}

.res-newsletter__field svg { flex-shrink: 0; color: var(--slate-500); }

.res-newsletter__field input {
  flex: 1;
  min-width: 0;
  height: 44px;
  border: 0;
  background: none;
  color: var(--ink-900);
  font-size: 1rem;
  font-family: inherit;
}

.res-newsletter__field input::placeholder { color: var(--slate-400); }
.res-newsletter__field input:focus-visible { outline: none; }
.res-newsletter__field:focus-within { border-color: var(--blue-600); }

.res-newsletter__field button {
  display: grid;
  flex-shrink: 0;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: var(--r-md);
  background: var(--color-primary);
  color: var(--color-on-primary);
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease-out);
}

.res-newsletter__field button:hover { background: var(--color-primary-hover); }
.res-newsletter__field button:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }

fieldset:disabled .res-newsletter__field { opacity: 0.6; }
fieldset:disabled .res-newsletter__field button { cursor: not-allowed; }

.res-newsletter__note {
  margin: 10px 0 0;
  color: var(--slate-600);
  font-size: 0.875rem;
}

@media (min-width: 1024px) {
  .res-newsletter__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 0.75fr); gap: 48px; }
}

/* ---- Print: a checklist should print cleanly, chrome stripped ------------------------ */

@media print {
  .res-page .pg-hero,
  .res-page .res-guides,
  .res-page .res-tools,
  .res-page .res-ask,
  .res-page .res-newsletter,
  .res-page .pg-close,
  .res-page .res-check__chev {
    display: none;
  }

  .res-checklists { background: #fff; padding-block: 12px; }
  .res-check { border-color: #999; break-inside: avoid; page-break-inside: avoid; }
  .res-check:not(:last-child) { margin-bottom: 14px; }

  /* Force <details> content visible on paper regardless of the on-screen open state —
     both the outer checklist AND the round-3 nested "Show all N" reveal, so a printed
     checklist always shows every item, not just the first 7. */
  .res-check:not([open]) > *:not(summary) { display: block !important; }
  .res-check__reveal:not([open]) > *:not(summary) { display: block !important; }
  .res-check__reveal summary { display: none; }

  .res-check summary { cursor: default; }
  .res-check__list input[type="checkbox"] { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .res-check__print-only { display: block; margin: 0; padding: 14px 22px 18px; color: #666; font-size: 0.75rem; }
}

/* Owner (2026-09-29): no wasted height. Desktop: the 3 checklists side by side (all open),
   so the section is one column-height, not three stacked lists. Phones: resources.js keeps
   only the first open (no-JS: all open, still usable). */
@media (min-width: 1100px) {
  .res-check-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; }
}
