/* ==========================================================
   Phoenix Survival Guide — shared stylesheet
   Warm desert palette. Edit the variables below to re-theme.
   ========================================================== */
:root {
  --sand-50: #fdf8f1;
  --sand-100: #f8eddd;
  --sand-200: #efdcc0;
  --clay: #b8461b;        /* primary (terracotta) — AA on white */
  --clay-dark: #8a3212;
  --sunset: #e8772e;
  --sun: #f4b33f;
  --saguaro: #2f5d50;     /* secondary (desert green) */
  --saguaro-dark: #1f4238;
  --sky: #1f4e79;
  --ink: #2a1e17;
  --ink-soft: #5a4639;
  --danger: #a8170f;
  --danger-bg: #fdecea;
  --white: #ffffff;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(74, 38, 16, 0.10);
  --max: 1140px;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-head: "Fraunces", Georgia, "Times New Roman", serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--sand-50);
}
img { max-width: 100%; height: auto; }
a { color: var(--clay-dark); text-underline-offset: 3px; }
a:hover { color: var(--clay); }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 2px; border-radius: 4px; }

h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.2; color: var(--ink); margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 4.5vw, 3.2rem); font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin-top: 0; }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
ul, ol { padding-left: 1.3em; margin: 0 0 1em; }
li { margin-bottom: .35em; }

.skip-link {
  position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff;
  padding: .6em 1em; z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; }

.container { width: min(100% - 2.5rem, var(--max)); margin-inline: auto; }

/* ---------- Top emergency strip ---------- */
.alert-strip {
  background: var(--ink); color: #fff; font-size: .9rem; text-align: center; padding: .45rem 1rem;
}
.alert-strip a { color: var(--sun); font-weight: 700; }

/* ---------- Header / nav ---------- */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--sand-200);
  position: sticky; top: 0; z-index: 50;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .8rem 0; }
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--ink); }
.brand-mark {
  width: 40px; height: 40px; border-radius: 50%;
  background: radial-gradient(circle at 50% 60%, var(--sun) 0 38%, var(--sunset) 39% 62%, var(--clay) 63%);
  flex-shrink: 0;
}
.brand-name { font-family: var(--font-head); font-weight: 700; font-size: 1.35rem; letter-spacing: -0.01em; }
.brand-name span { color: var(--clay); }

