/* Pé de Pixel — terra, broto e papel. Contorno marrom grosso + sombra "pixel" sólida, como a logo. */
@font-face { font-family: 'Fredoka'; src: url(/fonts/fredoka.woff2) format('woff2'); font-weight: 300 700; font-display: swap; }
@font-face { font-family: 'Nunito'; src: url(/fonts/nunito.woff2) format('woff2'); font-weight: 200 1000; font-display: swap; }

:root {
  --paper: #fbf1d9;
  --paper-2: #f4e2b8;
  --card: #fffaf0;
  --ink: #4a2c17;
  --ink-soft: #7a5638;
  --line: #3b2212;
  --dirt: #9c5a32;
  --dirt-dark: #6e3b1e;
  --leaf: #6cc04a;
  --leaf-dark: #3f8a26;
  --leaf-light: #a7e07f;
  --sun: #ffc94a;
  --r: 18px;
  --shadow: 0 6px 0 var(--line);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --paper: #2a1b10; --paper-2: #342214; --card: #3b2717; --ink: #fbecd2; --ink-soft: #d8bf9c; --line: #120a04;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--paper) radial-gradient(circle at 1px 1px, rgba(110, 59, 30, 0.08) 1px, transparent 0) 0 0 / 22px 22px;
  color: var(--ink); font: 600 17px/1.55 'Nunito', system-ui, sans-serif;
}
h1, h2, h3, .btn, .brand span, .playbtn { font-family: 'Fredoka', 'Nunito', sans-serif; font-weight: 700; letter-spacing: 0.01em; }
a { color: var(--leaf-dark); }
img { max-width: 100%; height: auto; }
.wrap { width: min(1180px, 100%); margin: 0 auto; padding: 0 16px 40px; flex: 1; }
.wrap.narrow { width: min(820px, 100%); padding-top: 28px; }

/* ---------- topo: faixa de terra com grama em degraus ---------- */
.top {
  position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 16px 14px; background: var(--dirt);
  box-shadow: inset 0 -6px 0 var(--dirt-dark);
}
.top::before { /* grama pixelada no topo */
  content: ''; position: absolute; inset: 0 0 auto; height: 8px;
  background: linear-gradient(90deg, var(--leaf) 50%, var(--leaf-dark) 0) 0 0 / 16px 8px;
}
.top::after { /* dentes da grama */
  content: ''; position: absolute; left: 0; right: 0; top: 8px; height: 6px;
  background: linear-gradient(90deg, var(--leaf-dark) 25%, transparent 0 50%, var(--leaf) 0 62%, transparent 0) 0 0 / 32px 6px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: #fff7e8; margin-top: 6px; }
.brand img { filter: drop-shadow(0 3px 0 rgba(0, 0, 0, 0.35)); }
.brand span { font-size: 26px; text-shadow: 0 3px 0 var(--line); }
.langs { display: flex; gap: 6px; margin-top: 6px; }
.langs a {
  color: #fff7e8; text-decoration: none; font: 800 13px 'Nunito', sans-serif; padding: 5px 9px; border-radius: 10px;
  border: 2px solid rgba(255, 255, 255, 0.25);
}
.langs a[aria-current] { background: var(--leaf); border-color: var(--line); box-shadow: 0 3px 0 var(--line); }

/* ---------- botões ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 20px; border-radius: 14px;
  background: var(--leaf); color: #fff; text-decoration: none; font-size: 18px;
  border: 3px solid var(--line); box-shadow: 0 5px 0 var(--line), inset 0 -4px 0 var(--leaf-dark);
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.25); transition: transform 0.1s, box-shadow 0.1s;
}
.btn.big { font-size: 22px; padding: 12px 26px; }

/* ---------- hero ---------- */
.hero { position: relative; width: min(1180px, 100%); margin: 20px auto 8px; padding: 0 16px; }
.hero-art {
  display: block; width: 100%; aspect-ratio: 16 / 7; object-fit: cover; object-position: 30% 55%;
  border: 4px solid var(--line); border-radius: 26px; box-shadow: 0 8px 0 var(--line);
}
.hero-txt {
  position: absolute; right: 44px; bottom: 34px; max-width: 440px; padding: 18px 22px 22px;
  background: var(--card); border: 3px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow);
}
.hero-txt h1 { margin: 0 0 4px; font-size: clamp(26px, 3.4vw, 38px); line-height: 1.1; color: var(--ink); }
.hero-txt p { margin: 0 0 14px; color: var(--ink-soft); }

