:root {
  --ink: #2a1a10;
  --outline: #3a2214;
  --sky: #7cc4f2;
  --grass: #4caf3e;
  --grass-dark: #2f8a31;
  --sun: #ffd84d;
  --chestnut: #c26a2c;
  --cream: #fff6e8;
  --barn: #c8453b;
  --pink: #ff9ec4;
  --radius: 22px;
  --shadow: 0 6px 0 var(--outline);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Nunito", system-ui, sans-serif;
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--cream);
}
h1, h2, h3 { font-family: "Fredoka", "Nunito", sans-serif; line-height: 1.1; margin: 0 0 .4em; }
h2 { font-size: clamp(2rem, 4vw, 2.8rem); }
a { color: inherit; }
img { max-width: 100%; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: min(1100px, 92vw); margin: 0 auto; }

/* Buttons */
.btn {
  display: inline-block;
  font: 700 1.05rem "Fredoka", sans-serif;
  background: var(--sun);
  color: var(--ink);
  border: 4px solid var(--outline);
  border-radius: 999px;
  padding: .7em 1.4em;
  text-decoration: none;
  box-shadow: 0 5px 0 var(--outline);
  cursor: pointer;
  transition: transform .12s, box-shadow .12s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 7px 0 var(--outline); }
.btn:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--outline); }
.btn:focus-visible, a:focus-visible, select:focus-visible, input:focus-visible, .myth:focus-visible {
  outline: 4px dashed var(--barn); outline-offset: 4px;
}
.btn-ghost { background: #fff; }
.btn-small { padding: .45em 1em; font-size: .95rem; box-shadow: 0 4px 0 var(--outline); }

/* Nav */
.nav {
  position: absolute; inset: 0 0 auto 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 4vw;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 700 1.5rem "Fredoka", sans-serif; }
.brand img { width: 52px; height: auto; filter: drop-shadow(0 3px 0 rgba(0,0,0,.25)); }
.footer .brand img { width: 44px; }
.nav nav { display: flex; align-items: center; gap: 22px; font-weight: 800; }
.nav nav a:not(.btn) { text-decoration: none; }
.nav nav a:not(.btn):hover { text-decoration: underline wavy var(--barn); }

/* Hero */
.hero { position: relative; min-height: max(720px, 100vh); overflow: hidden; display: flex; align-items: center; }
.scene { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-inner {
  position: relative; z-index: 2;
  width: min(1200px, 92vw); margin: 0 auto; padding: 110px 0 60px;
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; align-items: end;
}
.hero-copy {
  background: rgba(255, 246, 232, .93);
  border: 5px solid var(--outline);
  border-radius: 32px;
  padding: 34px 36px;
  box-shadow: 0 10px 0 var(--outline);
  align-self: center;
}
.eyebrow { font-weight: 800; text-transform: uppercase; letter-spacing: .08em; font-size: .8rem; color: var(--barn); margin: 0 0 .6em; }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); }
.hero h1 span { color: var(--chestnut); }
.lede { font-size: 1.2rem; margin: 0 0 .5em; }
.aside { font-style: italic; color: #6b4a33; margin: 0 0 1.2em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; }

.hero-horse { position: relative; display: flex; flex-direction: column; align-items: center; justify-self: center; width: min(420px, 100%); margin-bottom: 30px; }
.hero-horse picture { display: block; width: 100%; }
.mascot { width: 100%; height: auto; display: block; transform-origin: 50% 90%; animation: bob 4s ease-in-out infinite; filter: drop-shadow(0 10px 0 rgba(58,34,20,.9)); cursor: pointer; }
.bubble {
  position: relative; z-index: 3;
  background: #fff; border: 4px solid var(--outline); border-radius: 22px;
  padding: 12px 16px; font-weight: 600; font-size: 1rem; line-height: 1.35;
  margin-bottom: 14px; max-width: 300px; box-shadow: 0 5px 0 var(--outline);
}
.bubble::after {
  content: ""; position: absolute; left: 46%; bottom: -18px;
  border: 14px solid transparent; border-top-color: var(--outline); border-bottom: 0;
}
.bubble::before {
  content: ""; position: absolute; left: calc(46% + 5px); bottom: -10px; z-index: 1;
  border: 9px solid transparent; border-top-color: #fff; border-bottom: 0;
}

/* Animations */
@keyframes bob { 0%, 100% { transform: rotate(-1.5deg); } 50% { transform: rotate(1.5deg) translateY(-4px); } }
@keyframes drift { from { transform: translateX(0); } to { transform: translateX(60px); } }
.cloud { animation: drift 14s ease-in-out infinite alternate; }
.c2 { animation-duration: 18s; animation-delay: -6s; }
.c3 { animation-duration: 11s; animation-delay: -3s; }
@media (prefers-reduced-motion: reduce) {
  .cloud, .mascot { animation: none; }
  html { scroll-behavior: auto; }
}

/* Sections */
.section { padding: 90px 0; }
.section-lede { max-width: 640px; font-size: 1.1rem; margin: 0 0 32px; }
.tip-section { background: var(--grass-dark); color: var(--cream); position: relative; }
.tip-section::before {
  content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 40px;
  background: radial-gradient(40px 40px at 40px 0, var(--grass-dark) 98%, transparent) repeat-x;
  background-size: 80px 40px; transform: translateY(-38px);
}
.tip-section h2 { color: var(--sun); }

.tip-card {
  background: var(--cream); color: var(--ink);
  border: 5px solid var(--outline); border-radius: 28px;
  padding: 30px 32px; max-width: 720px;
  box-shadow: 0 10px 0 var(--outline);
  transition: transform .25s;
}
.tip-card.flip { transform: rotate(-1.2deg) scale(.98); }
.tip-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.chip { background: var(--sky); border: 3px solid var(--outline); border-radius: 999px; padding: 2px 12px; font-weight: 800; font-size: .85rem; }
.code { font: 700 1rem "Fredoka", sans-serif; color: #8a6a52; }
.tip-card h3 { font-size: 2rem; }
.unsmug {
  background: #ffe9a8; border: 3px dashed #b88a1e; border-radius: 14px;
  padding: 10px 14px; margin: 14px 0 20px; font-size: 1rem;
}
.unsmug.vet { background: #ffd9d4; border-color: var(--barn); }
.tip-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.filter-label { margin-left: auto; font-weight: 800; }
select {
  font: 600 1rem "Nunito", sans-serif; padding: 8px 12px;
  border: 3px solid var(--outline); border-radius: 12px; background: #fff;
}
.count-line { margin-top: 26px; font-weight: 800; }

.pillars { background: #e3f4fc; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
  background: #fff; border: 5px solid var(--outline); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow); display: flex; flex-direction: column;
}
.card:nth-child(2) { transform: rotate(.8deg); }
.card:nth-child(3) { transform: rotate(-.8deg); }
.card-icon svg { width: 64px; height: 64px; }
.card h3 { font-size: 1.6rem; margin-top: 8px; }
.card p { flex: 1; }
.tag { align-self: flex-start; font-weight: 800; font-size: .85rem; border: 3px solid var(--outline); border-radius: 999px; padding: 2px 12px; background: #eee; }
.tag-now { background: var(--sun); }

.myths { background: var(--cream); }
.myth-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.myth {
  position: relative; min-height: 200px; cursor: pointer; perspective: 900px;
  border: none; background: none; padding: 0; text-align: left; font: inherit; color: inherit;
}
.myth-inner { position: relative; width: 100%; height: 100%; min-height: 200px; transition: transform .5s; transform-style: preserve-3d; }
.myth[aria-pressed="true"] .myth-inner { transform: rotateY(180deg); }
.myth-face {
  position: absolute; inset: 0; backface-visibility: hidden;
  border: 4px solid var(--outline); border-radius: 18px; padding: 18px;
  box-shadow: 0 6px 0 var(--outline); display: flex; flex-direction: column; gap: 8px;
}
.myth-front { background: #fff; }
.myth-front .stamp {
  align-self: flex-start; font: 700 .85rem "Fredoka", sans-serif; color: var(--barn);
  border: 3px solid var(--barn); border-radius: 8px; padding: 0 8px; transform: rotate(-4deg);
}
.myth-front p { font: 600 1.15rem "Fredoka", sans-serif; margin: 0; text-decoration: line-through var(--barn); text-decoration-thickness: 3px; }
.myth-back { background: #e5f6dd; transform: rotateY(180deg); font-size: .95rem; overflow: auto; }
.myth-back b { font-family: "Fredoka", sans-serif; }
@media (prefers-reduced-motion: reduce) { .myth-inner { transition: none; } }

.promise { background: var(--sun); padding: 56px 0; border-top: 5px solid var(--outline); border-bottom: 5px solid var(--outline); }
.promise-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.promise h3 { font-size: 1.4rem; }
.promise p { margin: 0; }

.join { background: linear-gradient(#9ad6f7, #d9f1fb); }
.join-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: center; }
.join-form {
  display: flex; flex-wrap: wrap; gap: 12px; background: #fff;
  border: 5px solid var(--outline); border-radius: 26px; padding: 22px; box-shadow: var(--shadow);
}
.join-form input {
  flex: 1 1 220px; font: 600 1.05rem "Nunito", sans-serif; padding: 12px 16px;
  border: 3px solid var(--outline); border-radius: 999px;
}
.form-msg { flex-basis: 100%; margin: 0; font-weight: 800; min-height: 1.4em; }

.footer { background: var(--outline); color: var(--cream); padding: 34px 0; font-size: .95rem; }
.footer-row { display: flex; flex-wrap: wrap; gap: 18px 32px; align-items: center; justify-content: space-between; }
.footer p { margin: 0; }
.footer .brand { font-size: 1.2rem; }

/* Responsive */
@media (max-width: 900px) {
  .nav nav a:not(.btn) { display: none; }
  .hero-inner { grid-template-columns: 1fr; padding-top: 96px; }
  .hero-horse { width: min(300px, 80%); }
  .cards, .promise-row, .join-inner { grid-template-columns: 1fr; }
  .card:nth-child(n) { transform: none; }
  .filter-label { margin-left: 0; }
}
@media (max-width: 520px) {
  body { font-size: 17px; }
  .hero-copy { padding: 24px 22px; }
  .tip-card { padding: 22px; }
  .brand span { font-size: 1.25rem; }
}
