:root {
  --green: #4caf2a;
  --green-light: #6fd33f;
  --green-dark: #2f7a16;
  --yellow: #f6b71b;
  --yellow-dark: #d99405;
  --cream: #f3ead7;
  --cream-light: #fff8e8;
  --wood: #c89b5a;
  --wood-dark: #a87c3d;
  --ink: #2b2b2b;
  --shadow: 0 8px 24px rgba(60, 40, 10, .14);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: "Be Vietnam Pro", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  color: var(--ink);
  background: #ece3cf;
  line-height: 1.45;
  overflow-x: hidden;
}

h1, h2, .logo span, .btn-main { font-family: "Baloo 2", "Be Vietnam Pro", sans-serif; }

/* ---------- AMBIENT FLIES ---------- */
.ambient { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.amb-fly {
  position: absolute; font-size: 22px; opacity: .35;
  filter: drop-shadow(0 2px 2px rgba(0,0,0,.2));
  animation: drift 22s linear infinite;
}
.amb-fly.f1 { top: 12%; left: -5%; animation-duration: 26s; }
.amb-fly.f2 { top: 55%; left: -5%; font-size: 16px; animation-duration: 32s; animation-delay: -8s; }
.amb-fly.f3 { top: 78%; left: -5%; font-size: 26px; animation-duration: 20s; animation-delay: -14s; }

@keyframes drift {
  0%   { transform: translate(-10vw, 0) rotate(0deg); }
  25%  { transform: translate(30vw, -28px) rotate(12deg); }
  50%  { transform: translate(60vw, 18px) rotate(-8deg); }
  75%  { transform: translate(90vw, -22px) rotate(10deg); }
  100% { transform: translate(115vw, 0) rotate(0deg); }
}

/* ---------- HERO ---------- */
.hero {
  position: relative;
  padding: 48px 16px 72px;
  text-align: center;
  overflow: hidden;
  isolation: isolate;
}
.hero-bg {
  position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(120% 80% at 50% -10%, #f1e6c8 0%, #e3d2ac 55%, #d3c19c 100%);
}
.hero-bg::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    radial-gradient(circle at 18% 30%, rgba(255,255,255,.35) 0 1px, transparent 2px),
    radial-gradient(circle at 82% 22%, rgba(0,0,0,.05) 0 2px, transparent 3px),
    radial-gradient(circle at 68% 75%, rgba(0,0,0,.04) 0 3px, transparent 4px);
  background-size: 90px 90px, 140px 140px, 110px 110px;
  opacity: .7;
}

.hero-inner { position: relative; max-width: 760px; margin: 0 auto; }

/* logo */
.logo { line-height: .82; margin-bottom: 22px; }
.logo span { display: block; font-weight: 800; }
.logo-ban {
  font-size: clamp(52px, 13vw, 104px); color: #fff;
  -webkit-text-stroke: 3px #1a1a1a;
  text-shadow: 4px 5px 0 rgba(0,0,0,.28);
  transform: rotate(-2deg);
}
.logo-ruoi {
  position: relative; display: inline-block !important;
  font-size: clamp(72px, 18vw, 140px); color: var(--yellow);
  -webkit-text-stroke: 4px #1a1a1a;
  text-shadow: 5px 6px 0 rgba(0,0,0,.3);
}
.logo-splat {
  position: absolute; right: -28px; top: -6px; width: 54px; height: 54px;
  background:
    radial-gradient(circle at 50% 50%, #1a1a1a 32%, transparent 33%),
    conic-gradient(from 0deg, #1a1a1a 0 8%, transparent 8% 16%, #1a1a1a 16% 24%, transparent 24% 32%, #1a1a1a 32% 40%, transparent 40% 48%, #1a1a1a 48% 56%, transparent 56% 64%, #1a1a1a 64% 72%, transparent 72% 80%, #1a1a1a 80% 88%, transparent 88% 96%);
  -webkit-mask: radial-gradient(circle at 50% 50%, #000 60%, transparent 72%);
          mask: radial-gradient(circle at 50% 50%, #000 60%, transparent 72%);
  transform: rotate(8deg);
}
.logo-offline {
  display: inline-block !important; margin-top: 14px;
  font-size: clamp(16px, 4vw, 26px); letter-spacing: 4px; font-weight: 700;
  color: #fff; background: linear-gradient(#5a4632, #3c2f20);
  padding: 6px 26px; border-radius: 10px;
  box-shadow: 0 4px 0 rgba(0,0,0,.3), inset 0 1px 0 rgba(255,255,255,.15);
}

/* tagline */
.tagline {
  display: inline-block; font-weight: 700; letter-spacing: .5px; font-size: clamp(13px, 2.6vw, 16px);
  background: linear-gradient(var(--wood), var(--wood-dark)); color: #fff;
  padding: 12px 26px; border-radius: 14px; margin-bottom: 30px;
  box-shadow: 0 5px 0 rgba(0,0,0,.22), inset 0 1px 0 rgba(255,255,255,.25);
}
.tagline .dot { color: var(--yellow); margin: 0 4px; }

/* top feature cards */
.features-top {
  list-style: none; display: flex; flex-wrap: wrap; justify-content: center;
  gap: 16px; margin-bottom: 38px;
}
.features-top li {
  flex: 1 1 160px; max-width: 200px;
  background: var(--cream-light); border: 2px solid var(--wood);
  border-radius: 16px; padding: 18px 16px;
  font-size: 13px; font-weight: 700; line-height: 1.3;
  box-shadow: 0 5px 0 var(--wood-dark), var(--shadow);
  transition: transform .15s ease, box-shadow .15s ease;
}
.features-top li:hover { transform: translateY(-3px); box-shadow: 0 8px 0 var(--wood-dark), var(--shadow); }
.features-top strong { display: block; color: var(--ink); }
.features-top span { display: block; color: #7a6a4a; font-size: 11px; }
.features-top .ico {
  font-size: 34px; margin-bottom: 8px; line-height: 1;
  filter: drop-shadow(0 3px 3px rgba(0,0,0,.2));
}

/* decorative swatter */
.swatter { position: absolute; top: 30px; right: -10px; width: 130px; height: 280px; z-index: 1; pointer-events: none; transform: rotate(18deg); transform-origin: bottom center; animation: swat 4.5s ease-in-out infinite; }
.swatter-net {
  width: 110px; height: 130px; border-radius: 18px;
  background:
    repeating-linear-gradient(0deg, #2f7a16 0 3px, transparent 3px 16px),
    repeating-linear-gradient(90deg, #2f7a16 0 3px, transparent 3px 16px),
    var(--green);
  border: 6px solid var(--green-dark);
  box-shadow: 0 6px 14px rgba(0,0,0,.25);
}
.swatter-handle {
  width: 14px; height: 160px; margin: -4px auto 0;
  background: linear-gradient(90deg, var(--green-dark), var(--green-light), var(--green-dark));
  border-radius: 8px;
}
@keyframes swat {
  0%, 100% { transform: rotate(18deg); }
  50%      { transform: rotate(10deg); }
}

/* dead-fly mascot */
.mascot-dead { position: absolute; left: 18px; bottom: 18px; text-align: center; z-index: 1; opacity: .85; animation: bob 3s ease-in-out infinite; }
.mascot-dead span { font-size: 46px; display: block; filter: grayscale(.3) drop-shadow(0 3px 3px rgba(0,0,0,.25)); transform: rotate(180deg); }
.mascot-dead em { font-style: normal; font-weight: 800; font-size: 13px; color: #5a4632; letter-spacing: 2px; }
@keyframes bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }

/* ---------- DOWNLOAD BUTTON ---------- */
.btn-download {
  display: inline-flex; flex-direction: column; align-items: center;
  background: linear-gradient(var(--green-light), var(--green));
  color: #fff; text-decoration: none; font-weight: 800;
  padding: 16px 52px; border-radius: 16px; border: 3px solid var(--green-dark);
  box-shadow: 0 7px 0 var(--green-dark), 0 12px 24px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.3);
  transition: transform .1s ease, box-shadow .1s ease;
}
.btn-download .btn-main { font-size: clamp(22px, 5vw, 28px); }
.btn-download:hover { transform: translateY(2px); box-shadow: 0 5px 0 var(--green-dark), 0 9px 16px rgba(0,0,0,.26), inset 0 1px 0 rgba(255,255,255,.3); }
.btn-download:active { transform: translateY(7px); box-shadow: 0 0 0 var(--green-dark), inset 0 1px 0 rgba(255,255,255,.3); }
.btn-download small { font-size: 12px; font-weight: 600; opacity: .92; margin-top: 5px; letter-spacing: .5px; }
.btn-hero { animation: pulse 2.4s ease-in-out infinite; }
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.035); }
}
.btn-hero:hover { animation: none; }

/* ---------- GAMEPLAY ---------- */
main { position: relative; z-index: 1; max-width: 900px; margin: 0 auto; padding: 0 16px; }

.gameplay {
  position: relative;
  background: var(--cream); border: 3px solid var(--wood); border-radius: 22px;
  padding: 32px 22px; margin: -36px auto 40px;
  box-shadow: 0 12px 30px rgba(0,0,0,.14);
}
.gameplay h2 { text-align: center; color: var(--green-dark); font-size: clamp(22px, 5vw, 30px); letter-spacing: .5px; }
.gameplay .sub { text-align: center; margin: 8px 0 26px; color: #6a6150; font-size: 15px; }

.screens { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 18px; }
.screen {
  border-radius: 14px; overflow: hidden;
  box-shadow: 0 6px 16px rgba(0,0,0,.2);
  border: 2px solid rgba(0,0,0,.06);
  transition: transform .15s ease;
}
.screen:hover { transform: translateY(-4px); }
.screen-bar {
  display: flex; justify-content: space-between; align-items: center;
  background: linear-gradient(#333, #222); color: #fff;
  font-size: 11px; font-weight: 700; padding: 8px 10px; letter-spacing: .3px;
}
.screen-bar i { font-style: normal; }
.screen-bar .score { color: var(--yellow); }
.screen-body {
  position: relative; height: 150px;
  display: flex; align-items: center; justify-content: center;
  gap: 14px; flex-wrap: wrap; padding: 12px;
}
.screen-body .fly {
  font-size: 28px; filter: drop-shadow(0 3px 3px rgba(0,0,0,.25));
  animation: buzz 1.6s ease-in-out infinite;
}
.screen-body .fly:nth-child(2) { animation-delay: -.4s; }
.screen-body .fly:nth-child(3) { animation-delay: -.8s; }
.screen-body .fly:nth-child(4) { animation-delay: -1.2s; }
@keyframes buzz {
  0%, 100% { transform: translate(0,0) rotate(0); }
  25%      { transform: translate(3px,-4px) rotate(6deg); }
  50%      { transform: translate(-2px,3px) rotate(-5deg); }
  75%      { transform: translate(4px,2px) rotate(4deg); }
}
.screen-body .splat {
  width: 34px; height: 34px; border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, #1a1a1a 30%, transparent 31%),
    conic-gradient(from 10deg, #1a1a1a 0 7%, transparent 7% 14%, #1a1a1a 14% 21%, transparent 21% 28%, #1a1a1a 28% 35%, transparent 35% 42%, #1a1a1a 42% 49%, transparent 49% 56%, #1a1a1a 56% 63%, transparent 63% 70%, #1a1a1a 70% 77%, transparent 77% 84%, #1a1a1a 84% 91%, transparent 91% 98%);
  -webkit-mask: radial-gradient(circle at 50% 50%, #000 58%, transparent 70%);
          mask: radial-gradient(circle at 50% 50%, #000 58%, transparent 70%);
  opacity: .85;
}
.screen-body .splat.small { width: 22px; height: 22px; }
.s1 { background: radial-gradient(120% 100% at 30% 0%, #efe6cd, #ddd0aa); }
.s2 { background: radial-gradient(120% 100% at 30% 0%, #e3d4ab, #cdb985); }
.s3 { background: radial-gradient(120% 100% at 30% 0%, #d8e8ee, #b9d3dc); }

/* bottom feature cards */
.features-bottom { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; margin-top: 30px; }
.features-bottom > li {
  display: flex; gap: 14px; background: var(--cream-light);
  border: 2px solid #e0cfa3; border-radius: 16px; padding: 18px;
  box-shadow: 0 4px 0 #d8c499;
}
.features-bottom .ico { font-size: 34px; line-height: 1; filter: drop-shadow(0 3px 3px rgba(0,0,0,.18)); }
.features-bottom strong { display: block; color: var(--green-dark); font-size: 16px; margin-bottom: 4px; }
.features-bottom ul { margin: 4px 0 0 18px; font-size: 14px; color: #5a5240; }
.features-bottom ul li { margin: 2px 0; }
.features-bottom p { font-size: 14px; color: #5a5240; }

/* ---------- CTA ---------- */
.cta { position: relative; text-align: center; padding: 16px 0 56px; }
.cta-badges {
  list-style: none; display: flex; flex-wrap: wrap; justify-content: center;
  gap: 22px; margin: 24px 0 16px; font-size: 13px; font-weight: 700; color: #5a5240;
}

/* sticky note */
.sticky-note {
  position: relative; display: inline-block; margin-top: 22px;
  background: #fff3a8; padding: 24px 26px 22px;
  font-family: "Baloo 2", cursive; font-weight: 700; color: #3a2f12;
  line-height: 1.35; font-size: 18px;
  box-shadow: 3px 5px 14px rgba(0,0,0,.2);
  transform: rotate(-3deg);
  background-image: linear-gradient(#fff3a8, #ffe974);
}
.sticky-note::after {
  content: ""; position: absolute; right: 0; bottom: 0;
  border-width: 0 22px 22px 0; border-style: solid;
  border-color: transparent #e9d24f transparent transparent;
}
.sticky-note .pin {
  position: absolute; top: -10px; left: 50%; width: 18px; height: 18px;
  transform: translateX(-50%); border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #ff7a7a, #d62828);
  box-shadow: 0 3px 5px rgba(0,0,0,.35);
}

footer { position: relative; z-index: 1; text-align: center; padding: 24px 16px; font-size: 12px; color: #7a6f59; }

/* ---------- RESPONSIVE ---------- */
/* tablet */
@media (max-width: 720px) {
  .swatter { width: 96px; top: 14px; right: -18px; transform: rotate(22deg) scale(.85); }
  .swatter-net { width: 80px; height: 96px; }
  .swatter-handle { height: 120px; }
  .mascot-dead span { font-size: 38px; }
}

/* phone */
@media (max-width: 520px) {
  .hero { padding: 36px 14px 60px; }
  .logo-ban { -webkit-text-stroke-width: 2px; transform: rotate(-1deg); }
  .logo-ruoi { -webkit-text-stroke-width: 3px; }
  .logo-splat { right: -18px; width: 38px; height: 38px; }
  .tagline {
    max-width: 100%; padding: 11px 16px; font-size: 13px;
    line-height: 1.5; word-spacing: 1px;
  }
  .tagline .dot { display: inline; }
  .features-top { gap: 12px; }
  .features-top li { flex-basis: calc(50% - 6px); max-width: none; padding: 14px 10px; }
  .swatter { opacity: .5; right: -28px; }
  .mascot-dead { opacity: .7; left: 8px; bottom: 10px; }
  .gameplay { padding: 26px 16px; margin-top: -28px; }
  .screen-body { height: 130px; }
  .cta-badges { gap: 16px; }
}

/* very small */
@media (max-width: 360px) {
  .features-top li { flex-basis: 100%; }
}

/* desktop — give the hero more breathing room and pin props wider */
@media (min-width: 1024px) {
  .hero { padding: 64px 16px 88px; }
  .swatter { right: 4%; top: 40px; }
  .mascot-dead { left: 6%; bottom: 32px; }
}

/* respect reduced-motion */
@media (prefers-reduced-motion: reduce) {
  .amb-fly, .swatter, .mascot-dead, .btn-hero, .screen-body .fly { animation: none; }
}