.nav-toggle {
  display: none; background: none; border: 2px solid var(--sand-200); border-radius: 10px;
  padding: .45rem .7rem; font: inherit; font-weight: 600; color: var(--ink); cursor: pointer;
}
.site-nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: .25rem; margin: 0; padding: 0; }
.site-nav li { margin: 0; }
.site-nav a {
  display: block; padding: .5rem .75rem; border-radius: 8px; text-decoration: none;
  color: var(--ink); font-weight: 600; font-size: .95rem;
}
.site-nav a:hover { background: var(--sand-100); color: var(--clay-dark); }
.site-nav a[aria-current="page"] { background: var(--clay); color: #fff; }

@media (max-width: 960px) {
  .nav-toggle { display: inline-block; }
  .site-nav { display: none; width: 100%; }
  .site-nav.open { display: block; }
  .header-inner { flex-wrap: wrap; }
  .site-nav ul { flex-direction: column; padding-bottom: .8rem; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background:
    radial-gradient(circle at 82% 28%, rgba(255, 214, 120, .95) 0 7%, rgba(255, 170, 70, .55) 12%, transparent 30%),
    linear-gradient(170deg, #c2461a 0%, #d9622a 35%, #e88a3c 60%, #8a3212 100%);
  padding: 4.5rem 0 6.5rem;
}
.hero::after { /* desert ridge silhouette */
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 90px;
  background: var(--sand-50);
  clip-path: polygon(0 70%, 8% 52%, 16% 64%, 27% 30%, 35% 48%, 44% 40%, 55% 62%, 64% 44%, 72% 54%, 82% 26%, 90% 46%, 100% 38%, 100% 100%, 0 100%);
}
.hero h1 { color: #fff; max-width: 17ch; text-shadow: 0 2px 18px rgba(80, 20, 0, .35); }
.hero .lede { font-size: 1.2rem; max-width: 56ch; color: #fff8ee; }
.hero-badge {
  display: inline-block; background: rgba(42, 30, 23, .55); color: #fff; padding: .35rem .8rem;
  border-radius: 999px; font-size: .85rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; margin-bottom: 1rem;
}
.hero-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 2.5rem; align-items: center; position: relative; z-index: 1; }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; } }

.page-hero {
  background: linear-gradient(160deg, var(--clay) 0%, var(--sunset) 100%);
  color: #fff; padding: 3rem 0 3.2rem;
}
.page-hero h1 { color: #fff; margin-bottom: .3em; }
.page-hero p { color: #fff6ea; font-size: 1.15rem; max-width: 62ch; margin: 0; }
.page-hero.green { background: linear-gradient(160deg, var(--saguaro-dark) 0%, var(--saguaro) 100%); }
.page-hero.night { background: linear-gradient(160deg, #1b2a3a 0%, #3a3550 60%, #6b3a2a 100%); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; padding: .75rem 1.25rem; border-radius: 10px; font-weight: 700;
  text-decoration: none; border: 2px solid transparent; transition: transform .1s ease, background .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--ink); color: #fff; }
.btn-primary:hover { background: #000; color: #fff; }
.btn-light { background: #fff; color: var(--clay-dark); }
.btn-light:hover { color: var(--clay); }
.btn-outline { border-color: #fff; color: #fff; }
.btn-outline:hover { background: rgba(255,255,255,.12); color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }

/* ---------- Danger box ---------- */
.danger-box {
  background: var(--white); color: var(--ink); border-radius: var(--radius); box-shadow: 0 12px 40px rgba(60, 15, 0, .3);
  border-top: 8px solid var(--danger); padding: 1.5rem 1.6rem;
}
.danger-box h2 { color: var(--danger); font-size: 1.45rem; margin-bottom: .4em; }
.danger-box .call { font-size: 1.15rem; font-weight: 700; margin-bottom: .6em; }
.danger-box .call a { color: var(--danger); }
.danger-box ul { margin-bottom: .6em; }
.danger-box small { color: var(--ink-soft); }

/* ---------- Sections ---------- */
section { padding: 3.5rem 0; }
.section-tint { background: var(--sand-100); }
.section-dark { background: var(--ink); color: #f6ebdd; }
.section-dark h2, .section-dark h3 { color: #fff; }
.section-dark a { color: var(--sun); }
.eyebrow { color: var(--clay); font-weight: 800; text-transform: uppercase; letter-spacing: .08em; font-size: .8rem; margin-bottom: .4rem; }
.section-dark .eyebrow { color: var(--sun); }
.intro { max-width: 68ch; color: var(--ink-soft); font-size: 1.1rem; }

.grid { display: grid; gap: 1.25rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 960px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.card {
  background: var(--white); border-radius: var(--radius); padding: 1.4rem 1.5rem;
  box-shadow: var(--shadow); border: 1px solid var(--sand-200);
}
.card h3 { margin-bottom: .4em; }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
a.card { text-decoration: none; color: var(--ink); display: block; transition: transform .12s ease, box-shadow .12s ease; }
a.card:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(74, 38, 16, .16); color: var(--ink); }
.card .icon { font-size: 1.8rem; line-height: 1; margin-bottom: .6rem; display: block; }
.card .more { color: var(--clay-dark); font-weight: 700; }
.card.accent { border-top: 5px solid var(--clay); }
.card.green { border-top: 5px solid var(--saguaro); }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin: 1.5rem 0; }
@media (max-width: 860px) { .stats { grid-template-columns: repeat(2, 1fr); } }
.stat { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.15); border-radius: var(--radius); padding: 1.2rem; }
.stat .num { font-family: var(--font-head); font-size: 2.6rem; font-weight: 700; color: var(--sun); line-height: 1; display: block; margin-bottom: .4rem; }
.stat .label { font-size: .95rem; }
.stat .src { display: block; font-size: .78rem; margin-top: .5rem; opacity: .85; }
.light-stats .stat { background: var(--white); border: 1px solid var(--sand-200); box-shadow: var(--shadow); }
.light-stats .stat .num { color: var(--clay); }

/* bar chart */
.bars { display: grid; gap: .45rem; margin: 1rem 0 0; max-width: 720px; }
.bar-row { display: grid; grid-template-columns: 3.2rem 1fr 3rem; align-items: center; gap: .6rem; font-size: .9rem; }
.bar { height: 18px; border-radius: 4px; background: linear-gradient(90deg, var(--sunset), var(--clay)); }
.bar-val { font-weight: 700; }

/* ---------- Compare (exhaustion vs stroke) ---------- */
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
@media (max-width: 760px) { .compare { grid-template-columns: 1fr; } }
.compare .card.warn { border-top: 6px solid var(--sun); }
.compare .card.emergency { border-top: 6px solid var(--danger); background: #fffaf9; }
.tag { display: inline-block; padding: .2rem .6rem; border-radius: 999px; font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.tag-warn { background: #fff1d2; color: #7a4a00; }
.tag-danger { background: var(--danger-bg); color: var(--danger); }

.callout {
  border-left: 6px solid var(--clay); background: var(--white); padding: 1.1rem 1.3rem;
  border-radius: 0 var(--radius) var(--radius) 0; box-shadow: var(--shadow); margin: 1.5rem 0;
}
.callout.danger { border-left-color: var(--danger); background: #fffaf9; }
.callout.green { border-left-color: var(--saguaro); }
.callout p:last-child { margin-bottom: 0; }

/* ---------- Article layout with sidebar TOC ---------- */
.article { display: grid; grid-template-columns: 240px 1fr; gap: 2.5rem; align-items: start; padding: 3rem 0; }
.toc { position: sticky; top: 90px; background: var(--white); border: 1px solid var(--sand-200); border-radius: var(--radius); padding: 1rem 1.1rem; font-size: .92rem; }
.toc h2 { font-family: var(--font-body); font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-soft); margin-bottom: .5rem; }
.toc ol { margin: 0; padding-left: 1.1em; }
.toc a { text-decoration: none; color: var(--ink); }
.toc a:hover { color: var(--clay); text-decoration: underline; }
.article-body > section { padding: 0 0 2.5rem; scroll-margin-top: 90px; }
.article-body > section + section { border-top: 1px solid var(--sand-200); padding-top: 2.5rem; }
@media (max-width: 900px) { .article { grid-template-columns: 1fr; } .toc { position: static; } }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); font-size: .95rem; }
th, td { text-align: left; padding: .75rem .9rem; border-bottom: 1px solid var(--sand-200); vertical-align: top; }
th { background: var(--sand-100); font-weight: 700; }

/* ---------- Gear ---------- */
.gear-cat { margin-bottom: 2.5rem; }
.gear-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; }
.gear-card { display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--sand-200); border-radius: var(--radius); padding: 1.1rem 1.2rem; box-shadow: var(--shadow); }
.gear-card h3 { font-size: 1.08rem; margin-bottom: .35em; font-family: var(--font-body); font-weight: 700; }
.gear-card p { font-size: .93rem; color: var(--ink-soft); flex-grow: 1; }
.gear-card .why { font-size: .85rem; color: var(--saguaro-dark); font-weight: 600; }
.gear-card .check { display: flex; align-items: center; gap: .5rem; font-size: .9rem; margin: .4rem 0 .8rem; cursor: pointer; }
.gear-card .check input { width: 1.1rem; height: 1.1rem; accent-color: var(--saguaro); }
.btn-buy { background: var(--clay); color: #fff; text-align: center; padding: .6rem 1rem; border-radius: 9px; font-weight: 700; text-decoration: none; }
.btn-buy:hover { background: var(--clay-dark); color: #fff; }
.priority { font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--clay-dark); background: var(--sand-100); border-radius: 999px; padding: .15rem .55rem; align-self: flex-start; margin-bottom: .5rem; }
.disclosure { background: #fff7e6; border: 1px solid #f1d39a; border-radius: var(--radius); padding: 1rem 1.2rem; font-size: .95rem; }
.progress { background: var(--white); border: 1px solid var(--sand-200); border-radius: var(--radius); padding: .9rem 1.1rem; display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.progress-bar { flex: 1; min-width: 160px; height: 12px; background: var(--sand-200); border-radius: 999px; overflow: hidden; }
.progress-bar span { display: block; height: 100%; width: 0; background: var(--saguaro); transition: width .3s ease; }

/* ---------- Routes ---------- */
.route { display: grid; grid-template-columns: 90px 1fr; gap: 1.2rem; align-items: start; }
.route-badge { font-family: var(--font-body); font-weight: 800; font-size: 1.05rem; text-align: center; background: var(--saguaro); color: #fff; border-radius: 10px; padding: .7rem .4rem; line-height: 1.2; }
.route-badge.interstate { background: var(--sky); }
.route-meta { display: flex; flex-wrap: wrap; gap: .4rem; margin: .2rem 0 .6rem; }
.route-meta span { font-size: .8rem; background: var(--sand-100); border-radius: 999px; padding: .15rem .6rem; font-weight: 600; }
.map-frame { width: 100%; height: 420px; border: 0; border-radius: var(--radius); box-shadow: var(--shadow); background: var(--sand-200); }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #e9dccb; padding: 3rem 0 1.5rem; font-size: .95rem; margin-top: 2rem; }
.site-footer a { color: var(--sun); }
.site-footer h2 { color: #fff; font-size: 1.05rem; font-family: var(--font-body); text-transform: uppercase; letter-spacing: .06em; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 2rem; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-grid ul { list-style: none; padding: 0; }
.emergency-numbers li strong { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.15); margin-top: 2rem; padding-top: 1.2rem; font-size: .85rem; color: #c9b8a4; }
.footer-bottom p { margin-bottom: .6em; }

.small { font-size: .9rem; color: var(--ink-soft); }
.sources { font-size: .88rem; color: var(--ink-soft); }
.sources li { margin-bottom: .5em; }
.section-dark .sources { color: #d9c9b4; }

/* ---------- Help your neighbors CTA (on every page) ---------- */
.neighbor-cta { background: linear-gradient(135deg, var(--saguaro-dark), var(--saguaro)); color: #eef7f2; padding: 3rem 0; margin-top: 2rem; }
.neighbor-cta h2 { color: #fff; }
.neighbor-cta .eyebrow { color: #ffd58a; }
.neighbor-inner { display: grid; grid-template-columns: 1fr 1.2fr; gap: 1rem 2.5rem; align-items: start; }
.neighbor-inner > div:last-child { grid-column: 1 / -1; }
.neighbor-actions { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; }
.neighbor-actions li { background: rgba(255,255,255,.1); border-left: 4px solid var(--sun); padding: .6rem .9rem; border-radius: 0 10px 10px 0; margin: 0; }
.neighbor-actions strong { color: #fff; }
.neighbor-cta .btn-primary { background: #fff; color: var(--saguaro-dark); }
.neighbor-cta .btn-primary:hover { background: var(--sand-100); color: var(--saguaro-dark); }
.site-footer { margin-top: 0; }
@media (max-width: 860px) { .neighbor-inner { grid-template-columns: 1fr; } }

/* ---------- Situation finder ---------- */
.finder { background: var(--white); border: 1px solid var(--sand-200); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.5rem; }
.finder-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; }
@media (max-width: 1000px) { .finder-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .finder-grid { grid-template-columns: 1fr; } }
.finder fieldset { border: 1px solid var(--sand-200); border-radius: 10px; padding: .7rem .9rem; margin: 0; }
.finder legend { font-weight: 800; font-size: .9rem; padding: 0 .3rem; color: var(--clay-dark); }
.finder label { display: flex; gap: .45rem; align-items: flex-start; font-size: .93rem; margin: .3rem 0; cursor: pointer; line-height: 1.35; }
.finder input[type="radio"] { accent-color: var(--clay); margin-top: .2rem; }
.finder-actions { display: flex; gap: .75rem; flex-wrap: wrap; align-items: center; margin-top: 1rem; }
.btn-reset { background: none; border: 2px solid var(--sand-200); border-radius: 10px; padding: .55rem 1rem; font: inherit; font-weight: 700; cursor: pointer; color: var(--ink); }
.btn-reset:hover { border-color: var(--clay); }
.result-group { margin-top: 2.5rem; }
.result-group > h2 { display: flex; align-items: center; gap: .6rem; }
.advice[hidden] { display: none; }
.advice .who { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--saguaro-dark); background: #e3f0ea; border-radius: 999px; padding: .15rem .6rem; display: inline-block; margin-bottom: .5rem; }
.finder-status { font-weight: 600; color: var(--ink-soft); }
.result-group .grid { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
/* darker left side of hero for text contrast */
.hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(90, 25, 5, .55) 0%, rgba(90, 25, 5, .25) 55%, transparent 80%); }
@media (max-width: 860px) {
  .hero { background: linear-gradient(170deg, #b8461b 0%, #c9561f 50%, #8a3212 100%); padding-top: 3rem; }
  .hero::before { background: rgba(90, 25, 5, .25); }
}

/* ---------- Grow calculator ---------- */
.calc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
@media (max-width: 900px) { .calc-grid { grid-template-columns: 1fr; } }
.finder label.field { display: flex; flex-direction: column; gap: .25rem; font-weight: 600; font-size: .88rem; margin: .5rem 0; }
.finder input[type="number"], .finder select { font: inherit; font-weight: 400; padding: .45rem .6rem; border: 1px solid var(--sand-200); border-radius: 8px; background: var(--sand-50); color: var(--ink); width: 100%; }
.finder input[type="number"]:focus, .finder select:focus { border-color: var(--clay); }
.calc-results { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin: 1.25rem 0 .75rem; }
@media (max-width: 860px) { .calc-results { grid-template-columns: repeat(2, 1fr); } }
.calc-results .stat { background: var(--white); border: 1px solid var(--sand-200); box-shadow: var(--shadow); }
.calc-results .stat .num { color: var(--saguaro); font-size: 2rem; }
.stats.compact .stat .num { font-size: 1.85rem; white-space: nowrap; }

/* ---------- Home Upgrades ---------- */
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); border:0; }
.up-controls { display:flex; flex-wrap:wrap; gap:1rem 1.5rem; align-items:flex-end; background:#fff; border:1px solid var(--line, #ead9c6); border-radius:14px; padding:1rem 1.25rem; margin-top:1.5rem; }
.up-controls .field { display:flex; flex-direction:column; gap:.3rem; }
.up-controls label, .up-controls legend { font-weight:700; font-size:.9rem; }
.up-controls select { font:inherit; padding:.5rem .6rem; border-radius:8px; border:1px solid #cdb8a2; background:#fffaf4; min-width:14rem; }
.up-controls fieldset { border:0; padding:0; margin:0; }
.up-controls .checks label { font-weight:500; margin-right:1rem; display:inline-flex; gap:.35rem; align-items:center; }
.btn-ghost { background:transparent; border:2px solid #b8461b; color:#b8461b; padding:.45rem 1rem; border-radius:999px; font-weight:700; cursor:pointer; }
.up-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(320px, 1fr)); gap:1.25rem; }
.up-card { background:#fff; border:1px solid #ead9c6; border-radius:14px; padding:1.2rem 1.25rem; display:flex; flex-direction:column; gap:.55rem; box-shadow:0 2px 6px rgba(80,40,10,.05); }
.up-card[hidden] { display:none; }
.up-card header { display:flex; justify-content:space-between; gap:.75rem; align-items:flex-start; }
.up-card h3 { margin:0; font-size:1.12rem; }
.up-card p { margin:0; }
.up-card .tier { font-weight:800; color:#1f6f50; background:#e3f3ea; border-radius:999px; padding:.1rem .6rem; white-space:nowrap; }
.up-meta { margin:0; display:grid; gap:.3rem; }
.up-meta div { display:flex; gap:.5rem; }
.up-meta dt { font-weight:700; min-width:6.8rem; }
.up-meta dd { margin:0; }
.stars { color:#d9822b; letter-spacing:.05em; font-size:1.05rem; }
.up-card .why { color:#5a4636; }
.tags { list-style:none; padding:0; margin:0; display:flex; flex-wrap:wrap; gap:.35rem; }
.tag { font-size:.78rem; font-weight:700; border-radius:999px; padding:.15rem .6rem; background:#f4ebe0; color:#5a3a20; }
.tag.conv3 { background:#e6eef9; color:#22446e; } .tag.conv2 { background:#efe7f7; color:#4c2c6e; } .tag.conv1 { background:#fde8d8; color:#8a3212; }
.tag.rent-ok { background:#e3f3ea; color:#1f6f50; } .tag.rent-maybe { background:#fff4d6; color:#7a5600; }
.tag.outage { background:#2b2118; color:#ffe3b8; }
.rebate { font-size:.9rem; background:#f2f8f4; border-left:4px solid #1f6f50; padding:.45rem .6rem; border-radius:6px; }
.rebate.none { background:#f7f2ec; border-left-color:#cdb8a2; color:#6b5847; }
.up-card .sources { margin-top:auto; color:#6b5847; }

/* ---------- Bug-out bag ---------- */
.hero-split { display:grid; grid-template-columns: 1.4fr 1fr; gap:2rem; align-items:center; }
.hero-split img { width:100%; height:auto; border-radius:16px; box-shadow:var(--shadow); }
@media (max-width: 860px) { .hero-split { grid-template-columns:1fr; } }
.btn-light { background:#fff; color:var(--clay-dark); border:0; cursor:pointer; font:inherit; font-weight:700; }
.kit-grid { display:grid; gap:1.25rem; margin-top:1.25rem; }
.kit-card { display:grid; grid-template-columns: 200px 1fr; gap:1.25rem; background:#fff; border:1px solid #ead9c6; border-radius:14px; padding:1.1rem; box-shadow:0 2px 6px rgba(80,40,10,.05); }
.kit-card img { width:200px; height:auto; border-radius:10px; }
.kit-card h3 { margin:.1rem 0 .3rem; }
.kit-card .eyebrow { margin:0; }
.kit-price strong { font-size:1.35rem; color:var(--clay-dark); }
.kit-pc { display:grid; grid-template-columns:1fr 1fr; gap:1rem; margin:.5rem 0 .8rem; }
.kit-pc h4 { margin:0 0 .25rem; font-size:.95rem; }
.kit-pc ul { margin:0; padding-left:1.1rem; font-size:.93rem; }
@media (max-width: 700px) { .kit-card { grid-template-columns:1fr; } .kit-pc { grid-template-columns:1fr; } }
.bob-list { columns: 2 340px; column-gap: 1.5rem; }
.bob-cat { break-inside: avoid; border:1px solid #ead9c6; border-radius:12px; background:#fff; padding:.8rem 1rem; margin:0 0 1rem; }
.bob-cat legend { font-weight:800; font-family:var(--font-head); font-size:1.1rem; padding:0 .3rem; color:var(--clay-dark); }
.bob-cat ul { list-style:none; margin:0; padding:0; }
.bob-cat li { padding:.35rem 0; border-bottom:1px dashed #efdcc0; }
.bob-cat li:last-child { border-bottom:0; }
.bob-cat label { display:flex; gap:.55rem; align-items:flex-start; cursor:pointer; }
.bob-cat input { margin-top:.25rem; width:1.05rem; height:1.05rem; flex:none; }
.bob-cat .why { display:block; font-size:.88rem; color:var(--ink-soft); }
.print-only { display:none; }
@media print {
  .alert-strip, .site-header, .site-footer, .neighbor-cta, .no-print, .skip-link { display:none !important; }
  main:has(> section.bob-print) > .page-hero, main:has(> section.bob-print) > section:not(.bob-print) { display:none !important; }
  body { background:#fff; color:#000; font-size:10.5pt; }
  .print-only { display:block; margin-bottom:.4rem; }
  .bob-print { padding:0 !important; }
  .bob-list { columns:2; }
  .bob-cat { border:1px solid #999; padding:.4rem .6rem; margin-bottom:.5rem; }
  .bob-cat li { padding:.15rem 0; }
  .bob-cat input { -webkit-appearance:none; appearance:none; border:1.5px solid #000; width:.85rem; height:.85rem; }
  a { color:#000; text-decoration:none; }
}

/* ---------- Wheels block + data tables ---------- */
.wheels { margin-top:2rem; background:var(--sand-50); border:2px solid var(--sand-200); border-radius:18px; padding:1.5rem; }
.wheels[hidden] { display:none; }
.wheels h4 { margin:.2rem 0 .4rem; }
.data-table { width:100%; border-collapse:collapse; background:#fff; margin:.5rem 0 1rem; font-size:.95rem; }
.data-table caption { text-align:left; font-weight:700; padding:.4rem 0; }
.data-table th, .data-table td { border:1px solid #ead9c6; padding:.5rem .7rem; text-align:left; vertical-align:top; }
.data-table thead th { background:var(--sand-100); }
.data-table tbody th { font-weight:600; }

/* ---------- Resource map ---------- */
.map-wrap { display:grid; grid-template-columns: 1fr 340px; gap:1rem; margin-top:1rem; }
.resource-map { height: 72vh; min-height: 460px; border-radius: 14px; border:1px solid #ead9c6; z-index:0; }
.map-panel { background:#fff; border:1px solid #ead9c6; border-radius:14px; padding:1rem; max-height:72vh; overflow:auto; }
.map-tools { display:flex; flex-wrap:wrap; gap:.4rem; margin-bottom:.6rem; }
.map-tools .btn { padding:.3rem .7rem; font-size:.85rem; }
.layer-panel fieldset { border:0; border-top:1px solid #efdcc0; padding:.5rem 0 .3rem; margin:0; }
.layer-panel legend { font-weight:800; font-size:.9rem; color:var(--clay-dark); padding:0; }
.layer-panel label { display:flex; gap:.4rem; align-items:flex-start; font-size:.9rem; padding:.18rem 0; cursor:pointer; }
.layer-panel input { margin-top:.2rem; }
.h-small { font-size:1.05rem; margin:.2rem 0; }
.swatch { flex:none; width:.85rem; height:.85rem; border-radius:50%; background:var(--c); border:2px solid #fff; box-shadow:0 0 0 1px #999; margin-top:.2rem; }
.swatch.line { border-radius:2px; height:.3rem; margin-top:.5rem; box-shadow:none; border:0; }
.cnt { color:#6b5847; font-size:.8rem; }
.pop strong { font-size:1rem; } .pop-type { color:#6b5847; font-size:.85rem; }
.pop p { margin:.35rem 0; } .pop-caveat { color:#8a3212; } .pop-src { font-size:.8rem; color:#6b5847; } .pop-verify { font-size:.8rem; font-weight:700; }
.state-list { columns: 3 220px; padding-left:1.1rem; margin-top:.8rem; }
.state-list li { break-inside:avoid; margin-bottom:.3rem; font-size:.92rem; }
.state-list li[hidden] { display:none; }
#state-filter { font:inherit; padding:.45rem .6rem; border:1px solid #cdb8a2; border-radius:8px; width:min(320px,100%); display:block; margin:.25rem 0; }
.state-details summary { cursor:pointer; font-weight:700; }
@media (max-width: 900px) { .map-wrap { grid-template-columns:1fr; } .resource-map { height:60vh; } .map-panel { max-height:none; } }

/* ---------- Nav "More guides" dropdown ---------- */
.nav-more details { position: relative; }
.nav-more summary { list-style: none; cursor: pointer; padding: .45rem .7rem; border-radius: 8px; font-weight: 600; font-size: .95rem; color: var(--ink); }
.nav-more summary::-webkit-details-marker { display: none; }
.nav-more summary::after { content: " ▾"; font-size: .8em; }
.nav-more details.cur summary { color: var(--clay-dark); }
.nav-more details[open] > ul { position: absolute; right: 0; top: 100%; z-index: 50; display: block; min-width: 220px; background: #fff; border: 1px solid var(--sand-200); border-radius: 12px; box-shadow: 0 10px 30px rgba(42,30,23,.15); padding: .4rem; }
.nav-more details[open] > ul li a { display: block; }
@media (max-width: 900px) { .nav-more details[open] > ul { position: static; box-shadow: none; border: 0; padding: 0 0 0 .8rem; } }

/* ---------- Doodles & notebook ---------- */
.doodle { width: 54px; height: 54px; color: var(--clay); opacity: .55; pointer-events: none; }
.doodle-r { float: right; margin: 0 0 .5rem 1rem; transform: rotate(8deg); }
.doodle-l { display: block; margin: 1rem 0 0 auto; transform: rotate(-6deg); }
.inline-doodle { width: 1.4em; height: 1.4em; vertical-align: -.3em; }
.hand, .hand-note { font-family: "Patrick Hand", "Comic Sans MS", cursive; font-size: 1.2rem; }
.hand-note { background: #fff9db; border-left: 4px solid #f08c00; padding: .7rem 1rem; border-radius: 4px 12px 12px 4px; transform: rotate(-.3deg); }
.notebook { background: #fff; border: 1px solid var(--sand-200); border-radius: 14px; padding: 1.5rem 1.6rem;
  background-image: repeating-linear-gradient(to bottom, transparent 0 31px, #e7eef7 31px 32px); background-position: 0 12px; }
.notebook h2 { font-family: "Patrick Hand", var(--font-head); font-size: 2rem; color: var(--clay-dark); margin-top: 1.6rem; scroll-margin-top: 90px; }
.notebook h2:first-of-type { margin-top: 0; }
.diagram { margin: 1rem 0; background: #fffdf7; border: 1.5px dashed #d9c3a5; border-radius: 12px; padding: .6rem; }
.diagram svg { width: 100%; height: auto; display: block; }
.diagram figcaption { font-size: .9rem; color: var(--ink-soft); margin-top: .3rem; }
.knots { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: .8rem; }
.notebook-hero { background-image: linear-gradient(135deg, #7a2e10, #b8461b 60%, #c9682e); }

/* ---------- Generators ---------- */
.watt-calc input[type=checkbox] { width: 1.1rem; height: 1.1rem; }
.calc-out { background: var(--sand-100); border-radius: 10px; padding: .7rem 1rem; font-size: 1.05rem; }
.gen-picks .card { display: flex; flex-direction: column; }
.gen-picks .btn-buy { margin-top: auto; align-self: flex-start; }
.pick-art { width: 100%; max-height: 120px; margin-bottom: .4rem; }
.spec { padding-left: 1.1rem; font-size: .92rem; }
.tier { font-family: "Patrick Hand", cursive; font-size: 1.25rem; margin: 0 0 .3rem; padding: .1rem .7rem; border-radius: 999px; display: inline-block; align-self: flex-start; border: 2px solid currentColor; }
.tier-budget { color: #2b8a3e; } .tier-mid { color: #1864ab; } .tier-premium { color: #862e9c; }
.trouble td:first-child { font-weight: 700; }
.layer-note { background: #f3f0ff; border-radius: 8px; padding: .4rem .55rem; margin: .2rem 0 .4rem; }

/* ---------- Field guide builder ---------- */
.fg-builder { margin-top: 1.5rem; background: #fff; border: 2px dashed #e0a96d; border-radius: 18px; padding: 1.3rem 1.5rem;
  background-image: repeating-linear-gradient(to bottom, transparent 0 31px, #f1e6d6 31px 32px); }
.fg-builder fieldset { border: 0; padding: 0; margin: .4rem 0 .8rem; display: flex; flex-wrap: wrap; gap: .3rem 1rem; }
.fg-builder legend { font-weight: 800; margin-bottom: .3rem; }
.fg-builder h2 { font-family: "Patrick Hand", var(--font-head); font-size: 2rem; }
.offline-banner { position: fixed; left: 50%; bottom: 1rem; transform: translateX(-50%); z-index: 1000; background: var(--ink); color: #fff; padding: .7rem 1rem; border-radius: 12px; max-width: min(92vw, 560px); box-shadow: 0 8px 30px rgba(0,0,0,.3); }
.offline-banner .btn-x { background: none; border: 0; color: #fff; font-size: 1.3rem; cursor: pointer; margin-left: .5rem; }

/* ---------- Field guides (screen + print) ---------- */
.fg-toolbar { background: var(--sand-100); padding: 1.2rem 0; border-bottom: 1px solid var(--sand-200); }
.fieldguide { max-width: 860px; margin: 1.5rem auto; padding: 2rem 2.2rem; background: #fff; box-shadow: 0 4px 24px rgba(42,30,23,.1);
  background-image: linear-gradient(to right, transparent 54px, #f4c7c3 54px 56px, transparent 56px), repeating-linear-gradient(to bottom, transparent 0 27px, #dfe9f5 27px 28px); }
.fieldguide [hidden] { display: none !important; }
.fg-cover { position: relative; min-height: 70vh; padding: 3rem 1rem 2rem 2.5rem; }
.fg-title { font-family: "Patrick Hand", var(--font-head); font-size: 4rem; margin: 0; color: var(--clay-dark); }
.fg-kicker { color: var(--ink-soft); margin: 0; }
.fg-under { width: 300px; height: 30px; opacity: .8; display: block; }
.fg-cover .doodle { position: absolute; width: 80px; height: 80px; opacity: .5; }
.fg-c1 { top: 0; right: 10px; } .fg-c2 { bottom: 40px; right: 30px; transform: rotate(6deg); } .fg-c3 { bottom: 0; left: 30%; width: 140px !important; }
.fg-c4 { top: 40%; right: 0; } .fg-c5 { top: 8px; left: 45%; } .fg-c6 { bottom: 30%; left: 0; }
.fg-toc ol { columns: 2; }
.fill-line { border-bottom: 1.5px solid #888; padding: .9rem 0 .15rem; margin: 0 0 .3rem; }
.fill-table { width: 100%; border-collapse: collapse; margin-bottom: 1rem; }
.fill-table th, .fill-table td { border: 1px solid #999; padding: .55rem .4rem; text-align: left; height: 1.9rem; }
.fg-chapter, .cg-chapter { padding-left: 1.2rem; }
.fg-chap-head { position: relative; border-bottom: 2px dashed #c9a37c; margin: 2rem 0 1rem; padding-bottom: .3rem; }
.fg-chap-head h2 { font-family: "Patrick Hand", var(--font-head); font-size: 2.2rem; margin: 0; color: var(--clay-dark); }
.fg-chap-head .hand { margin: 0; color: var(--ink-soft); }
.fg-num { position: absolute; left: -2.6rem; top: 0; font-family: "Patrick Hand", cursive; font-size: 1.6rem; width: 2rem; height: 2rem; line-height: 2rem; text-align: center; border: 2px solid var(--clay); border-radius: 50%; color: var(--clay); margin: 0; }
.fg-chap-doodle { position: absolute; right: 0; top: -10px; }
.fieldguide .page-hero { background: none !important; color: var(--ink) !important; padding: 0 0 .5rem !important; }
.fieldguide .page-hero h1 { font-family: "Patrick Hand", var(--font-head); color: var(--clay-dark) !important; font-size: 2.6rem; }
.fieldguide .page-hero p, .fieldguide .page-hero .eyebrow { color: var(--ink-soft) !important; }
.fieldguide section { padding: .6rem 0 !important; }
.fieldguide .container { width: auto; max-width: none; padding: 0; }
.fieldguide .grid-3, .fieldguide .grid-2 { grid-template-columns: 1fr 1fr; }
.fieldguide .article { display: block; padding: 0; }
.fieldguide .card, .fieldguide .callout { box-shadow: none; }
.fieldguide .btn, .fieldguide .btn-buy, .fieldguide .finder, .fieldguide .finder-actions, .fieldguide .no-print, .fieldguide .map-wrap, .fieldguide .controls, .fieldguide form.upg-controls { display: none !important; }
.fieldguide .bob-cat input { width: 1rem; height: 1rem; }
.fg-numbers li { margin-bottom: .35rem; }
.fg-end { text-align: center; margin-top: 2rem; }
.print-map img { width: 100%; border: 1px solid #999; }

@media print {
  @page { size: letter; margin: 0.55in 0.5in; }
  body:has(.fieldguide) { background: #fff; }
  body:has(.fieldguide) .fg-toolbar, body:has(.fieldguide) .offline-banner { display: none !important; }
  .fieldguide { box-shadow: none; margin: 0; max-width: none; padding: 0 0 0 .2in; font-size: 10.5pt;
    background-image: linear-gradient(to right, transparent 0.12in, #e8b4b0 0.12in 0.13in, transparent 0.13in);
    -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .fg-cover { min-height: 9in; page-break-after: always; break-after: page; }
  .fg-chapter, .cg-chapter { break-before: page; page-break-before: always; }
  .fg-chapter:first-of-type { break-before: auto; }
  .fieldguide .card, .fieldguide .callout, .fieldguide figure, .fieldguide tr, .fieldguide .bob-cat { break-inside: avoid; }
  .fieldguide h2, .fieldguide h3 { break-after: avoid; }
  .fieldguide a { color: #000; text-decoration: none; }
  .fieldguide .card { border: 1px solid #999 !important; }
  .fieldguide .callout.danger { border: 2px solid #000 !important; }
  .fieldguide .doodle { opacity: .45; color: #555; }
  .fieldguide .stats, .fieldguide .grid-3, .fieldguide .grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; }
  .fieldguide .bob-list { columns: 2; }
  .fieldguide .upg-card { break-inside: avoid; }
}

/* ---------- Radio ---------- */
.phonetic { font-family: "Patrick Hand", cursive; font-size: 1.2rem; line-height: 1.6; }
.rc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.radio-card h2 { font-family: "Patrick Hand", var(--font-head); color: var(--clay-dark); font-size: 1.6rem; margin: .8rem 0 .3rem; }
.radio-card .data-table { font-size: .85rem; }
.radio-card .hand-note { font-size: 1.05rem; }
@media print { .rc-page + .rc-page { break-before: page; } .radio-card { font-size: 10pt; } }
@media print {
  .radio-card .data-table th, .radio-card .data-table td { padding: .15rem .35rem; font-size: 8pt; line-height: 1.25; }
  .radio-card .data-table caption { font-size: 8pt; }
  .radio-card ul.small li { margin-bottom: .1rem; }
  .radio-card .hand-note { padding: .4rem .7rem; font-size: 10pt; }
  .radio-card .hand-note ol { margin: .2rem 0; }
  .radio-card h2 { font-size: 1.3rem; margin: .5rem 0 .2rem; }
  .radio-card .fg-title { font-size: 2rem !important; }
}

/* ---------- Radio pocket card (4.25 x 5.5 in panels) ---------- */
.pocket { font-family: "Patrick Hand", var(--font-body); color: #2b2b2b; }
.pocket .pk-page { width: 4.25in; min-height: 5.5in; box-sizing: border-box; padding: .3in .3in .25in; margin: 1rem auto; border: 2px dashed #c9b8a6; border-radius: 8px;
  background: #fffdf6 repeating-linear-gradient(transparent 0 23px, #dde7f2 23px 24px); font-size: 15.5px; line-height: 1.4; }
.pocket h1 { font-family: "Patrick Hand", cursive; color: var(--clay-dark); font-size: 30px; margin: 0 0 .1in; }
.pocket h2 { font-family: "Patrick Hand", cursive; color: var(--clay-dark); font-size: 23px; margin: 0 0 .1in; display: flex; align-items: center; gap: 6px; }
.pocket .pk-doodle { width: 20px; height: 20px; }
.pocket .pk-kicker { margin: 0; font-size: 13px; color: #6b5b4b; }
.pocket ul { padding-left: 1.1em; margin: 0; } .pocket li { margin-bottom: 7px; }
.pocket .pk-table { width: 100%; border-collapse: collapse; margin: .08in 0; font-size: 14px; }
.pocket .pk-table th, .pocket .pk-table td { border: 1.5px solid #6b5b4b; padding: 2px 5px; text-align: left; }
.pocket .pk-fill td { height: 24px; }
.pocket .pk-tip { background: #fff4c2; padding: 4px 6px; border-radius: 4px; }
.pocket .pk-fine { font-size: 11px; color: #555; }
.pocket .hand-note { font-size: 15px; padding: 6px 8px; margin: 0; } .pocket .hand-note ol { padding-left: 1.2em; margin: .05in 0; }
.pocket .phonetic { font-size: 15.5px; line-height: 1.5; }
@media print {
  .pocket .pk-page { margin: 0; border: 0; border-radius: 0; height: 5.5in; overflow: hidden; break-after: page; }
  .pocket .pk-page:last-child { break-after: auto; }
}

/* ---------- Wildlife field guide ---------- */
.wildlife .golden { margin-top: 1.5rem; }
.wildlife .golden h2 { font-family: "Patrick Hand", var(--font-head); margin-top: 0; }
.wildlife .golden ol li { margin-bottom: .4rem; }
.kid-criteria { background: #fff8d6; border-left-color: #e0a800; }
.badge { display: inline-block; font-family: "Patrick Hand", cursive; font-size: .95rem; line-height: 1.2; padding: .1rem .55rem; border-radius: 999px; border: 1.5px solid currentColor; margin: 0 .15rem .2rem 0; }
.b-danger { color: #a61e1e; background: #fdeaea; } .b-edible { color: #2b6b2f; background: #e8f5e6; }
.b-kid { color: #7a5600; background: #ffe98a; } .b-region { color: #5b4a3a; background: #f4ede3; font-size: .85rem; }
.sp-filter { display: grid; gap: .6rem 1.2rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); background: #fffdf6; border: 2px dashed #c9b8a6; border-radius: 12px; padding: 1rem; margin: 1.5rem 0; }
.sp-filter fieldset { border: 0; padding: 0; margin: 0; } .sp-filter legend { font-weight: 700; font-size: .9rem; }
.sp-filter label { display: inline-flex; gap: .3rem; align-items: center; margin-right: .7rem; font-size: .95rem; }
.sp-filter .sp-search { display: flex; flex-direction: column; align-items: stretch; } .sp-filter .sp-search span { font-weight: 700; font-size: .9rem; }
.sp-filter input[type=search] { padding: .5rem .7rem; border: 2px solid #c9b8a6; border-radius: 8px; font: inherit; }
.sp-filter #sp-count { grid-column: 1 / -1; margin: 0; }
@media (max-width: 700px) { .sp-filter { position: static; } }
.sp-group-title { font-family: "Patrick Hand", var(--font-head); font-size: 1.6rem; color: var(--clay-dark); margin: 1.6rem 0 .6rem; }
.sp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1.1rem; }
.sp-card { background: #fffdf6; border: 2px solid #3a2a1a; border-radius: 14px 18px 12px 16px; box-shadow: 3px 3px 0 #3a2a1a22; padding: 1rem 1rem .8rem; display: flex; flex-direction: column; }
.sp-card[hidden] { display: none; }
.sp-card h4 { font-family: "Patrick Hand", var(--font-head); font-size: 1.45rem; margin: 0; line-height: 1.15; }
.sp-card .sp-sci { margin: .1rem 0 .3rem; font-size: .9rem; color: #6b5b4b; }
.sp-card .sp-badges { margin: 0 0 .5rem; }
.sp-gallery { display: grid; grid-auto-flow: column; grid-auto-columns: 82%; gap: .5rem; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: .3rem; margin-bottom: .5rem; }
.sp-gallery:has(> .sp-fig:only-child) { grid-auto-columns: 100%; }
.sp-fig { margin: 0; scroll-snap-align: start; }
.sp-fig img { width: 100%; height: 190px; object-fit: cover; border-radius: 10px; border: 1.5px solid #3a2a1a55; background: #eee; display: block; }
.sp-fig figcaption { font-size: .82rem; line-height: 1.3; margin-top: .2rem; }
.sp-credit { display: block; color: #6b5b4b; font-size: .72rem; }
.sp-dl { margin: 0; } .sp-row { margin: 0 0 .45rem; } .sp-row dt { font-weight: 700; font-size: .85rem; text-transform: uppercase; letter-spacing: .03em; color: #6b5b4b; }
.sp-row dd { margin: 0; font-size: .95rem; }
.sp-row.sp-danger dd { color: #8a1c1c; } .sp-row.sp-aid { background: #fdeaea; border-radius: 8px; padding: .35rem .5rem; } .sp-row.sp-prep { background: #eef6ea; border-radius: 8px; padding: .35rem .5rem; }
.sp-src { margin-top: auto; color: #6b5b4b; } .sp-src a { color: inherit; }
.protected-list li { margin-bottom: .3rem; }
.wl-regions svg { width: 100%; height: auto; max-width: 760px; }
.credits-table td { vertical-align: top; font-size: .85rem; }
@media print {
  .sp-grid { display: block; }
  .sp-card { break-inside: avoid; box-shadow: none; border-width: 1.5px; margin: 0 0 .25in; padding: .12in .16in; }
  .sp-gallery { display: grid; grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); overflow: visible; }
  .sp-gallery:has(> .sp-fig:only-child) { grid-template-columns: 2.3in; }
  .sp-fig img { height: 1.45in; }
  .sp-row dd, .sp-card { font-size: 9.5pt; }
  .sp-filter { display: none !important; }
  .credits-table img { width: 50px !important; }
}
@media print {
  .wildlife .sp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .14in; }
  .wildlife .sp-card { margin: 0; padding: .08in .12in; border-radius: 8px; }
  .wildlife .sp-card h4 { font-size: 13pt; }
  .wildlife .sp-gallery { grid-template-columns: repeat(3, 1fr); gap: .05in; margin-bottom: .04in; }
  .wildlife .sp-gallery:has(> .sp-fig:only-child) { grid-template-columns: 1.4in; }
  .wildlife .sp-fig img { height: .9in; border-radius: 5px; }
  .wildlife .sp-fig figcaption { font-size: 6.5pt; line-height: 1.15; }
  .wildlife .sp-credit { font-size: 5.5pt; }
  .wildlife .sp-row { margin-bottom: .03in; } .wildlife .sp-row dt { font-size: 6.5pt; }
  .wildlife .sp-row dd, .wildlife .sp-card { font-size: 7.6pt; line-height: 1.3; }
  .wildlife .sp-src { font-size: 6.5pt; }
  .wildlife .badge { font-size: 7pt; padding: 0 .3rem; }
}
@media print {
  .wildlife .sp-grid { display: block; column-count: 2; column-gap: .16in; }
  .wildlife .sp-card { display: block; break-inside: avoid; margin: 0 0 .14in; }
}
@media print {
  .wildlife .sp-card { break-inside: auto; }
  .wildlife .sp-card header, .wildlife .sp-gallery { break-inside: avoid; break-after: avoid; }
  .wildlife .sp-row { break-inside: avoid; }
}

/* ---- Articles & cover-up article ---- */
.article-wrap { max-width: 980px; padding-top: 1rem; padding-bottom: 2rem; }
.cover-article h2 { margin-top: 2rem; }
.callout.answer { border-left-color: var(--saguaro); background: #f7fbf2; }
sup.cite { font-size: .7em; line-height: 0; }
sup.cite a { text-decoration: none; }
.table-wrap { overflow-x: auto; }
.refs li { margin-bottom: .25rem; word-break: break-word; }
.wrap-steps { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.wrap-step { display: grid; grid-template-columns: 180px 1fr; gap: .8rem; align-items: start; background: #fffdf7; border: 1.5px dashed #d9c3a5; border-radius: 12px; padding: .7rem; break-inside: avoid; }
.wrap-fig { margin: 0; }
.wrap-fig svg { width: 100%; height: auto; display: block; }
.wrap-step h4 { margin: .2rem 0 .3rem; font-family: "Patrick Hand", cursive; font-size: 1.3rem; }
.wrap-step p { margin: 0; font-size: .95rem; }
.step-n { display: inline-grid; place-items: center; width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--clay, #b8461b); color: #fff; font-size: 1rem; margin-right: .2rem; }
.headwrap-fig, .foot-fig { max-width: 640px; }
.article-card .doodle { width: 48px; height: 48px; }
@media (max-width: 760px) { .wrap-steps { grid-template-columns: 1fr; } .wrap-step { grid-template-columns: 120px 1fr; } }
@media print {
  .wrap-steps { grid-template-columns: 1fr 1fr; gap: .5rem; }
  .wrap-step { grid-template-columns: 150px 1fr; padding: .4rem; }
  .wrap-step p { font-size: 9.5pt; }
  .wrap-step h4 { font-size: 13pt; }
}

/* ---- Contact & Report ---- */
.contact-form { max-width: 760px; background: #fffdf7; border: 1.5px dashed #d9c3a5; border-radius: 12px; padding: 1rem 1.2rem; margin: 1rem 0 2rem; }
.contact-form label { display: block; font-weight: 600; margin: .6rem 0; }
.contact-form input[type=text], .contact-form input[type=email], .contact-form select, .contact-form textarea { display: block; width: 100%; margin-top: .25rem; padding: .55rem .6rem; border: 1.5px solid #d9c3a5; border-radius: 8px; font: inherit; background: #fff; }
.contact-form .consent { font-weight: 400; display: flex; gap: .5rem; align-items: flex-start; }
.contact-form .consent input { margin-top: .3rem; }
.contact-form .hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-status { min-height: 1.4em; font-weight: 600; }
.contact-status.ok { color: #2f6b2f; } .contact-status.err { color: var(--danger); }
.report-row { text-align: right; margin: 1.2rem auto .4rem; }
.report-link { font-size: .9rem; color: var(--ink-soft); }
@media print { .report-row { display: none; } }

/* ---- Site search ---- */
.site-search { display: flex; align-items: center; margin-left: auto; margin-right: .5rem; }
.site-search input { width: 11rem; padding: .4rem .6rem; border: 1.5px solid #d9c3a5; border-right: 0; border-radius: 8px 0 0 8px; font: inherit; font-size: .9rem; background: #fff; }
.site-search input:focus { outline: 2px solid var(--clay, #b8461b); outline-offset: 1px; width: 14rem; }
.site-search button { padding: .4rem .55rem; border: 1.5px solid #d9c3a5; border-radius: 0 8px 8px 0; background: var(--sand-100, #f6efe2); color: inherit; cursor: pointer; line-height: 0; }
@media (max-width: 960px) { .site-search { order: 3; flex: 1 1 100%; margin: .2rem 0 0; } .site-search input, .site-search input:focus { width: 100%; } }
.search-wrap { max-width: 860px; padding: 1rem 0 2rem; }
.search-page-form { display: flex; gap: .5rem; }
.search-page-form input { flex: 1; font: inherit; font-size: 1.1rem; padding: .65rem .8rem; border: 1.5px solid #d9c3a5; border-radius: 10px; min-width: 0; }
.search-filters { display: flex; flex-wrap: wrap; gap: .4rem 1rem; margin: .7rem 0; font-size: .95rem; }
.search-count { color: var(--ink-soft); min-height: 1.3em; }
.search-results { list-style: none; padding: 0; margin: 0; }
.search-result a { display: block; padding: .75rem .9rem; margin: .5rem 0; background: #fffdf7; border: 1.5px dashed #d9c3a5; border-radius: 12px; text-decoration: none; color: inherit; }
.search-result a:hover, .search-result a:focus { border-color: var(--clay, #b8461b); border-style: solid; outline: none; box-shadow: 0 0 0 3px rgba(184,70,27,.18); }
.sr-kind { display: block; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-soft); }
.sr-title { display: block; font-size: 1.1rem; color: var(--clay, #b8461b); margin: .1rem 0 .2rem; }
.sr-snip { display: block; font-size: .93rem; line-height: 1.45; }
.search-result mark { background: #ffe08a; padding: 0 .1em; border-radius: 3px; }
@media print { .site-search { display: none; } }
@media (max-width: 480px) { .brand-name { font-size: 1.15rem; } .header-inner { gap: .5rem; } .brand-mark { width: 30px; height: 30px; } }
.notebook-hero a, .page-hero a:not(.btn) { color: #fff3dc; }
.brand-name { white-space: nowrap; }
@media (min-width: 961px) and (max-width: 1360px) { .site-search input { width: 7.5rem; } .site-search input:focus { width: 11rem; } .site-search { margin-right: 0; } }
@media (min-width: 961px) and (max-width: 1360px) {
  .header-inner { flex-wrap: wrap; row-gap: .3rem; }
  .site-search { order: 3; flex: 0 0 100%; justify-content: flex-end; margin: 0; }
  .site-search input, .site-search input:focus { width: 16rem; }
}
.headwrap-fig { max-width: 380px; }
@media (max-width: 560px) {
  .wrap-step { grid-template-columns: 1fr; }
  .wrap-fig { max-width: 250px; width: 100%; margin: 0 auto; }
  .headwrap-fig, .foot-fig { max-width: 100%; }
}

/* ---- Language toggle + banner ---- */
.lang-toggle { font-size: .9rem; white-space: nowrap; display: flex; align-items: center; }
.lang-toggle a { text-decoration: none; color: var(--ink-soft); padding: .2rem .25rem; border-radius: 6px; }
.lang-toggle a[aria-current="true"] { font-weight: 700; color: var(--clay, #b8461b); text-decoration: underline; text-underline-offset: 3px; }
.lang-toggle a:focus-visible { outline: 2px solid var(--clay, #b8461b); }
.lang-banner { background: #fff4d6; border-bottom: 2px solid #f4b33f; padding: .6rem 1rem; text-align: center; }
.lang-banner p { margin: 0; display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; justify-content: center; }
@media (max-width: 960px) { .lang-toggle { order: 2; margin-left: auto; } }
@media print { .lang-toggle, .lang-banner { display: none; } }

/* ---- AC broken? (home box + page) ---- */
.ac-home { padding-top: 0; padding-bottom: 1.5rem; }
.ac-home-box { background: #fff7ed; border: 3px solid var(--danger); border-radius: 14px; padding: 1.25rem 1.4rem; box-shadow: 0 6px 18px rgba(0,0,0,.08); }
.ac-home-kicker { text-transform: uppercase; letter-spacing: .08em; font-weight: 800; font-size: .8rem; color: var(--danger); margin: 0 0 .2em; }
.ac-home-box h2 { color: var(--danger); margin: 0 0 .3em; font-size: clamp(1.5rem, 4.5vw, 2rem); }
.ac-home-why { font-size: .95rem; color: var(--ink-soft); margin-bottom: .7em; }
.ac-steps { counter-reset: acs; list-style: none; padding: 0; margin: 0 0 1em; display: grid; gap: .55rem; }
.ac-steps li { counter-increment: acs; position: relative; padding: .55rem .7rem .55rem 2.7rem; background: #fff; border: 1px solid #f1d3c2; border-radius: 10px; line-height: 1.45; }
.ac-steps li::before { content: counter(acs); position: absolute; left: .6rem; top: .5rem; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--danger); color: #fff; font-weight: 800; display: grid; place-items: center; font-size: .9rem; }
@media (min-width: 900px) { .ac-home-box { display: grid; grid-template-columns: 1fr 1.6fr; gap: 0 1.6rem; } .ac-home-box .btn-row { grid-column: 2; } .ac-home-box .ac-steps { margin-bottom: .8em; } }
.ac-quick { background: #fff7ed; border: 2px solid var(--danger); border-radius: 12px; padding: 1rem 1.1rem; margin-bottom: 1.6rem; }
.ac-quick-title { color: var(--danger); margin-top: 0; }
.ac-checklist li { margin-bottom: .5em; }
@media print { .ac-home-box, .ac-quick { box-shadow: none; break-inside: avoid; } .ac-steps li { break-inside: avoid; } }
.ac-home-box .btn-outline { color: var(--danger); border-color: var(--danger); background: #fff; }
.ac-home-box .btn-outline:hover, .ac-home-box .btn-outline:focus { background: var(--danger); color: #fff; }
@media (min-width: 900px) { .ac-home-box .btn-row { grid-column: 1; grid-row: 2; align-self: start; flex-direction: column; align-items: flex-start; } .ac-home-box .ac-steps { grid-column: 2; grid-row: 1 / span 2; } }

/* ---------- Mobile overflow fixes (narrow screens; print unaffected) ---------- */
.article > *, .grid > *, .rc-grid > *, .compare > * { min-width: 0; }
@media screen and (max-width: 900px) { .article { grid-template-columns: minmax(0, 1fr); } }
@media screen and (max-width: 640px) {
  .fieldguide .grid-3, .fieldguide .grid-2, .rc-grid { grid-template-columns: minmax(0, 1fr); }
  .article table, .fieldguide table, .radio-card table { display: block; max-width: 100%; overflow-x: auto; }
  .article pre { white-space: pre-wrap; }
  .article, .fieldguide, .radio-card { overflow-wrap: anywhere; }
}
@media screen and (max-width: 440px) { .pocket .pk-page { max-width: 100%; } }
.stats > * { min-width: 0; }
@media screen and (max-width: 860px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .stat { overflow-wrap: anywhere; } }
