/* TrailFox — trailfoxapp.co.uk
   Palette from the app itself: cream, sand, fox-tan, peach, sage, sky.
   Display face: Baloo 2 (self-hosted variable, 600–700). Body: system stack. */

@font-face {
  font-family: "Baloo 2";
  src: url("fonts/baloo2-latin.woff2") format("woff2");
  font-weight: 600 700;
  font-display: swap;
}

:root {
  --cream: #F9F7F2;
  --sand: #EFE9DD;
  --ink: #2F2A22;
  --ink-soft: #5C5347;
  --fox: #D4A373;
  --fox-deep: #8A5A2B;
  --peach: #FFD6A5;
  --sage: #A3B18A;
  --sage-deep: #56653F;
  --sky: #B8D4E3;
  --white: #FFFFFF;
  --radius: 18px;
  --display: "Baloo 2", "Avenir Next", "Trebuchet MS", sans-serif;
  --body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --shadow: 0 2px 6px rgba(47, 42, 34, 0.07), 0 12px 32px rgba(47, 42, 34, 0.08);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; }

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.15;
  color: var(--ink);
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h1 { font-size: clamp(2rem, 5.5vw, 3.1rem); }
h2 { font-size: clamp(1.55rem, 3.6vw, 2.15rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

a { color: var(--fox-deep); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible {
  outline: 3px solid var(--fox-deep);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.wrap--narrow { max-width: 760px; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(249, 247, 242, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--sand);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--ink);
  text-decoration: none;
}
.brand img { width: 36px; height: 36px; border-radius: 9px; }

.nav-toggle {
  margin-left: auto;
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: none;
  border: 0;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2.5px;
  border-radius: 2px;
  background: var(--ink);
}

.site-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--cream);
  border-bottom: 1px solid var(--sand);
  padding: 8px 20px 20px;
}
.site-nav.open { display: block; }
.site-nav a {
  display: block;
  padding: 10px 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.05rem;
  text-decoration: none;
  color: var(--ink);
}
.site-nav a[aria-current="page"] { color: var(--fox-deep); }
.site-nav .nav-cta {
  display: inline-block;
  margin-top: 10px;
  background: var(--ink);
  color: var(--cream);
  padding: 10px 22px;
  border-radius: 999px;
}

@media (min-width: 780px) {
  .nav-toggle { display: none; }
  .site-nav {
    display: flex;
    position: static;
    margin-left: auto;
    align-items: center;
    gap: 26px;
    background: none;
    border: 0;
    padding: 0;
  }
  .site-nav a { padding: 4px 0; }
  .site-nav .nav-cta { margin: 0; padding: 9px 20px; }
  .site-nav .nav-cta:hover { background: var(--fox-deep); color: var(--cream); }
}

/* ---------- Hero ---------- */

.hero { padding: 56px 0 30px; }
.hero .wrap {
  display: grid;
  gap: 40px;
  align-items: center;
}
@media (min-width: 900px) {
  .hero { padding: 72px 0 48px; }
  /* Two columns only on the homepage hero (headline + try-it widget) —
     narrow heroes (blog, packs) stay single-column. */
  .hero .wrap:not(.wrap--narrow) { grid-template-columns: 1.05fr 0.95fr; }
}
.hero .eyebrow {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  color: var(--sage-deep);
  margin-bottom: 10px;
}
.hero .lede {
  font-size: 1.2rem;
  color: var(--ink-soft);
  max-width: 34em;
}
/* Narrow heroes (blog, packs) are a single centred column — centre the text
   and let element margins set the rhythm instead of the homepage grid gap */
.hero .wrap--narrow {
  gap: 0;
  text-align: center;
}
.hero .wrap--narrow .lede { margin-left: auto; margin-right: auto; }

.store-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin: 26px 0 8px;
}
.store-badges img { height: 52px; width: auto; }
.free-note {
  font-size: 0.9rem;
  color: var(--ink-soft);
  margin-top: 4px;
}

/* ---------- Try-it widget (signature) ---------- */

