@font-face { font-family: Fredoka; src: url(fonts/fredoka-500.woff2) format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: Fredoka; src: url(fonts/fredoka-600.woff2) format('woff2'); font-weight: 600; font-display: swap; }
@font-face { font-family: Fredoka; src: url(fonts/fredoka-700.woff2) format('woff2'); font-weight: 700; font-display: swap; }

:root {
  --paper: #f6f1e7;
  --card: #fffdf8;
  --ink: #2a2238;
  --muted: #6e6779;
  --line: #e4dccd;
  --accent: #5b3fd1;
  --display: Fredoka, ui-rounded, 'Segoe UI', system-ui, sans-serif;
  --text: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

/* Modo escuro: a classe .dark no <html> vem do script do <head> (preferência salva ou a do sistema). */
html.dark {
  --paper: #16131d;
  --card: #201b2a;
  --ink: #f1ecf7;
  --muted: #a8a0b5;
  --line: #352f42;
  --accent: #a593ff;
  color-scheme: dark;
}
html.dark .more { color: color-mix(in srgb, var(--c) 55%, #fff); }
html.dark .features li::before { background: color-mix(in srgb, var(--c) 70%, #fff); }
html.dark .pill-play { background: rgb(52 168 83 / .2); color: #86e0a6; }
html.dark .pill-soon { background: rgb(251 188 4 / .18); color: #f3c95c; }
html.dark .pill-dev { background: rgb(165 147 255 / .2); color: #c3b6ff; }
html.dark .card:hover { box-shadow: 0 14px 30px rgb(0 0 0 / .45); }
html.dark .icon { box-shadow: 0 2px 10px rgb(0 0 0 / .5); }

/* Idioma: o HTML traz os dois textos; mostra só o escolhido. */
html:not(.en) [lang='en'], html.en [lang='pt'] { display: none !important; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; transition: background-color .2s ease, color .2s ease; background: var(--paper); color: var(--ink); font: 16px/1.6 var(--text); }
a { color: inherit; }
img { max-width: 100%; display: block; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.15; margin: 0; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* topo */
.top { display: flex; align-items: center; justify-content: space-between; max-width: 1080px; margin: 0 auto; padding: 18px 20px; }
.brand { font-family: var(--display); font-weight: 700; font-size: 1.35rem; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.key { font-size: .7em; font-weight: 600; padding: 2px 9px 3px; border: 2px solid var(--ink); border-radius: 8px; box-shadow: 0 3px 0 var(--ink); line-height: 1.2; transform: translateY(-1px); }
.brand.small { font-size: 1rem; }
.controls { display: flex; align-items: center; gap: 10px; }
.theme { width: 38px; height: 38px; display: grid; place-items: center; border: 2px solid var(--line); border-radius: 50%; background: var(--card); color: var(--ink); cursor: pointer; padding: 0; }
.theme:hover { border-color: var(--muted); }
.theme svg { width: 18px; height: 18px; fill: currentColor; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.theme .moon { stroke: none; }
.theme .sun, html.dark .theme .moon { display: none; }
html.dark .theme .sun { display: block; }
.lang { display: flex; border: 2px solid var(--line); border-radius: 999px; padding: 3px; background: var(--card); }
.lang button { font: 600 .8rem var(--display); letter-spacing: .04em; border: 0; background: none; color: var(--muted); padding: 4px 11px; border-radius: 999px; cursor: pointer; }
html:not(.en) .lang [data-lang='pt'], html.en .lang [data-lang='en'] { background: var(--ink); color: var(--paper); }

/* hero */
.hero { padding: 40px 0 28px; }
.eyebrow { font: 600 .85rem var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin: 0 0 10px; }
.hero h1 { font-size: clamp(2.1rem, 6vw, 3.6rem); max-width: 18ch; letter-spacing: -.01em; }
.lead { font-size: 1.12rem; color: var(--muted); max-width: 58ch; margin: 16px 0 0; }
.hero-icons { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-icons .icon { width: 60px; height: 60px; }

/* ícones */
.icon { width: 56px; height: 56px; border-radius: 22%; flex: none; box-shadow: 0 2px 8px rgb(42 34 56 / .14); object-fit: cover; }
.icon.glyph { display: grid; place-items: center; background: var(--bg); color: var(--c); font-size: 34px; line-height: 1; }
.icon.big { width: 96px; height: 96px; }
.icon.big.glyph { font-size: 56px; }

/* seções e cartões */
.section { padding: 36px 20px 8px; }
.section h2 { font-size: 1.7rem; }
.section-lead { color: var(--muted); margin: 6px 0 0; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; margin-top: 22px; }
.card { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 22px; overflow: hidden; text-decoration: none; transition: transform .18s ease, box-shadow .18s ease; }
.card:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgb(42 34 56 / .12); }
.card:focus-visible { outline: 3px solid var(--c); outline-offset: 3px; }
.card-shot { height: 230px; background: var(--bg); overflow: hidden; display: flex; justify-content: center; border-bottom: 1px solid rgb(0 0 0 / .06); }
.card-shot img { width: 50%; height: auto; align-self: flex-start; margin-top: 26px; border-radius: 16px; box-shadow: 0 10px 30px rgb(0 0 0 / .22); transition: transform .3s ease; }
.card:hover .card-shot img { transform: translateY(-8px); }
.card.wide .card-shot img { width: 100%; height: 100%; margin: 0; border-radius: 0; box-shadow: none; object-fit: cover; }
.card.wide:hover .card-shot img { transform: scale(1.03); }
.card-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-head { display: flex; gap: 14px; align-items: center; }
.card h3 { font-size: 1.3rem; margin-bottom: 4px; }
.card p { margin: 0; color: var(--muted); flex: 1; }
.more { font: 600 .95rem var(--display); color: var(--c); }

/* selos */
.tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tag { display: inline-flex; align-items: center; gap: 4px; font: 600 .74rem var(--display); letter-spacing: .03em; padding: 1px 9px 1px 7px; border-radius: 999px; border: 1.5px solid var(--line); color: var(--muted); }
.tag svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.tag-web { border-color: color-mix(in srgb, #1a8fb8 45%, transparent); color: #157a9e; }
html.dark .tag-web { color: #6cc6e6; }
.pill { display: inline-block; font: 600 .74rem var(--display); letter-spacing: .03em; padding: 2px 10px; border-radius: 999px; }
.pill-play { background: #dcf3e4; color: #13693a; }
.pill-soon { background: #fdefc9; color: #8a5a00; }
.pill-dev { background: #ebe5fb; color: #5b3fd1; }

/* página do jogo */
.back { display: inline-block; margin: 8px 0 22px; font: 600 .95rem var(--display); color: var(--muted); text-decoration: none; }
.back:hover { color: var(--ink); }
.game-head { display: flex; gap: 20px; align-items: center; }
.game-head h1 { font-size: clamp(1.9rem, 5vw, 2.8rem); }
.meta { margin: 4px 0 8px; color: var(--muted); }
.game .lead { margin-top: 20px; color: var(--ink); }
.hint { color: var(--muted); font-style: italic; margin: 14px 0 0; }
.btn-play { border: 1px solid #8a8a8a; display: inline-flex; align-items: center; gap: 12px; margin-top: 20px; background: #000; color: #fff; text-decoration: none; padding: 9px 22px 9px 16px; border-radius: 12px; transition: transform .15s ease; }
.btn-play:hover { transform: translateY(-2px); }
.btn-play svg { width: 28px; height: 28px; }
.btn-play span { display: flex; flex-direction: column; line-height: 1.1; }
.btn-play small { font-size: .7rem; text-transform: uppercase; letter-spacing: .05em; }
.btn-play b { font: 600 1.25rem var(--display); }

.gallery-wrap { background: var(--bg); margin: 34px 0; padding: 26px 0; border-block: 1px solid rgb(0 0 0 / .06); }
.gallery { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 10px; scrollbar-width: thin; }
.shot { flex: none; scroll-snap-align: start; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 13px; overflow: hidden; box-shadow: 0 8px 24px rgb(0 0 0 / .22); }
.shot img { height: 340px; width: auto; }
.gallery.landscape .shot img { height: 260px; }
.note { color: var(--muted); font-size: .9rem; margin: 10px 0 0; }
.gallery-wrap .note { color: rgb(255 255 255 / .7); }

.cols { display: grid; grid-template-columns: 1fr 300px; gap: 40px; align-items: start; padding-bottom: 30px; }
.cols h2 { font-size: 1.45rem; margin-bottom: 8px; }
.features { padding: 0; list-style: none; margin: 18px 0 0; display: grid; gap: 10px; }
.features li { position: relative; padding-left: 28px; }
.features li::before { content: ''; position: absolute; left: 4px; top: .55em; width: 11px; height: 11px; border-radius: 50%; background: var(--c); }
.info { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 20px 22px; }
.info dl { margin: 0; display: grid; gap: 2px; }
.info dt { font: 600 .78rem var(--display); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-top: 10px; }
.info dt:first-child { margin-top: 0; }
.info dd { margin: 0; word-break: break-word; }
.privacy { display: block; margin-top: 18px; padding: 11px 14px; border-radius: 12px; background: var(--paper); font: 600 .95rem var(--display); text-decoration: none; text-align: center; }
.privacy:hover { background: var(--line); }

.lightbox { border: 0; padding: 0; background: none; max-width: 94vw; max-height: 92vh; }
.lightbox::backdrop { background: rgb(15 10 25 / .85); }
.lightbox img { max-width: 94vw; max-height: 92vh; border-radius: 14px; }
.lightbox .close { position: fixed; top: 14px; right: 18px; width: 44px; height: 44px; border-radius: 50%; border: 0; font-size: 28px; line-height: 1; cursor: pointer; background: #fff; color: var(--ink); }

/* rodapé */
.foot { margin-top: 56px; border-top: 1px solid var(--line); padding: 26px 0 40px; color: var(--muted); font-size: .92rem; }
.foot p { margin: 6px 0; }
.foot a { color: var(--ink); }
.foot .brand { color: var(--ink); }

@media (max-width: 760px) {
  .cols { grid-template-columns: 1fr; gap: 24px; }
  .shot img { height: 300px; }
  .gallery.landscape .shot img { height: 200px; }
  .game-head { gap: 16px; }
  .hero-icons { gap: 8px; }
  .hero-icons .icon { width: 48px; height: 48px; }
  .hero-icons .icon.glyph { font-size: 28px; }
  .icon.big { width: 76px; height: 76px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
