/* Mr. Giggles Adventures - refreshed stylesheet (preview). Palette unchanged from the original style.css. */
:root {
  --primary-green: #006400;   /* original */
  --accent-green: #c4e07c;    /* original */
  --contrast-brown: #332200;  /* original */
  --highlight-yellow: #ffd700;/* original */
  --calm-blue: #add8e6;       /* original */
  --rust: #8b3103;            /* original .rust-colored */
  --saddle: #8b4513;          /* original */
  --cream: #ffe0b2;           /* original */
  --card: rgba(255, 255, 255, 0.92);
  --radius: 18px;
  --shadow: 0 6px 18px rgba(51, 34, 0, 0.18);
  --font-display: "Fredoka", "Baloo 2", "Comic Sans MS", system-ui, sans-serif;
  --font-body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--font-body); font-size: 1.05rem; line-height: 1.6;
  color: var(--contrast-brown); background-color: var(--primary-green);
  background-image: url("images/Mr%20Giggles%20Farm.png");
  background-size: cover; background-position: center; background-attachment: fixed;
}
img { max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
a { color: var(--primary-green); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--highlight-yellow); outline-offset: 3px; }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--highlight-yellow); color: var(--contrast-brown); padding: .5rem 1rem; z-index: 100; border-radius: 0 0 8px 0; }
.skip-link:focus { left: 0; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--primary-green);
  background-image: linear-gradient(49deg, transparent 52%, rgba(255,255,255,.18) 40%, rgba(255,255,255,0) 100%);
  color: #fff; box-shadow: 0 3px 12px rgba(0,0,0,.25);
}
.site-header.trees { background-image: linear-gradient(rgba(0,100,0,.75), rgba(0,100,0,.75)), url("images/Gemini_Generated_Image_t8t09it8t09it8t0.jpg"); background-size: cover; background-position: center; }
.header-bar { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; gap: 1rem; padding: .6rem 1rem; }
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: #fff; }
.brand img { width: 64px; height: 64px; border-radius: 14px; object-fit: contain; border: 3px solid var(--highlight-yellow); background: #fff; }
.brand-name { font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; line-height: 1.05; display: block; }
.brand-sub { font-family: var(--font-display); font-size: 1rem; color: var(--accent-green); display: block; }
.header-pic { margin-left: auto; width: 64px; height: 64px; border-radius: 50%; object-fit: cover; border: 3px solid var(--accent-green); }
.menu-toggle { display: none; margin-left: auto; background: var(--highlight-yellow); color: var(--contrast-brown); border: 0; border-radius: 12px; padding: .55rem .8rem; font: 700 1rem var(--font-display); cursor: pointer; }
.menu-toggle .bars { display: inline-block; width: 22px; height: 3px; background: currentColor; position: relative; vertical-align: middle; margin-right: .4rem; border-radius: 2px; }
.menu-toggle .bars::before, .menu-toggle .bars::after { content: ""; position: absolute; left: 0; width: 22px; height: 3px; background: currentColor; border-radius: 2px; }
.menu-toggle .bars::before { top: -7px; } .menu-toggle .bars::after { top: 7px; }

/* ---------- Picture-button nav (original buttons kept) ---------- */
.site-nav { background: rgba(0, 70, 0, .55); }
.site-nav ul { list-style: none; margin: 0 auto; padding: .5rem 1rem .75rem; max-width: 1200px; display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem; }
.site-nav a { display: flex; flex-direction: column; align-items: center; gap: .25rem; width: 86px; padding: .35rem .25rem; border-radius: 14px; text-decoration: none;
  color: var(--contrast-brown); background: rgba(255,255,255,.85); font: 700 .72rem/1.1 var(--font-display); letter-spacing: .02em; text-align: center; transition: transform .15s, background .15s; }
.site-nav a img { width: 56px; height: 56px; object-fit: cover; border-radius: 12px; }
.site-nav a:hover { background: var(--accent-green); transform: translateY(-3px); }
.site-nav a[aria-current="page"] { background: var(--accent-green); box-shadow: 0 0 0 3px var(--highlight-yellow); }

/* ---------- Main + cards ---------- */
main { max-width: 1100px; margin: 1.5rem auto 2rem; padding: 0 1rem; }
.panel { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(1rem, 3vw, 2rem); margin-bottom: 1.5rem; }
.panel.green { background: var(--primary-green); color: #fff; }
.panel.green a { color: var(--highlight-yellow); }
.panel h1, .panel h2 { color: var(--primary-green); }
.panel.green h1, .panel.green h2, .panel.green h3 { color: #fff; }
.panel h3 { color: var(--rust); }
.lead { font-size: 1.15rem; }
.split { display: grid; grid-template-columns: minmax(180px, 1fr) 2fr; gap: 1.5rem; align-items: start; }
.split img { border-radius: var(--radius); }
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 1rem; margin: 1rem 0; }
.card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; border: 3px solid var(--accent-green); transition: transform .15s; }
.card:hover { transform: translateY(-4px); }
.card img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; display: block; background: var(--cream); }
.card .card-body { padding: .75rem .9rem 1rem; }
.card .card-title { font: 700 1.05rem var(--font-display); color: var(--primary-green); margin: 0 0 .25rem; }
.card .price { display: inline-block; background: var(--highlight-yellow); color: var(--contrast-brown); font-weight: 800; border-radius: 999px; padding: .1rem .7rem; margin: .25rem 0 0; }
.card p { margin: .25rem 0; }
.card a.card-link { text-decoration: none; color: inherit; display: flex; flex-direction: column; height: 100%; }
.series-head { display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; margin-top: 1.5rem; }
.badge { background: var(--accent-green); color: var(--contrast-brown); border-radius: 999px; padding: .1rem .7rem; font-weight: 800; font-size: .85rem; }
.three-col { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.btn { display: inline-block; background: var(--highlight-yellow); color: var(--contrast-brown); font: 700 1.1rem var(--font-display); padding: .7rem 1.4rem; border-radius: 999px; text-decoration: none; box-shadow: var(--shadow); border: 0; cursor: pointer; }
.btn:hover { background: var(--accent-green); }
form.stack { display: grid; gap: .6rem; max-width: 460px; }
form.stack input { padding: .6rem .8rem; border-radius: 10px; border: 2px solid var(--accent-green); font: inherit; }
.embed { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; margin: 1rem 0; }
.embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.hero { text-align: center; padding: 2rem 1rem; }
.hero-circle { display: inline-flex; flex-direction: column; align-items: center; gap: .5rem; background: rgba(255,255,255,.88); border-radius: 50%; width: min(520px, 88vw); aspect-ratio: 1; justify-content: center; padding: 3rem; box-shadow: var(--shadow); text-decoration: none; border: 6px solid var(--accent-green); }
.hero-circle .up { font: 700 clamp(1.15rem, 3vw, 2rem) var(--font-display); color: var(--primary-green); margin: 0; max-width: 80%; text-align: center; }
.hero-circle img { width: 62%; }
.hero-circle .down { font: 700 clamp(1.1rem, 3vw, 1.8rem) var(--font-display); color: var(--primary-green); }
.song-grid .card img { aspect-ratio: 1; }
canvas#gameCanvas { display: block; margin: 1rem auto; max-width: 100%; height: auto; border-radius: var(--radius); border: 4px solid var(--saddle); background: var(--cream); }

/* ---------- Footer ---------- */
.site-footer { background: var(--primary-green); color: #fff; text-align: center; padding: 1.5rem 1rem; }
.footer-inner { max-width: 1100px; margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1.5rem; }
.site-footer a { color: #fff; font-weight: 700; text-decoration: none; display: inline-flex; align-items: center; gap: .5rem; background: rgba(255,255,255,.12); padding: .4rem .8rem; border-radius: 999px; }
.site-footer a:hover { background: rgba(255,255,255,.25); }
.site-footer img.thanks-img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.site-footer img.qr { width: 84px; height: 84px; background: #fff; border-radius: 10px; padding: 4px; }
.site-footer small { display: block; width: 100%; opacity: .9; }

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .three-col, .split { grid-template-columns: 1fr; }
  .header-pic { display: none; }
  .menu-toggle { display: inline-block; }
  .site-nav { display: none; }
  .site-nav.open { display: block; }
  .site-nav ul { justify-content: flex-start; display: grid; grid-template-columns: repeat(3, 1fr); }
  .site-nav a { width: auto; }
  .brand img { width: 52px; height: 52px; }
  .brand-name { font-size: 1.2rem; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  body { background-attachment: scroll; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }

/* v7: donate panel + notices + game controls */
.donate-panel { text-align: center; }
.donate-panel > div { max-width: 420px; margin: 0 auto; }
.notice { background: #fff8d6; border-left: 6px solid var(--accent-green); padding: .8rem 1rem; border-radius: var(--radius); }
.game-controls { display: grid; grid-template-columns: repeat(3, 64px); gap: .4rem; justify-content: center; margin: .5rem auto; }
.game-controls button { font-size: 1.6rem; height: 56px; }
.game-status { text-align: center; font-weight: 800; min-height: 1.5em; }