.tryit {
  background: var(--white);
  border: 2px solid var(--sand);
  border-radius: calc(var(--radius) + 6px);
  padding: 24px;
  box-shadow: var(--shadow);
}
.tryit-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
  margin: 0 0 4px;
}
.tryit-sub { font-size: 0.92rem; color: var(--ink-soft); margin: 0 0 14px; }
.tryit fieldset { border: 0; padding: 0; margin: 0 0 14px; }
.tryit legend {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0 0 8px;
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ink);
  background: var(--sand);
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 8px 15px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
}
.chip:hover { transform: translateY(-1px); }
.chip[aria-pressed="true"] { background: var(--peach); border-color: var(--fox); }
.chips--place .chip[aria-pressed="true"] { background: var(--sky); border-color: var(--sage-deep); }

.tryit-card {
  background: var(--cream);
  border: 2px dashed var(--fox);
  border-radius: var(--radius);
  padding: 18px;
  min-height: 148px;
}
.tryit-card h3 { font-size: 1.1rem; margin-bottom: 6px; }
.tryit-card p { font-size: 0.95rem; color: var(--ink-soft); margin: 0; }
.tryit-card .placeholder { color: var(--ink-soft); font-size: 0.95rem; }
.tryit-more {
  display: inline-block;
  margin-top: 12px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.95rem;
}

/* ---------- Paw trail divider ---------- */

.paw-trail {
  display: block;
  width: min(320px, 60vw);
  margin: 8px auto -8px;
  opacity: 0.55;
}

/* ---------- Sections ---------- */

.section { padding: 64px 0; }
.section--sand { background: var(--sand); }
.section--sage { background: var(--sage); }
.section--sage h2, .section--sage p { color: var(--ink); }
.section-lede {
  font-size: 1.15rem;
  color: var(--ink-soft);
  max-width: 40em;
  margin-bottom: 2em;
}
.center { text-align: center; }
.center .section-lede { margin-left: auto; margin-right: auto; }

/* Trust strip */
.trust {
  border-top: 1px solid var(--sand);
  border-bottom: 1px solid var(--sand);
  padding: 16px 0;
}
.trust ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 28px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink-soft);
}

/* Steps */
.steps {
  display: grid;
  gap: 22px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
@media (min-width: 720px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li {
  counter-increment: step;
  background: var(--white);
  border-radius: var(--radius);
  padding: 26px 22px 22px;
  box-shadow: var(--shadow);
  position: relative;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  top: -16px;
  left: 20px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: var(--peach);
  border: 2px solid var(--fox);
  border-radius: 50%;
  font-family: var(--display);
  font-weight: 700;
}
.steps h3 { margin-top: 4px; }
.steps p { margin: 0; color: var(--ink-soft); font-size: 0.98rem; }

/* Activity examples grid */
.acts {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}
.acts li {
  background: var(--white);
  border-left: 5px solid var(--sage);
  border-radius: 12px;
  padding: 14px 16px;
  box-shadow: 0 1px 4px rgba(47, 42, 34, 0.06);
}
.acts b { font-family: var(--display); font-weight: 600; display: block; }
.acts span { font-size: 0.9rem; color: var(--ink-soft); }

/* Split feature (journal) */
.split {
  display: grid;
  gap: 34px;
  align-items: center;
}
@media (min-width: 860px) { .split { grid-template-columns: 1fr 1fr; } }
.split .visual {
  background: linear-gradient(160deg, var(--sky), var(--cream) 70%);
  border-radius: calc(var(--radius) + 6px);
  padding: 30px;
  text-align: center;
  font-size: 3rem;
  line-height: 1.3;
}
.split ul { padding-left: 1.2em; color: var(--ink-soft); }
.split li { margin-bottom: 0.5em; }

/* Pack cards */
.packs-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}
.pack-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  border-top: 6px solid var(--fox);
  transition: transform 0.15s;
}
.pack-card:hover { transform: translateY(-3px) rotate(-0.5deg); }
.pack-card--free { border-top-color: var(--sage); }
.pack-card .pack-emoji { font-size: 2rem; line-height: 1; display: block; margin-bottom: 10px; }
.pack-card h3 { margin-bottom: 4px; }
.pack-card .pack-tag {
  display: inline-block;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.03em;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--peach);
  margin-bottom: 10px;
}
.pack-card--free .pack-tag { background: #DCE8D0; }
.pack-card p { font-size: 0.95rem; color: var(--ink-soft); margin: 0; }

/* Deck teaser fan (homepage) */
.deck-fan {
  display: flex;
  justify-content: center;
  gap: 0;
  margin: 30px 0 10px;
}
.deck-fan .mini-card {
  width: 120px;
  background: var(--white);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 14px 10px;
  text-align: center;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.82rem;
  line-height: 1.25;
  border-top: 5px solid var(--fox);
}
.deck-fan .mini-card span { font-size: 1.5rem; display: block; margin-bottom: 6px; }
.deck-fan .mini-card:nth-child(odd) { transform: rotate(-4deg) translateY(6px); }
.deck-fan .mini-card:nth-child(even) { transform: rotate(3deg); }
.deck-fan .mini-card:not(:first-child) { margin-left: -18px; }
/* Five 120px cards can't fit a phone screen in one row — let the fan wrap */
@media (max-width: 600px) {
  .deck-fan { flex-wrap: wrap; gap: 10px; }
  .deck-fan .mini-card:not(:first-child) { margin-left: 0; }
}

/* FAQ */
.faq { max-width: 760px; margin: 0 auto; }
.faq details {
  background: var(--white);
  border-radius: 14px;
  padding: 4px 20px;
  margin-bottom: 12px;
  box-shadow: 0 1px 4px rgba(47, 42, 34, 0.06);
}
.faq summary {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.05rem;
  padding: 14px 0;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.4rem; color: var(--fox-deep); flex-shrink: 0; }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: var(--ink-soft); margin: 0 0 16px; }

