/* Sunny River Farm: site styles. Colours come from the farm itself: sky, grass, the red barn and the sun. */
:root {
  --sky: #5aa6ea;
  --sky-deep: #2f6fc2;
  --grass: #3fae49;
  --barn: #d8343f;
  --barn-deep: #b02230;
  --sun: #ffd23a;
  --cream: #fff9ec;
  --paper: #ffffff;
  --ink: #2a2440;
  --ink-soft: #5b5670;
  --line: #eadfc8;
  --night: #2b3a78;
  --radius: 22px;
  --shadow: 0 6px 0 rgba(42, 36, 64, .08), 0 14px 30px rgba(42, 36, 64, .10);
  --head: "Fredoka", "Trebuchet MS", system-ui, sans-serif;
  --body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--cream); color: var(--ink); font-family: var(--body); font-size: 1.0625rem; line-height: 1.6; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { font-family: var(--head); font-weight: 600; line-height: 1.15; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(2.1rem, 5.2vw, 3.6rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.3rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
a { color: inherit; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(680px, 100% - 32px); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 10px; z-index: 50; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--sky-deep); outline-offset: 3px; border-radius: 8px; }

/* header */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(255, 249, 236, .94); backdrop-filter: blur(8px); border-bottom: 2px solid var(--line); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--head); font-weight: 700; font-size: 1.3rem; color: var(--barn); }
.brand img { border-radius: 50%; border: 3px solid var(--sun); }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a { text-decoration: none; font-weight: 700; padding: 8px 14px; border-radius: 999px; }
.nav a:hover { background: #fff; }
.nav a[aria-current="page"]:not(.btn) { background: var(--sun); }
.menu-btn { display: none; font: inherit; font-weight: 700; background: #fff; border: 2px solid var(--line); border-radius: 999px; padding: 8px 16px; color: var(--ink); cursor: pointer; }

/* buttons and links */
.btn { display: inline-block; font-family: var(--head); font-weight: 600; font-size: 1.05rem; text-decoration: none; background: var(--barn); color: #fff; padding: 12px 24px; border-radius: 999px; border: 0; box-shadow: 0 4px 0 var(--barn-deep); cursor: pointer; transition: transform .12s ease, box-shadow .12s ease; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 6px 0 var(--barn-deep); }
.btn:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--barn-deep); }
.nav a.btn:hover { background: var(--barn); }
.btn-small { padding: 8px 18px; font-size: 1rem; margin-left: 6px; }
.btn-ghost { background: #fff; color: var(--ink); box-shadow: 0 4px 0 var(--line); }
.btn-ghost:hover { box-shadow: 0 6px 0 var(--line); }
.link { color: var(--sky-deep); font-weight: 700; text-underline-offset: 3px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.4em 0 0; }
.eyebrow { font-family: var(--head); font-weight: 600; letter-spacing: .02em; color: var(--sky-deep); margin-bottom: .6em; }
.lead { font-size: 1.2rem; max-width: 60ch; }
.sub { color: var(--ink-soft); max-width: 60ch; margin-top: -.3em; }

/* home hero */
.hero { background: linear-gradient(180deg, #a9d4fb 0%, #dcefff 55%, var(--paper) 55%); padding: clamp(28px, 5vw, 60px) 0 0; }
.hero-text { text-align: center; margin-bottom: clamp(22px, 3.5vw, 40px); }
.hero-text h1 { color: var(--ink); }
.hero-text .eyebrow { display: inline-block; background: #fff; padding: 5px 16px; border-radius: 999px; }
.hero-text .lead { margin-inline: auto; max-width: 52ch; }
.hero-text .actions { justify-content: center; }
.hero-img { width: 100%; aspect-ratio: 16 / 7.4; object-fit: cover; object-position: 50% 58%; border-radius: 28px; border: 6px solid #fff; box-shadow: var(--shadow); }

/* numbers */
.stats { background: var(--paper); border-bottom: 2px solid var(--line); padding: 28px 0 18px; }
.stat-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px 88px; }   /* centred: there are two numbers now, not four */
.stat { text-align: center; }
.stat strong { display: block; font-family: var(--head); font-weight: 700; font-size: clamp(1.5rem, 3vw, 2.2rem); color: var(--barn); font-variant-numeric: tabular-nums; }
.stat span { color: var(--ink-soft); }
.asof { text-align: center; color: var(--ink-soft); font-size: .92rem; margin: 14px auto 0; }

/* sections */
.section { padding: clamp(40px, 7vw, 80px) 0; }
.tint { background: #eaf6e4; }
.page-head { background: linear-gradient(180deg, #cfe8ff 0%, var(--cream) 100%); padding: clamp(36px, 6vw, 72px) 0 clamp(20px, 3vw, 36px); }
.two-col { display: grid; grid-template-columns: 1fr 1.25fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.tint .two-col { align-items: start; grid-template-columns: 1fr 1fr; }

/* cards */
.card { background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.card-body { display: block; padding: 16px 18px 20px; }
.card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 28px; }
.show-card { text-decoration: none; border-top: 8px solid var(--barn); transition: transform .15s ease; }
.show-card:hover { transform: translateY(-4px); }
.show-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.show-card strong { display: block; font-family: var(--head); font-size: 1.2rem; }
.show-card span span { color: var(--ink-soft); font-size: .98rem; }
.c-red { --c: var(--barn); } .c-blue { --c: var(--sky-deep); } .c-yellow { --c: #e2a800; } .c-green { --c: var(--grass); } .c-night { --c: var(--night); }
.show-card[class*="c-"] { border-top-color: var(--c); }

/* friends */
.faces { display: grid; grid-template-columns: repeat(8, 1fr); gap: 14px; margin-top: 28px; }
.face { text-decoration: none; text-align: center; font-family: var(--head); }
.face img { border-radius: 50%; border: 5px solid #fff; box-shadow: var(--shadow); transition: transform .15s ease; }
.face:hover img { transform: scale(1.06) rotate(-2deg); }
.face strong { display: block; margin-top: 8px; font-weight: 600; }
.friend-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.friend { scroll-margin-top: 90px; }
.friend img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.friend h2 { font-size: 1.6rem; margin-bottom: 0; }
.tag { display: inline-block; background: var(--sun); font-family: var(--head); font-weight: 600; font-size: .9rem; padding: 2px 12px; border-radius: 999px; margin: 6px 0 10px; }
.friend p:last-child { margin: 0; }

/* shows and videos */
.show { scroll-margin-top: 70px; border-top: 2px solid var(--line); }
.show:nth-of-type(even) { background: var(--paper); }
.show-head { max-width: 70ch; margin-bottom: 24px; padding-left: 18px; border-left: 8px solid var(--c, var(--barn)); }
.tagline { font-family: var(--head); font-size: 1.2rem; color: var(--ink-soft); margin-top: -.3em; }
.facts { font-weight: 700; margin: 0; }
.video-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.yt { display: block; text-decoration: none; }
.yt-frame { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: 18px; overflow: hidden; background: #1c1930; box-shadow: var(--shadow); }
.yt-frame img, .yt-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border: 0; }
.play { position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; background: var(--barn); box-shadow: 0 4px 0 var(--barn-deep); transition: transform .15s ease; }
.play::after { content: ""; position: absolute; left: 26px; top: 20px; border-style: solid; border-width: 12px 0 12px 19px; border-color: transparent transparent transparent #fff; }
.yt:hover .play { transform: scale(1.12); }
.yt-big .play { width: 88px; height: 88px; margin: -44px 0 0 -44px; }
.yt-big .play::after { left: 36px; top: 28px; border-width: 16px 0 16px 25px; }
.yt-title { display: block; font-family: var(--head); font-weight: 600; margin-top: 10px; }
.yt-len { display: block; color: var(--ink-soft); font-size: .92rem; }
.yt.playing .play { display: none; }

/* partners */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 24px; }
.feature { background: var(--paper); border-radius: var(--radius); padding: 22px; border: 2px solid var(--line); }
.feature p { margin: 0; }
.ticks { list-style: none; padding: 0; margin: 0 0 1.2em; }
.ticks li { position: relative; padding: 6px 0 6px 34px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 10px; width: 22px; height: 22px; border-radius: 50%; background: var(--grass); }
.ticks li::after { content: ""; position: absolute; left: 7px; top: 15px; width: 7px; height: 10px; border: solid #fff; border-width: 0 3px 3px 0; transform: rotate(40deg); }

/* call to action */
.cta { background: var(--sky-deep); color: #fff; text-align: center; padding: clamp(40px, 6vw, 72px) 0; }
.cta p { max-width: 56ch; margin-inline: auto; }
.cta .actions { justify-content: center; }

/* contact form */
.form { display: grid; gap: 18px; }
.field label { display: block; font-weight: 700; margin-bottom: 6px; }
.opt { font-weight: 400; color: var(--ink-soft); }
.field input, .field select, .field textarea { width: 100%; font: inherit; color: var(--ink); background: #fff; border: 2px solid #cfc4ad; border-radius: 14px; padding: 12px 14px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid var(--sky); outline-offset: 1px; border-color: var(--sky-deep); }
.field textarea { resize: vertical; min-height: 160px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note { color: var(--ink-soft); font-size: .95rem; margin: 0; }
.form .btn { justify-self: start; }
.notice { border-radius: var(--radius); padding: 20px 22px; margin-bottom: 22px; border: 2px solid; }
.notice.ok { background: #eaf6e4; border-color: var(--grass); }
.notice.bad { background: #fdecee; border-color: var(--barn); }
.notice p:last-child { margin: 0; }
.aspNetHidden { display: none; }

/* text pages */
.prose { max-width: 70ch; }
.prose h2 { font-size: 1.35rem; margin-top: 1.4em; }

/* footer */
.site-footer { background: var(--ink); color: #e9e6f5; padding: 40px 0 24px; }
.foot { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.foot-brand { font-family: var(--head); font-weight: 700; font-size: 1.3rem; color: var(--sun); margin: 0; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 6px 22px; align-content: start; }
.site-footer a { color: #fff; font-weight: 700; text-underline-offset: 3px; }
.site-footer .small { margin-top: 20px; font-size: .9rem; color: #bdb8d4; }
.site-footer p { margin: 0 0 .4em; }

/* smaller screens */
@media (max-width: 980px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .faces { grid-template-columns: repeat(4, 1fr); }
  .feature-grid, .friend-grid { grid-template-columns: repeat(2, 1fr); }
  .two-col, .tint .two-col { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .menu-btn { display: block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; background: var(--cream); border-bottom: 2px solid var(--line); padding: 10px 16px 16px; }
  .nav.open { display: flex; }
  .nav a { padding: 12px 14px; }
  .btn-small { margin: 6px 0 0; text-align: center; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .video-grid { grid-template-columns: 1fr; }
  .hero-img { aspect-ratio: 4 / 3; object-position: 44% 60%; }
  .hero-text .lead { font-size: 1.05rem; }
}
@media (max-width: 520px) {
  .card-grid, .feature-grid, .friend-grid { grid-template-columns: 1fr; }
  .faces { grid-template-columns: repeat(2, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* home: the live 3D farmyard (Content/world/farm-world.js). Until it starts, and wherever it can't, the picture shows instead. */
.world-stage { position: relative; aspect-ratio: 16 / 8.2; border-radius: 28px; border: 6px solid #fff; box-shadow: var(--shadow); overflow: hidden; background: #bfe0fb; }
.world-poster, .world-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.world-poster { object-fit: cover; object-position: 50% 58%; }
.world-canvas { display: block; opacity: 0; transition: opacity .6s ease; touch-action: pan-y; cursor: grab; outline-offset: -4px; }
.world-canvas.is-point { cursor: pointer; }
.world-canvas.is-drag { cursor: grabbing; }
.world-on .world-canvas { opacity: 1; }
.world-hud, .world [hidden] { display: none; }
.world-seasons, .world-tools, .world-hint { position: absolute; opacity: 0; transition: opacity .4s ease; pointer-events: none; }
.world-on .world-seasons, .world-on .world-tools, .world-on .world-hint { opacity: 1; pointer-events: auto; }
.world-seasons { top: 12px; left: 12px; display: flex; gap: 4px; padding: 4px; border-radius: 999px; background: rgba(255, 255, 255, .86); }
.world-tools { right: 12px; bottom: 12px; display: flex; gap: 6px; }
.world-seasons button, .world-tools button, .world-chip { font-family: var(--head); font-weight: 600; font-size: .95rem; color: var(--ink); border: 0; cursor: pointer; border-radius: 999px; }
.world-seasons button { background: transparent; padding: 6px 14px; }
.world-seasons button[aria-pressed="true"] { background: var(--sun); }
.world-seasons .world-night { margin-left: 6px; }
.world-seasons .world-night[aria-pressed="true"] { background: var(--night); color: #fff; }
.world-tools button { width: 42px; height: 42px; display: grid; place-items: center; background: rgba(255, 255, 255, .9); }
.world-tools svg { width: 22px; height: 22px; fill: var(--ink); }
.world-tools .i-play, .world-tools .is-paused .i-pause { display: none; }
.world-tools .is-paused .i-play { display: block; }
.world-hint { left: 14px; bottom: 14px; margin: 0; padding: 6px 14px; border-radius: 999px; background: rgba(255, 255, 255, .86); font-family: var(--head); font-size: .95rem; pointer-events: none !important; }
.world-bar { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 18px; }
.world-chip { background: #fff; padding: 8px 16px; box-shadow: 0 3px 0 var(--line); }
.world-chip:hover { transform: translateY(-1px); }
.world-chip[aria-pressed="true"] { background: var(--sun); box-shadow: 0 3px 0 #e0b21c; }
.world-card { text-align: center; max-width: 62ch; margin: 14px auto 0; min-height: 3.2em; }
.world-card strong { font-family: var(--head); font-size: 1.15rem; }
.world button:focus-visible, .world-canvas:focus-visible { outline: 3px solid var(--sky-deep); outline-offset: 2px; }
.world-off .world-bar, .world-off .world-card, .world:not(.world-on) .world-bar, .world:not(.world-on) .world-card { visibility: hidden; }
.world-full { background: #10182e; display: flex; flex-direction: column; padding: 10px; }
.world-full .world-stage { flex: 1; aspect-ratio: auto; border: 0; border-radius: 16px; }
.world-full .world-canvas { touch-action: none; }
.world-full .world-bar { margin-top: 10px; }
.world-full .world-card { color: #fff; min-height: 0; margin-top: 8px; }
.world-full .world-card .link { color: var(--sun); }
@media (max-width: 720px) {
  .world-stage { aspect-ratio: 4 / 3.4; border-radius: 22px; }
  .world-seasons button { padding: 5px 9px; font-size: .85rem; }
  .world-seasons { top: 8px; left: 8px; } .world-tools { right: 8px; bottom: 8px; } .world-hint { left: 8px; bottom: 8px; }
  .world-tools button { width: 38px; height: 38px; }
  .world-chip { padding: 6px 12px; font-size: .9rem; }
}

/* a line break that only happens on phones (the hero label breaks after "songs", not before the last "5") */
.br-m { display: none; }
@media (max-width: 520px) { .br-m { display: inline; } .hero-text .eyebrow { border-radius: 22px; padding: 6px 20px; line-height: 1.35; } }
