/* why: a identidade vem do logo (contorno marinho grosso, sombra seca embaixo, ouro e laranja nos destaques); sprites sempre em pixel puro */
:root {
  --bg: #eef6ff;
  --bg-2: #dfeeff;
  --surface: #ffffff;
  --surface-2: #f6faff;
  --ink: #14213d;
  --muted: #4d5e80;
  --line: #cfe0f5;
  --navy: #12214a;
  --gold: #ffb81c;
  --gold-2: #ff9d0a;
  --orange: #f2780c;
  --red: #d62d2d;
  --blue: #2f86eb;
  --green: #2e9a45;
  --cream: #fff6dc;
  --shadow: rgba(18, 33, 74, .22);
  --nav-bg: rgba(238, 246, 255, .9);
  --radius: 14px;
  --display: 'Teko', 'Impact', 'Arial Narrow', sans-serif;
  --body: 'Nunito', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0a1330; --bg-2: #0f1c44; --surface: #121f4a; --surface-2: #17275a; --ink: #eef3ff; --muted: #a9b8dc; --line: #26397a;
    --navy: #050b1f; --cream: #2a2340; --shadow: rgba(0, 0, 0, .5); --nav-bg: rgba(10, 19, 48, .9); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0a1330; --bg-2: #0f1c44; --surface: #121f4a; --surface-2: #17275a; --ink: #eef3ff; --muted: #a9b8dc; --line: #26397a;
  --navy: #050b1f; --cream: #2a2340; --shadow: rgba(0, 0, 0, .5); --nav-bg: rgba(10, 19, 48, .9); color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.02rem/1.65 var(--body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; }
.px { image-rendering: pixelated; image-rendering: crisp-edges; }
a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--orange); }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 600; line-height: 1.05; letter-spacing: .01em; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(2.6rem, 6vw, 4.4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: 1.7rem; }
p { margin: 0 0 1em; }
.wrap { width: min(1160px, 100% - 2rem); margin-inline: auto; }
.narrow { width: min(820px, 100% - 2rem); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--gold); color: var(--navy); padding: .5rem 1rem; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--gold-2); outline-offset: 2px; border-radius: 6px; }
mark.todo { background: #ffe27a; color: #5a3b00; padding: 0 .35em; border-radius: 4px; font-weight: 700; }

.site-header { position: sticky; top: 0; z-index: 50; background: var(--nav-bg); backdrop-filter: blur(10px); border-bottom: 3px solid var(--navy); }
.nav { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; column-gap: 1.2rem; min-height: 104px; }
.brand { grid-column: 2; grid-row: 1; display: flex; align-items: center; text-decoration: none; }
.brand img { height: 88px; width: auto; filter: drop-shadow(0 3px 0 var(--shadow)); transition: transform .15s; }
.brand:hover img { transform: scale(1.04) rotate(-1deg); }
.nav-menu { display: contents; }
.nav-left { grid-column: 1; grid-row: 1; justify-self: end; }
.nav-right { grid-column: 3; grid-row: 1; justify-self: start; display: flex; align-items: center; gap: .6rem; }
.nav-links { display: flex; align-items: center; gap: .15rem; list-style: none; margin: 0; padding: 0; }
.nav-links a { display: block; padding: .5rem .8rem; border-radius: 10px; color: var(--ink); text-decoration: none; font: 600 1.35rem/1 var(--display); letter-spacing: .03em; text-transform: uppercase; white-space: nowrap; }
.nav-links a:hover, .nav-links a[aria-current="page"] { background: var(--bg-2); color: var(--orange); }
.lang { display: flex; gap: .15rem; margin-left: .2rem; }
.lang a { padding: .2rem .45rem; border-radius: 8px; border: 2px solid transparent; color: var(--muted); text-decoration: none; font: 800 .78rem/1 var(--body); }
.lang a:hover { color: var(--orange); }
.lang a[aria-current="true"] { background: var(--gold); color: var(--navy); border-color: var(--navy); }
.nav-toggle { display: none; }
.burger { display: none; width: 46px; height: 46px; border: 3px solid var(--navy); border-radius: 12px; background: var(--surface); cursor: pointer; align-items: center; justify-content: center; box-shadow: 0 3px 0 var(--navy); }
.burger span, .burger span::before, .burger span::after { display: block; width: 20px; height: 3px; background: var(--navy); border-radius: 2px; content: ''; position: relative; }
.burger span::before { position: absolute; top: -7px; } .burger span::after { position: absolute; top: 7px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .burger span, :root:not([data-theme="light"]) .burger span::before, :root:not([data-theme="light"]) .burger span::after { background: var(--ink); } :root:not([data-theme="light"]) .burger { border-color: var(--line); box-shadow: 0 3px 0 var(--line); } }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; padding: .7rem 1.5rem; border: 3px solid var(--navy); border-radius: 14px; font: 600 1.5rem/1 var(--display); letter-spacing: .04em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: transform .08s, box-shadow .08s; box-shadow: 0 5px 0 var(--navy); color: var(--navy); background: #fff; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 7px 0 var(--navy); color: var(--navy); }
.btn:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--navy); }
.btn-play { background: linear-gradient(#ffd24a, var(--gold-2)); }
.btn-sm { font-size: 1.2rem; padding: .45rem 1rem; box-shadow: 0 4px 0 var(--navy); }
.btn-ghost { background: #fff; }

.hero { position: relative; isolation: isolate; background: #4aa8ff; border-bottom: 3px solid var(--navy); }
.hero-art { display: block; width: 100%; height: auto; }
.cta-row { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; margin-top: 1.6rem; }
.lead { text-align: center; padding: clamp(2rem, 5vw, 3.5rem) 0 1rem; }
.lead h1 { margin-bottom: .3em; }
.lead h1 em { font-style: normal; color: var(--orange); }
.lead p { max-width: 62ch; margin-inline: auto; color: var(--muted); font-size: 1.15rem; }
.pill-row { display: flex; gap: .6rem; justify-content: center; flex-wrap: wrap; margin-top: 1.2rem; }
.pill { display: inline-flex; align-items: center; gap: .4rem; padding: .3rem .9rem; border: 2px solid var(--navy); border-radius: 999px; background: var(--surface); font-weight: 800; font-size: .9rem; box-shadow: 0 3px 0 var(--shadow); }

.section { padding: clamp(2.2rem, 5vw, 4rem) 0; }
.section-alt { background: var(--bg-2); border-block: 3px solid var(--navy); }
.section-head { text-align: center; margin-bottom: 2rem; }
.section-head p { color: var(--muted); max-width: 60ch; margin-inline: auto; }
.eyebrow { display: inline-block; font: 600 1.2rem/1 var(--display); letter-spacing: .12em; text-transform: uppercase; color: var(--orange); margin-bottom: .3rem; }

.grid { display: grid; gap: 1.2rem; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.card { background: var(--surface); border: 3px solid var(--navy); border-radius: var(--radius); padding: 1.3rem; box-shadow: 0 6px 0 var(--navy); min-width: 0; }
.card h3 { margin-bottom: .25em; }
.card p:last-child { margin-bottom: 0; }
.card .ico { width: 56px; height: 56px; object-fit: contain; margin-bottom: .6rem; }
a.card { display: block; text-decoration: none; color: inherit; transition: transform .1s; }
a.card:hover { transform: translateY(-3px); }

.steps { counter-reset: step; display: grid; gap: 1.6rem 1.2rem; grid-template-columns: repeat(4, minmax(0, 1fr)); list-style: none; padding: 1rem 0 0; margin: 0; }
.steps li { counter-increment: step; position: relative; padding: 1.4rem 1.2rem 1.2rem; background: var(--surface); border: 3px solid var(--navy); border-radius: var(--radius); box-shadow: 0 6px 0 var(--navy); }
.steps li::before { content: counter(step); position: absolute; top: -22px; left: 16px; width: 44px; height: 44px; display: grid; place-items: center; border: 3px solid var(--navy); border-radius: 50%; background: var(--gold); color: var(--navy); font: 700 1.7rem/1 var(--display); box-shadow: 0 3px 0 var(--navy); }
.steps h3 { margin-top: .6rem; font-size: 1.5rem; }
@media (max-width: 959px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .steps { grid-template-columns: minmax(0, 1fr); } }
.steps p { margin: 0; color: var(--muted); }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; text-align: center; }
.stat b { display: block; font: 700 clamp(2.4rem, 5vw, 3.6rem)/1 var(--display); color: var(--orange); text-shadow: 0 3px 0 var(--navy); }
.stat span { color: var(--muted); font-weight: 700; }

.cta-band { text-align: center; background: linear-gradient(135deg, #1f63c9, #2f86eb 55%, #58b3ff); color: #fff; border-block: 3px solid var(--navy); }
.cta-band h2, .cta-band p { color: #fff; text-shadow: 0 2px 0 rgba(10, 30, 70, .5); }
.cta-band p { max-width: 56ch; margin-inline: auto; }

.article-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2rem; padding: 2.4rem 0 3.5rem; }
.page-title { padding: 2.2rem 0 1.4rem; background: var(--bg-2); border-bottom: 3px solid var(--navy); }
.page-title h1 { margin: 0; font-size: clamp(2.4rem, 5vw, 3.6rem); }
.page-title p { margin: .4rem 0 0; color: var(--muted); max-width: 70ch; }
.toc { position: sticky; top: 90px; align-self: start; background: var(--surface); border: 3px solid var(--navy); border-radius: var(--radius); padding: 1rem 1.1rem; box-shadow: 0 5px 0 var(--navy); max-height: calc(100vh - 120px); overflow: auto; }
.toc h2 { font-size: 1.4rem; margin-bottom: .4rem; }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: .1rem; }
.toc a { display: block; padding: .22rem .4rem; border-radius: 6px; text-decoration: none; color: var(--muted); font-size: .94rem; font-weight: 600; }
.toc a:hover { background: var(--bg-2); color: var(--orange); }
@media (min-width: 960px) { .article-layout.has-toc { grid-template-columns: 270px minmax(0, 1fr); } }
@media (max-width: 959px) { .toc { position: static; max-height: none; } }
.prose { min-width: 0; max-width: 78ch; }
.prose h2 { margin-top: 1.6em; padding-top: .4em; border-top: 3px dashed var(--line); font-size: 2.2rem; }
.prose h2:first-child { border-top: 0; margin-top: 0; }
.prose h3 { margin-top: 1.2em; font-size: 1.6rem; color: var(--orange); }
.prose li { margin-bottom: .35em; }
.prose code, code { background: var(--bg-2); padding: .1em .4em; border-radius: 6px; font-size: .92em; }
.callout { background: var(--cream); border: 3px solid var(--navy); border-left-width: 10px; border-radius: 10px; padding: .8rem 1.1rem; margin: 1.2rem 0; }
.callout p { margin: 0 0 .4em; } .callout p:last-child { margin: 0; }
.table-wrap { overflow-x: auto; margin: 1rem 0; border: 3px solid var(--navy); border-radius: 12px; background: var(--surface); }
table { border-collapse: collapse; width: 100%; font-size: .95rem; }
th, td { padding: .55rem .8rem; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--bg-2); font: 600 1.15rem/1.1 var(--display); letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
.updated { color: var(--muted); font-size: .9rem; }

.faq details { background: var(--surface); border: 3px solid var(--navy); border-radius: 12px; margin-bottom: .8rem; box-shadow: 0 4px 0 var(--navy); }
.faq summary { cursor: pointer; padding: .9rem 1.1rem; font: 600 1.4rem/1.2 var(--display); letter-spacing: .02em; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 1.8rem; line-height: 1; color: var(--orange); }
.faq details[open] summary::after { content: '–'; }
.faq .answer { padding: 0 1.1rem 1rem; color: var(--muted); }
.faq .answer p:last-child { margin: 0; }

.crumbs { font-size: .9rem; color: var(--muted); margin-bottom: .5rem; }
.crumbs a { color: var(--muted); }
.wiki-tools { display: flex; gap: .8rem; flex-wrap: wrap; align-items: center; margin: 1rem 0 1.4rem; }
.search { flex: 1 1 260px; min-width: 0; padding: .75rem 1rem; border: 3px solid var(--navy); border-radius: 12px; background: var(--surface); color: var(--ink); font: 600 1rem var(--body); box-shadow: inset 0 3px 0 var(--shadow); }
.search:focus { outline: 3px solid var(--gold-2); }
.chips { display: flex; gap: .4rem; flex-wrap: wrap; }
.chip { border: 2px solid var(--navy); background: var(--surface); color: var(--ink); border-radius: 999px; padding: .2rem .8rem; font: 700 .85rem var(--body); cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--gold); color: var(--navy); }
.dex { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .9rem; }
.mon { display: flex; flex-direction: column; align-items: center; gap: .15rem; padding: .8rem .5rem; text-decoration: none; color: var(--ink); text-align: center; background: var(--surface); border: 3px solid var(--navy); border-radius: 12px; box-shadow: 0 4px 0 var(--navy); }
.mon:hover { transform: translateY(-3px); color: var(--ink); }
.mon img { width: 40px; height: 40px; object-fit: contain; }
.mon small { color: var(--muted); font-weight: 700; }
.mon b { font: 600 1.3rem/1 var(--display); }
.types { display: flex; gap: .3rem; justify-content: center; flex-wrap: wrap; }
.type { display: inline-block; padding: .05rem .6rem; border-radius: 999px; font: 800 .72rem/1.6 var(--body); color: #fff; text-shadow: 0 1px 0 rgba(0, 0, 0, .45); border: 2px solid rgba(0, 0, 0, .28); text-transform: uppercase; letter-spacing: .04em; }
.mon-head { display: grid; gap: 1.2rem; grid-template-columns: 220px minmax(0, 1fr); align-items: center; margin-bottom: 1.6rem; }
.mon-head .portrait { display: grid; place-items: center; min-height: 200px; background: var(--surface); border: 3px solid var(--navy); border-radius: var(--radius); box-shadow: 0 6px 0 var(--navy); }
.mon-head .portrait img { max-width: 180px; max-height: 180px; }
@media (max-width: 640px) { .mon-head { grid-template-columns: 1fr; } }
.bar { display: grid; grid-template-columns: 7ch 3ch minmax(0, 1fr); gap: .6rem; align-items: center; margin: .2rem 0; font-weight: 700; font-size: .92rem; }
.bar i { display: block; height: 12px; border-radius: 6px; background: var(--line); overflow: hidden; border: 2px solid var(--navy); }
.bar i u { display: block; height: 100%; background: linear-gradient(90deg, var(--green), var(--gold)); }
.tags { display: flex; gap: .4rem; flex-wrap: wrap; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: .3rem 1rem; margin: 0 0 1rem; }
.kv dt { font-weight: 800; color: var(--muted); } .kv dd { margin: 0; }
.row-icon { display: flex; align-items: center; gap: .5rem; }
.row-icon img { width: 32px; height: 32px; object-fit: contain; }
.empty { padding: 2rem; text-align: center; color: var(--muted); }

.fan-note { background: var(--cream); border-top: 3px solid var(--navy); padding: 1.2rem 0; font-size: .92rem; color: var(--ink); }
.fan-note p { margin: 0; }
.site-footer { background: var(--navy); color: #cfdcff; padding: 2.4rem 0 1.4rem; font-size: .95rem; }
.site-footer a { color: #fff; text-decoration: none; } .site-footer a:hover { color: var(--gold); text-decoration: underline; }
.foot-grid { display: grid; gap: 1.6rem; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.foot-grid h2 { font-size: 1.4rem; color: var(--gold); margin-bottom: .5rem; letter-spacing: .06em; text-transform: uppercase; }
.foot-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .3rem; }
.foot-brand img { height: 72px; width: auto; margin-bottom: .6rem; }
.foot-bottom { margin-top: 1.8rem; padding-top: 1rem; border-top: 1px solid rgba(255, 255, 255, .15); font-size: .85rem; color: #9fb2e6; }
.notice { position: fixed; inset: auto 12px 12px 12px; z-index: 80; display: none; max-width: 760px; margin-inline: auto; gap: 1rem; align-items: center; background: var(--surface); border: 3px solid var(--navy); border-radius: 14px; padding: .9rem 1.1rem; box-shadow: 0 6px 0 var(--navy), 0 12px 30px var(--shadow); font-size: .92rem; }
.notice.show { display: flex; }
.notice p { margin: 0; }

@media (max-width: 960px) {
  .nav { grid-template-columns: auto 1fr auto; min-height: 76px; }
  .brand { grid-column: 1; }
  .brand img { height: 60px; }
  .burger { display: inline-flex; grid-column: 3; grid-row: 1; }
  .nav-menu { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; background: var(--surface); border-bottom: 3px solid var(--navy); padding: .6rem 1rem 1rem; gap: .4rem; }
  .nav-toggle:checked ~ .nav-menu { display: flex; }
  .nav-left, .nav-right { justify-self: stretch; }
  .nav-links, .nav-right { flex-direction: column; align-items: stretch; }
  .nav-right .btn { align-self: flex-start; }
  .lang { margin: .4rem 0 0; }
  .notice { flex-direction: column; align-items: stretch; }
}
@media (max-width: 640px) {
  .hero-art { height: 300px; object-fit: cover; object-position: 50% 40%; }
  .cta-row .btn { flex: 1 1 100%; }
}
dialog.beta { padding: 0; border: 3px solid var(--navy); border-radius: 18px; background: var(--navy); width: min(1000px, 96vw); max-width: 96vw; max-height: 94vh; overflow: auto; box-shadow: 0 8px 0 var(--navy), 0 30px 70px rgba(0, 0, 0, .55); color: #fff; }
dialog.beta:focus { outline: none; }
dialog.beta[open] { animation: beta-drop .55s cubic-bezier(.2, 1.2, .35, 1) both; }
dialog.beta::backdrop { background: rgba(5, 11, 31, .72); backdrop-filter: blur(3px); }
dialog.beta img { display: block; width: 100%; height: auto; }
.beta-info { background: var(--cream); color: var(--ink); border-top: 3px solid var(--navy); padding: 1rem 1.4rem .6rem; }
.beta-info h2 { font-size: 1.7rem; margin: 0 0 .4rem; color: var(--orange); }
.beta-info ul { margin: 0; padding-left: 1.2rem; font-size: .95rem; line-height: 1.5; }
.beta-info li { margin-bottom: .3rem; }
.beta-cta { display: flex; justify-content: center; padding: .9rem; background: var(--navy); }
.beta-x { position: absolute; top: .6rem; right: .6rem; z-index: 2; width: 42px; height: 42px; border: 3px solid var(--navy); border-radius: 50%; background: #fff; color: var(--navy); font: 700 1.9rem/1 var(--display); cursor: pointer; box-shadow: 0 3px 0 var(--navy); display: grid; place-items: center; padding: 0 0 .2rem; }
.beta-x:hover { background: var(--gold); }
@keyframes beta-drop { from { transform: translateY(-70vh) rotate(-2deg); opacity: 0; } to { transform: none; opacity: 1; } }
.gallery { display: grid; gap: 1.2rem; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.shot { margin: 0; background: var(--surface); border: 3px solid var(--navy); border-radius: var(--radius); box-shadow: 0 6px 0 var(--navy); overflow: hidden; }
.shot:first-child { grid-column: 1 / -1; }
.shot-btn { display: block; width: 100%; padding: 0; border: 0; background: var(--navy); cursor: zoom-in; }
.shot-btn img { display: block; width: 100%; height: auto; image-rendering: auto; transition: transform .25s; }
.shot-btn:hover img { transform: scale(1.02); }
.shot-btn { overflow: hidden; }
.shot figcaption { padding: .7rem 1rem .9rem; font-weight: 700; color: var(--ink); }
@media (max-width: 700px) { .gallery { grid-template-columns: minmax(0, 1fr); } }
dialog.lightbox { padding: 0; border: 3px solid var(--navy); border-radius: 16px; background: var(--navy); width: min(1280px, 96vw); max-width: 96vw; max-height: 94vh; overflow: auto; color: #fff; }
dialog.lightbox:focus { outline: none; }
dialog.lightbox::backdrop { background: rgba(5, 11, 31, .82); }
dialog.lightbox img { display: block; width: 100%; height: auto; }
.lightbox-cap { margin: 0; padding: .8rem 1.2rem; font-weight: 700; }
@media (prefers-reduced-motion: reduce) { dialog.beta[open] { animation: none; } * { transition: none !important; scroll-behavior: auto !important; } }