/* CTA band — inset rounded card so it reads as its own moment, not part of the footer */
.cta-band {
  background: var(--ink);
  color: var(--cream);
  text-align: center;
  width: min(1080px, calc(100% - 40px));
  margin: 40px auto 72px;
  border-radius: calc(var(--radius) + 10px);
  box-shadow: var(--shadow);
}
.cta-band h2 { color: var(--cream); }
.cta-band p { color: #CFC8BC; max-width: 36em; margin-left: auto; margin-right: auto; }
.cta-band .store-badges { justify-content: center; }

.btn {
  display: inline-block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.05rem;
  background: var(--ink);
  color: var(--cream);
  text-decoration: none;
  padding: 13px 30px;
  border-radius: 999px;
  transition: background 0.15s;
}
.btn:hover { background: var(--fox-deep); color: var(--cream); }
.btn--light { background: var(--cream); color: var(--ink); }
.btn--light:hover { background: var(--peach); color: var(--ink); }

/* ---------- Blog ---------- */

/* Breadcrumbs live inside the page-title block (hero / post header), styled
   as a quiet eyebrow line rather than a separate bar */
.breadcrumbs { font-size: 0.82rem; margin-bottom: 14px; }
.breadcrumbs ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  margin: 0;
  padding: 0;
}
.hero .breadcrumbs ol { justify-content: center; }
.breadcrumbs li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--display);
  font-weight: 600;
  color: var(--ink-soft);
}
.breadcrumbs li + li::before { content: "›"; color: var(--fox); line-height: 1; }
.breadcrumbs a { color: var(--fox-deep); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }

.post-list {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}
.post-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  display: flex;
  flex-direction: column;
}
.post-card .post-tag {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--sage-deep);
  margin-bottom: 8px;
}
.post-card h2, .post-card h3 { font-size: 1.25rem; }
.post-card h2 a, .post-card h3 a { text-decoration: none; color: var(--ink); }
.post-card h2 a:hover, .post-card h3 a:hover { color: var(--fox-deep); }
.post-card p { color: var(--ink-soft); font-size: 0.96rem; flex-grow: 1; }
.post-card .post-meta { font-size: 0.85rem; color: var(--ink-soft); margin: 0; }

.post { max-width: 820px; margin: 0 auto; }
.post header.post-head { padding: 24px 0 8px; }
.post .post-meta { font-size: 0.92rem; color: var(--ink-soft); }
.post-tag {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--sage-deep);
  margin: 0 0 8px;
}
.post-hero {
  display: block;
  width: 100%;
  max-width: 820px;
  height: auto;
  border-radius: calc(var(--radius) + 8px);
  box-shadow: var(--shadow);
  margin: 18px 0 34px;
}
.post-body { max-width: 720px; }
.post-body h2 { margin-top: 1.6em; }
.post-body h3 { margin-top: 1.3em; }
.post-body ul, .post-body ol { padding-left: 1.3em; }
.post-body li { margin-bottom: 0.45em; }
.post-body .tip {
  background: var(--sand);
  border-left: 5px solid var(--fox);
  border-radius: 10px;
  padding: 14px 18px;
  margin: 1.4em 0;
  font-size: 0.98rem;
}