.sec { font-size: 28px; margin: 34px 0 16px; display: flex; align-items: center; gap: 10px; }
.sec::before { content: ''; width: 22px; height: 22px; background: var(--leaf); border: 3px solid var(--line); border-radius: 6px 14px; transform: rotate(-12deg); }

/* ---------- cards de jogo ---------- */
.grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }
.card {
  display: flex; flex-direction: column; text-decoration: none; color: inherit; background: var(--card);
  border: 3px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden;
  transition: transform 0.15s, box-shadow 0.15s;
}
.card.big { grid-column: 1 / -1; flex-direction: row; }
.card.big .thumb { flex: 1.5; }
.card.big .body { flex: 1; justify-content: center; padding: 24px 26px; }
.card.big h3 { font-size: 34px; }
.thumb { position: relative; border-bottom: 3px solid var(--line); background: var(--paper-2); }
.card.big .thumb { border-bottom: 0; border-right: 3px solid var(--line); }
.thumb img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.pv { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 0.3s; pointer-events: none; }
.pv.on { opacity: 1; }
.badge {
  position: absolute; top: 12px; left: 12px; font: 800 13px 'Nunito', sans-serif; font-style: normal; color: var(--line);
  background: var(--sun); padding: 3px 10px; border: 2px solid var(--line); border-radius: 999px; transform: rotate(-4deg);
}
.beta {
  font: 800 12px 'Nunito', sans-serif; font-style: normal; letter-spacing: 1px; color: #fff7e8; vertical-align: middle;
  background: #e0542f; padding: 3px 9px; border: 2px solid var(--line); border-radius: 6px; box-shadow: 0 2px 0 var(--line);
}
.thumb .beta { position: absolute; top: 12px; right: 12px; transform: rotate(4deg); }
.bar h1 .beta { text-shadow: none; font-size: 11px; margin-left: 6px; }
.body { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px 18px; flex: 1; }
.body h3 { margin: 0; font-size: 24px; line-height: 1.15; }
.body p { margin: 0; color: var(--ink-soft); font-size: 15.5px; flex: 1; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 10px; }
.tags span { font-size: 12.5px; font-weight: 800; padding: 2px 9px; border-radius: 999px; background: var(--paper-2); border: 2px solid rgba(59, 34, 18, 0.25); }
.body .btn { align-self: flex-start; }
.support { background: var(--paper-2); border: 2px dashed rgba(59, 34, 18, 0.35); border-radius: 12px; padding: 4px 14px 14px; margin-bottom: 8px; }
.support h2 { margin-top: 10px; }
.support p { margin: 0 0 10px; color: var(--ink-soft); }
.support .btn { background: #fa5c5c; }
.support .btn:hover { background: #ff7676; }

@media (hover: hover) {
  .card:hover, .card:focus-visible { transform: translateY(-4px) rotate(-0.4deg); box-shadow: 0 10px 0 var(--line); outline: none; }
  .btn:hover, .card:hover .btn { background: #7fd35a; }
  .btn:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--line), inset 0 -4px 0 var(--leaf-dark); }
}

/* ---------- página do jogo ---------- */
.crumbs { margin: 18px 0 12px; }
.crumbs a { font-weight: 800; text-decoration: none; }
.player { background: var(--line); border: 4px solid var(--line); border-radius: 22px; box-shadow: 0 8px 0 rgba(59, 34, 18, 0.5); overflow: hidden; }
.stage { position: relative; aspect-ratio: var(--ar, 16 / 9); max-height: min(78vh, 720px); width: 100%; margin: 0 auto; background: #000; }
.stage > .pv.on { filter: brightness(0.85); }
.stage > img { width: 100%; height: 100%; object-fit: cover; filter: saturate(1.05) brightness(0.8); }
.stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.stage:fullscreen { max-height: none; aspect-ratio: auto; }
.playbtn {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-size: 30px; color: #fff; cursor: pointer; padding: 16px 40px 18px; border-radius: 22px;
  background: var(--leaf); border: 4px solid var(--line); box-shadow: 0 8px 0 var(--line), inset 0 -6px 0 var(--leaf-dark);
  text-shadow: 0 3px 0 rgba(0, 0, 0, 0.3); animation: bob 1.8s ease-in-out infinite;
}
.playbtn span { font-size: 44px; line-height: 1; }
.playbtn small { font: 700 13px 'Nunito', sans-serif; opacity: 0.9; text-shadow: none; }
.playbtn:hover { background: #7fd35a; }
@keyframes bob { 50% { transform: translate(-50%, calc(-50% - 6px)); } }
@media (prefers-reduced-motion: reduce) { .playbtn { animation: none; } }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; background: var(--dirt); }
.bar h1 { margin: 0; font-size: 24px; color: #fff7e8; text-shadow: 0 2px 0 var(--line); }
.bar button {
  font: 800 14px 'Nunito', sans-serif; color: var(--line); background: var(--sun); border: 2px solid var(--line);
  border-radius: 10px; padding: 6px 12px; cursor: pointer; box-shadow: 0 3px 0 var(--line);
}

.info { display: grid; grid-template-columns: 1.6fr 1fr; gap: 22px; margin-top: 26px; align-items: start; }
.panel { background: var(--card); border: 3px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 6px 22px 18px; }
.panel h1 { font-size: 34px; margin: 14px 0 6px; }
.panel h2 { font-size: 22px; margin: 18px 0 8px; color: var(--dirt-dark); }
.panel p { margin: 0 0 12px; }
.feat { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.feat li { position: relative; padding-left: 28px; }
.feat li::before { content: ''; position: absolute; left: 0; top: 6px; width: 16px; height: 13px; background: var(--leaf); border: 2px solid var(--line); border-radius: 2px 10px; }
.keys { display: grid; grid-template-columns: auto 1fr; gap: 8px 12px; margin: 0; }
.keys dt { font: 800 13.5px 'Nunito', sans-serif; padding: 2px 8px; background: var(--paper-2); border: 2px solid var(--line); border-radius: 8px; box-shadow: 0 2px 0 var(--line); white-space: nowrap; align-self: start; justify-self: start; }
.keys dd { margin: 0; }
details { border-top: 2px dashed rgba(59, 34, 18, 0.25); padding: 8px 0; }
summary { cursor: pointer; font-weight: 800; }
details p { margin: 6px 0 0; color: var(--ink-soft); }

.ad { margin: 22px auto 0; text-align: center; }
.ad small { display: block; font-size: 11px; color: var(--ink-soft); text-transform: uppercase; letter-spacing: 0.1em; }

.nf { text-align: center; }
.nf .grid { text-align: left; margin-top: 24px; }

/* ---------- rodapé ---------- */
.foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; padding: 22px 16px 26px;
  margin-top: 30px; background: var(--dirt-dark); color: #f6e3c6; font-size: 15px; border-top: 4px solid var(--line);
}
.foot a { color: var(--leaf-light); font-weight: 800; }

/* ---------- celular ---------- */
@media (max-width: 760px) {
  body { font-size: 16px; }
  .brand span { font-size: 21px; }
  .brand img { width: 34px; height: 34px; }
  .hero { margin-top: 14px; }
  .hero-art { aspect-ratio: 16 / 10; border-radius: 20px 20px 0 0; box-shadow: none; border-bottom: 0; object-position: 20% 50%; }
  .hero-txt { position: static; max-width: none; border-radius: 0 0 20px 20px; box-shadow: 0 6px 0 var(--line); }
  .card.big { flex-direction: column; }
  .card.big .thumb { border-right: 0; border-bottom: 3px solid var(--line); }
  .card.big .body { padding: 14px 16px 18px; }
  .card.big h3 { font-size: 26px; }
  .grid { grid-template-columns: 1fr; }
  .info { grid-template-columns: 1fr; }
  .playbtn { font-size: 24px; padding: 12px 28px 14px; }
  .playbtn span { font-size: 34px; }
  .bar h1 { font-size: 20px; }
}