.app-plug {
  background: linear-gradient(150deg, var(--peach), var(--cream) 85%);
  border: 2px solid var(--fox);
  border-radius: var(--radius);
  padding: 24px;
  margin: 2em 0;
}
.app-plug h3 { margin-top: 0; }
.app-plug .store-badges { margin: 14px 0 0; }
.app-plug .store-badges img { height: 44px; }

.related {
  margin-top: 4em;
  padding: 2.2em 0 4.5em;
  border-top: 2px dashed rgba(212, 163, 115, 0.55);
}
.related h2 { font-size: 1.5rem; }
.related .post-card h3 { font-size: 1.1rem; }

/* CubTrack cross-promo (sky accent = CubTrack, not TrailFox tan) */
.crosspromo { padding: 0 0 72px; }
.crosspromo-card {
  max-width: 860px;
  margin: 0 auto;
  background: var(--white);
  border: 2px solid var(--sky);
  border-radius: calc(var(--radius) + 6px);
  padding: 26px 28px;
  display: flex;
  gap: 18px;
  align-items: flex-start;
  box-shadow: 0 1px 4px rgba(47, 42, 34, 0.06);
}
.crosspromo-emoji { font-size: 2rem; line-height: 1; margin-top: 2px; }
.crosspromo-card h2 { font-size: 1.25rem; margin-bottom: 4px; }
.crosspromo-card p { color: var(--ink-soft); font-size: 0.98rem; margin: 0; }
.crosspromo-card .store-badges { margin: 14px 0 0; }
.crosspromo-card .store-badges img { height: 44px; }
@media (max-width: 560px) { .crosspromo-card { flex-direction: column; } }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--ink);
  color: #CFC8BC;
  padding: 52px 0 32px;
  font-size: 0.95rem;
}
.site-footer a { color: var(--peach); text-decoration: none; }
.site-footer a:hover { color: var(--cream); text-decoration: underline; }
.footer-grid {
  display: grid;
  gap: 32px;
  margin-bottom: 32px;
}
@media (min-width: 720px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-grid h3 {
  color: var(--cream);
  font-size: 1rem;
  margin-bottom: 12px;
}
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 8px; }
.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.footer-brand img { width: 34px; height: 34px; border-radius: 8px; }
.footer-brand span { font-family: var(--display); font-weight: 700; font-size: 1.15rem; color: var(--cream); }
.footer-note { border-top: 1px solid #453D31; padding-top: 22px; font-size: 0.85rem; }

/* ---------- Misc pages ---------- */

/* Top/bottom only: a padding shorthand here zeroed .wrap's side gutter, so text ran to the screen edge on phones */
.prose { padding-top: 40px; padding-bottom: 70px; }
.prose h2 { margin-top: 1.6em; }
.prose ul { padding-left: 1.3em; }

.err { text-align: center; padding: 90px 20px; }
.err h1 { font-size: 4rem; }

/* ═══════════ Fun layer ═══════════ */

@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(var(--tilt, 0deg)); }
  50% { transform: translateY(-12px) rotate(var(--tilt, 0deg)); }
}
@keyframes popIn {
  0% { opacity: 0; transform: scale(0.92) translateY(6px); }
  70% { transform: scale(1.02); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes wiggle {
  0%, 100% { transform: rotate(0); }
  30% { transform: rotate(-3deg); }
  60% { transform: rotate(3deg); }
}
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  40% { transform: translateY(-14px); }
  60% { transform: translateY(-6px); }
}

/* Floating doodles in the hero */
.hero { position: relative; overflow: hidden; }
.doodle {
  position: absolute;
  font-size: 1.6rem;
  opacity: 0.5;
  pointer-events: none;
  user-select: none;
  animation: bob 6s ease-in-out infinite;
}
.doodle:nth-of-type(2n) { animation-duration: 7.5s; animation-delay: 1.2s; }
.doodle:nth-of-type(3n) { animation-duration: 9s; animation-delay: 2.4s; }
@media (max-width: 899px) { .doodle { display: none; } }

/* Squiggle underline for centred section headings */
.center h2::after {
  content: "";
  display: block;
  width: 110px;
  height: 10px;
  margin: 10px auto 0;
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 110 10"><path d="M2 6 Q 10 1, 19 6 T 36 6 T 53 6 T 70 6 T 87 6 T 104 6" fill="none" stroke="%23D4A373" stroke-width="3" stroke-linecap="round"/></svg>') no-repeat center / contain;
}
.cta-band h2::after {
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 110 10"><path d="M2 6 Q 10 1, 19 6 T 36 6 T 53 6 T 70 6 T 87 6 T 104 6" fill="none" stroke="%23FFD6A5" stroke-width="3" stroke-linecap="round"/></svg>') no-repeat center / contain;
}

/* Trust strip → colourful pills */
.trust li {
  background: var(--sand);
  padding: 6px 16px;
  border-radius: 999px;
}
.trust li:nth-child(2) { background: #E7F0E0; }
.trust li:nth-child(3) { background: #FBE8D8; }
.trust li:nth-child(4) { background: #E3EEF5; }

/* Colour-cycled cards: packs, posts, activity grid */
.packs-grid .pack-card:nth-child(4n+1) { border-top-color: var(--fox); }
.packs-grid .pack-card:nth-child(4n+2) { border-top-color: var(--sage); }
.packs-grid .pack-card:nth-child(4n+3) { border-top-color: var(--sky); }
.packs-grid .pack-card:nth-child(4n+4) { border-top-color: var(--peach); }
.packs-grid .pack-card--free { border-top-color: var(--sage) !important; }
.post-list .post-card { border-top: 6px solid var(--fox); transition: transform 0.15s; }
.post-list .post-card:nth-child(4n+2) { border-top-color: var(--sage); }
.post-list .post-card:nth-child(4n+3) { border-top-color: var(--sky); }
.post-list .post-card:nth-child(4n+4) { border-top-color: var(--peach); }
.post-list .post-card:hover { transform: translateY(-3px) rotate(-0.4deg); }
.acts li { transition: transform 0.15s; }
.acts li:hover { transform: translateY(-2px) rotate(0.5deg); }
.acts li:nth-child(4n+2) { border-left-color: var(--fox); }
.acts li:nth-child(4n+3) { border-left-color: var(--sky); }
.acts li:nth-child(4n+4) { border-left-color: var(--peach); }

/* Pack emoji perks up on hover */
.pack-card .pack-emoji { transition: transform 0.2s; }
.pack-card:hover .pack-emoji { transform: rotate(-10deg) scale(1.2); }

/* Chips get playful */
.chip:hover { animation: wiggle 0.4s ease-in-out; }
.chip[aria-pressed="true"] { transform: scale(1.06); }

/* Activity card deals in */
.tryit-card.dealt { animation: popIn 0.35s ease-out; }

/* Deck fan spreads on hover */
.deck-fan .mini-card { transition: transform 0.25s ease, margin 0.25s ease; }
.deck-fan:hover .mini-card:not(:first-child) { margin-left: -6px; }
.deck-fan:hover .mini-card:nth-child(odd) { transform: rotate(-7deg) translateY(8px); }
.deck-fan:hover .mini-card:nth-child(even) { transform: rotate(6deg) translateY(-4px); }

/* Steps look hand-placed */
@media (min-width: 720px) {
  .steps li:nth-child(1) { transform: rotate(-0.6deg); }
  .steps li:nth-child(3) { transform: rotate(0.6deg); }
}

/* Buttons lift */
.btn, .nav-cta { transition: transform 0.15s, background 0.15s, box-shadow 0.15s; }
.btn:hover, .nav-cta:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(47, 42, 34, 0.18); }

/* 404 fox bounces */
.err h1 { animation: bounce 2.2s ease-in-out infinite; }

/* App screenshots in phone frames */
.phones-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 28px;
  margin-top: 44px;
}
.phone {
  width: min(240px, 70vw);
  text-align: center;
}
.phone img {
  width: 100%;
  height: auto;
  border-radius: 26px;
  border: 5px solid var(--ink);
  box-shadow: var(--shadow);
  background: var(--white);
}
.phone:nth-child(odd) img { transform: rotate(-1.2deg); }
.phone:nth-child(even) img { transform: rotate(1.2deg); }
.phone-cap {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink-soft);
  margin-top: 12px;
}
.split .visual--shot {
  background: none;
  padding: 0;
  font-size: initial;
  text-align: center;
}
.split .visual--shot img {
  width: min(260px, 75vw);
  border-radius: 26px;
  border: 5px solid var(--ink);
  box-shadow: var(--shadow);
  transform: rotate(1.5deg);
}

/* Story banner illustration */
.story-img {
  display: block;
  width: 100%;
  max-width: 860px;
  margin: 36px auto 0;
  border-radius: calc(var(--radius) + 8px);
  box-shadow: var(--shadow);
}
/* Crops the empty left half of the toddler-meets-fox illustration */
.story-img--fox {
  aspect-ratio: 2.2 / 1;
  object-fit: cover;
  object-position: 92% 42%;
}

/* Split visual as a flat illustration (not a phone frame) */
.split .visual--illo {
  background: none;
  padding: 0;
  font-size: initial;
}
.split .visual--illo img {
  width: 100%;
  height: auto;
  border-radius: calc(var(--radius) + 8px);
  box-shadow: var(--shadow);
  transform: rotate(-1deg);
}


/* Blog cards get their illustration as a thumbnail */
.post-card .card-img {
  display: block;
  margin: -24px -24px 18px;
  border-radius: 12px 12px 0 0;
  overflow: hidden;
}
.post-card .card-img img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
  transition: transform 0.25s ease;
}
.post-card:hover .card-img img { transform: scale(1.04); }

/* Warm wash on the homepage hero only — on inner pages it created a visible
   band change behind the breadcrumbs/title area */
.hero:has(.tryit) { background: linear-gradient(180deg, #FCF1E1 0%, var(--cream) 82%); }

/* Small delights */
::selection { background: var(--peach); color: var(--ink); }
[id] { scroll-margin-top: 84px; }

/* Scroll reveal (JS adds .in; safe without JS via body:not(.js)) */
body.js .reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.5s ease, transform 0.5s ease; }
body.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  body.js .reveal { opacity: 1; transform: none; }
  .doodle, .err h1 { animation: none; }
}

/* ---------- People: about + author pages, post author box ---------- */

/* Initials stand in until real photos arrive: put an <img> inside .avatar to replace them */
.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--peach);
  color: var(--fox-deep);
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.3rem;
  line-height: 1;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar--sage { background: #E7F0E0; color: var(--sage-deep); }
.avatar--lg { width: 116px; height: 116px; font-size: 2.3rem; }

.author-box {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: var(--sand);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin: 2.6em 0 0;
}
.author-box p { margin: 0; font-size: 0.96rem; color: var(--ink-soft); }
.author-box .author-box-name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.08rem;
  color: var(--ink);
  margin-bottom: 4px;
}
.author-box .author-box-links { margin-top: 8px; font-size: 0.9rem; }

.profile-head { display: flex; gap: 24px; align-items: center; margin: 4px 0 30px; }
.profile-head h1 { margin-bottom: 6px; }
.profile-role { font-family: var(--display); font-weight: 600; color: var(--sage-deep); margin: 0; }
.prose .intro { font-size: 1.15rem; color: var(--ink-soft); }
@media (max-width: 560px) {
  .profile-head { flex-direction: column; align-items: flex-start; gap: 14px; }
  .author-box { flex-direction: column; }
}

.people {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  list-style: none;
  margin: 1.4em 0 0;
}
.person-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border-top: 6px solid var(--fox);
  padding: 24px;
}
.person-card:nth-child(2) { border-top-color: var(--sage); }
.person-card h3 { margin: 14px 0 6px; }
.person-card h3 a { color: var(--ink); text-decoration: none; }
.person-card h3 a:hover { color: var(--fox-deep); }
.person-card p { color: var(--ink-soft); font-size: 0.96rem; margin: 0; }

.places { list-style: none; margin: 1em 0; }
.places li {
  background: var(--white);
  border-left: 5px solid var(--sage);
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 10px;
  box-shadow: 0 1px 4px rgba(47, 42, 34, 0.06);
}
.places li:nth-child(3n+2) { border-left-color: var(--fox); }
.places li:nth-child(3n+3) { border-left-color: var(--sky); }
.places a { font-family: var(--display); font-weight: 700; }
.prose .people, .prose .places { padding-left: 0; }

.page-updated { margin-top: 2.6em; font-size: 0.88rem; color: var(--ink-soft); }
