/* Tibia Backup — escuro como as janelas do cliente do Tibia (pedra, chanfro claro em cima e escuro embaixo), dourado nos
   títulos, pergaminho para o que é regra, e os sprites do jogo em pixel art. */
:root {
  --bg: #0d0e11; --bg-2: #13151a; --panel: #1a1c22; --panel-2: #22252c; --panel-3: #2b2f37;
  --bevel-light: #4a4e57; --bevel-dark: #07080a; --line: #2f333b;
  --text: #ece4d2; --text-2: #c9c0ad; --muted: #8f9198;
  --gold: #e3b95f; --gold-2: #f5d48c; --gold-dark: #8a6a2b; --red: #c0442a; --good: #6cc68f; --bad: #f0705d;
  --parchment: #e9dcb8; --parchment-ink: #3b2c17;
  --radius: 6px;
  --font: Verdana, Tahoma, "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif;
  --head: Georgia, "Palatino Linotype", "Book Antiqua", serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }   /* um link para #seção não a deixa embaixo do cabeçalho fixo */
body {
  margin: 0; color: var(--text); font: 15px/1.6 var(--font);
  background: radial-gradient(ellipse at 50% -10%, #2a2216 0%, transparent 55%), var(--bg);
  background-attachment: fixed;
}
a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-2); text-decoration: underline; }
h1, h2, h3 { font-family: var(--head); color: var(--gold-2); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(28px, 4.5vw, 44px); }
h2 { font-size: 24px; }
h3 { font-size: 17px; }
p { margin: 0 0 1em; }
img.item, .brand img, .locker, .hero-art img { image-rendering: pixelated; image-rendering: crisp-edges; }
.wrap { max-width: 1120px; margin: 0 auto; padding-left: 20px; padding-right: 20px; }   /* só nas laterais: uma section.wrap fica com o espaço de cima e de baixo das seções */
.narrow { max-width: 760px; }
/* a primeira seção de cada página (fora a abertura da página inicial) respira abaixo do cabeçalho */
main > section.wrap:first-child { padding-top: 32px; padding-bottom: 24px; }
.row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.row.center, .center { justify-content: center; text-align: center; }
.row.top { align-items: flex-start; }
.row.bottom { align-items: flex-end; }
.grow { flex: 1; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.ok { color: var(--good); }
.error { color: var(--bad); }
.mono, .code { font-family: ui-monospace, Menlo, Consolas, monospace; }

/* o cabeçalho */
header.top { position: sticky; top: 0; z-index: 10; background: rgba(13, 14, 17, .92); backdrop-filter: blur(6px);
             border-bottom: 1px solid var(--line); }
header.top .wrap { height: 64px; flex-wrap: nowrap; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--head); font-size: 20px; color: var(--gold-2); font-weight: 700;
         white-space: nowrap; }
.brand:hover { text-decoration: none; }
.brand img { width: 40px; height: 40px; }
.brand.small { font-size: 16px; }
.brand.small img { width: 28px; height: 28px; }
header nav { justify-content: center; gap: 22px; }
header nav a, .account a:not(.btn) { color: var(--text-2); }
header nav a.on, header nav a:hover { color: var(--gold-2); text-decoration: none; }
.langs { display: flex; gap: 2px; margin-left: 8px; }
.langs a { font-size: 11px; color: var(--muted); padding: 3px 5px; border-radius: 4px; }
.langs a.on { color: var(--gold-2); background: var(--panel-2); }

/* o menu do celular: um botão no cabeçalho que abre um painel embaixo dele, com as páginas, a conta e o idioma */
.menu { display: none; margin-left: auto; }
.menu summary { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border-radius: 6px; cursor: pointer;
                color: var(--text); background: var(--panel-2); border: 1px solid var(--line); }
header .menu summary::before, header .menu[open] summary::before { content: none; display: none; }
.menu summary:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.menu[open] summary { color: var(--gold-2); border-color: var(--gold-dark); }
.burger { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.burger.x, .menu[open] .burger.bars { display: none; }
.menu[open] .burger.x { display: block; }
.menu-panel { position: absolute; top: 100%; left: 0; right: 0; padding: 4px 20px 20px; background: var(--bg-2);
              border-bottom: 1px solid var(--line); box-shadow: 0 18px 30px rgba(0, 0, 0, .55);
              max-height: calc(100vh - 64px); max-height: calc(100dvh - 64px); overflow-y: auto; }
header .menu-panel nav { display: flex; flex-direction: column; gap: 0; }
.menu-panel nav a { padding: 13px 2px; border-bottom: 1px solid var(--line); color: var(--text); font-size: 16px; }
.menu-panel nav a.on { color: var(--gold-2); }
.menu-account { display: flex; gap: 10px; margin: 18px 0 14px; }
.menu-account .btn { flex: 1; min-width: 0; overflow-wrap: anywhere; text-align: center; padding: 12px; }
header .account .btn { max-width: 170px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (min-width: 1100px) { header .account .btn { max-width: 260px; } }
/* com o menu aberto, a página embaixo escurece (o toque fora fecha o menu, sem abrir o que estiver embaixo: site.js) */
main, footer { transition: opacity .15s; }
body.menu-open main, body.menu-open footer { opacity: .35; }
.menu-panel .langs { margin: 0; gap: 6px; }
.menu-panel .langs a { font-size: 13px; padding: 9px 0; min-width: 48px; text-align: center; border: 1px solid var(--line); }

/* botões com o chanfro do cliente */
.btn { display: inline-block; cursor: pointer; font: 700 14px var(--font); color: #20160a; text-decoration: none;
       padding: 10px 18px; border-radius: 4px; border: 1px solid #5a4317;
       background: linear-gradient(#f2cf7c, #d9a94a); box-shadow: inset 0 1px 0 #fff3c4, inset 0 -2px 0 #a8792c, 0 2px 0 #07080a; }
.btn:hover { filter: brightness(1.08); text-decoration: none; color: #20160a; }
.btn.big { font-size: 16px; padding: 14px 26px; }
.btn.small { font-size: 12px; padding: 6px 12px; }
.btn.wide { width: 100%; }
.btn.ghost { color: var(--text); background: linear-gradient(var(--panel-3), var(--panel-2)); border-color: var(--bevel-dark);
             box-shadow: inset 0 1px 0 var(--bevel-light), 0 2px 0 #07080a; }
.btn.ghost:hover { color: var(--gold-2); }
.btn.danger { color: #fff; background: linear-gradient(#cf5638, #a3341d); border-color: #5c1a0c; box-shadow: inset 0 1px 0 #f08a6c, 0 2px 0 #07080a; }

/* os painéis */
.card { background: linear-gradient(var(--panel), var(--bg-2)); border: 1px solid var(--bevel-dark); border-radius: var(--radius);
        box-shadow: inset 1px 1px 0 var(--bevel-light), inset -1px -1px 0 #0b0c0e, 0 10px 30px rgba(0, 0, 0, .35);
        padding: 22px; margin-bottom: 18px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.grid.three { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 16px; align-items: end; }

/* a abertura */
.hero { padding: 64px 0 48px; }
.hero-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 40px; align-items: center; }
.eyebrow { color: var(--gold); text-transform: uppercase; letter-spacing: .14em; font-size: 12px; font-weight: 700; }
.lead { font-size: 18px; color: var(--text-2); max-width: 620px; }
.cta { margin: 26px 0 10px; }
.hero-art { position: relative; aspect-ratio: 1; max-width: 380px; justify-self: center; width: 100%;
            background: radial-gradient(circle, rgba(227, 185, 95, .22) 0%, transparent 62%); }
.hero-art .locker { position: absolute; inset: 22%; width: 56%; height: 56%; filter: drop-shadow(0 18px 24px rgba(0, 0, 0, .6)); }
.hero-art .item { position: absolute; width: 22%; filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .55)); animation: float 6s ease-in-out infinite; }
.hero-art .item:nth-of-type(2) { left: 2%; top: 8%; }
.hero-art .item:nth-of-type(3) { right: 0; top: 4%; animation-delay: -1.5s; }
.hero-art .item:nth-of-type(4) { left: 4%; bottom: 4%; animation-delay: -3s; }
.hero-art .item:nth-of-type(5) { right: 4%; bottom: 8%; animation-delay: -4.5s; }
@keyframes float { 50% { transform: translateY(-10px); } }

/* as seções */
section { padding: 44px 0; }
.title { text-align: center; font-size: clamp(24px, 3.2vw, 32px); }
.title.left { text-align: left; }
.sub { text-align: center; color: var(--text-2); max-width: 680px; margin: 0 auto 28px; }
.feature { text-align: left; margin: 0; transition: transform .15s; }
.feature:hover { transform: translateY(-3px); }
.feature .item { width: 64px; height: 64px; object-fit: contain; margin-bottom: 8px; }
.feature p { color: var(--text-2); font-size: 14px; margin: 0; }
.band { background: linear-gradient(180deg, rgba(34, 37, 44, .5), rgba(13, 14, 17, 0)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.steps { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.steps li { display: flex; gap: 14px; align-items: flex-start; }
.steps .num { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font: 700 18px var(--head);
              color: #20160a; background: linear-gradient(#f2cf7c, #c99a3e); box-shadow: 0 2px 0 #07080a; }
.steps p { color: var(--text-2); margin: 0; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: center; }
.ways { list-style: none; padding: 0; margin: 0; }
.ways li { padding: 10px 0; border-bottom: 1px solid var(--line); display: flex; gap: 12px; align-items: center; flex-wrap: nowrap; }
.ways .mb, .ways .done { white-space: nowrap; }
.ways.list .mb, .ways.list .done { text-align: right; }
.ways .mb { color: var(--gold-2); font-weight: 700; min-width: 72px; }
.ways .done { color: var(--good); font-weight: 700; }
.scroll { background: linear-gradient(#efe3c3, #dccb9f); color: var(--parchment-ink); border-color: #6d5428;
          box-shadow: inset 0 0 0 2px #f7edd2, inset 0 0 30px rgba(110, 80, 30, .35), 0 12px 30px rgba(0, 0, 0, .45); }
.scroll h3 { color: #5a3d14; }
.scroll ul { margin: 0; padding-left: 20px; }
.scroll li { margin: 6px 0; }
.scroll .item { float: right; width: 72px; margin: 0 0 6px 10px; }
details.card { padding: 0; margin-bottom: 10px; }
details summary { cursor: pointer; padding: 16px 22px; font-weight: 700; color: var(--text); list-style: none; }
details summary::-webkit-details-marker { display: none; }
details summary::before { content: "▸ "; color: var(--gold); }
details[open] summary::before { content: "▾ "; }
details p { padding: 0 22px 18px; margin: 0; color: var(--text-2); }
.final { text-align: center; padding: 56px 0; }

/* download */
.os.mine { border-color: var(--gold-dark); box-shadow: inset 1px 1px 0 var(--gold), 0 10px 30px rgba(0, 0, 0, .35); }
.os ul { list-style: none; padding: 0; margin: 0 0 12px; }
.os li { margin: 10px 0; }
.os li .muted { white-space: nowrap; }
table.sha { width: calc(100% - 44px); border-collapse: collapse; font-size: 12px; margin: 0 22px 18px; }
table.sha td { padding: 6px; border-top: 1px solid var(--line); word-break: break-all; }

/* entrar e a conta */
.auth { max-width: 440px; }
.auth form { margin-bottom: 14px; }
.auth p.row a { padding: 6px 0; }
.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 14px; font-size: 13px; color: var(--text-2); }
input, select { font: inherit; color: var(--text); background: #0b0c0f; border: 1px solid var(--bevel-dark); border-radius: 4px;
                padding: 10px 12px; box-shadow: inset 1px 1px 0 #000, inset -1px -1px 0 var(--panel-3); }
input:focus { outline: 2px solid var(--gold-dark); outline-offset: 0; }
input[type=checkbox] { padding: 0; width: 16px; height: 16px; vertical-align: middle; }
.notice { background: var(--panel-2); border-left: 3px solid var(--gold); padding: 12px 16px; border-radius: 4px; margin: 0 0 16px; }
.notice.ok { border-color: var(--good); }
.notice.error { border-color: var(--bad); color: var(--bad); }
.account-page h2 { display: flex; align-items: center; gap: 10px; }
.account-page > .row.between > div { min-width: 0; }
.account-page h1, .account-page .muted { overflow-wrap: anywhere; }
.account-page form.row .field { flex: 1 1 200px; max-width: 360px; }
.card form + h3, .card .row.top + h3 { margin-top: 26px; }
.card > form + p { margin-top: 12px; }
.danger-zone form > label.small { display: flex; gap: 8px; align-items: center; margin: 6px 0 14px; }
.row.between > strong:last-child { margin-left: auto; text-align: right; }
.account-page h2 .item { width: 36px; height: 36px; object-fit: contain; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 12px 0 22px; }
.tabs a { padding: 7px 14px; border-radius: 4px; background: var(--panel-2); color: var(--text-2); font-size: 13px; }
.list { list-style: none; padding: 0; margin: 0 0 12px; }
.list > li { padding: 12px 0; border-top: 1px solid var(--line); }
.list > li:first-child { border-top: 0; }
.list .item { width: 20px; vertical-align: middle; }
form.inline { display: inline-flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0; max-width: 100%; }
form.inline input:not([type=checkbox]) { padding: 6px 10px; flex: 1 1 150px; min-width: 0; }
.meter { height: 12px; border-radius: 999px; background: #0b0c0f; border: 1px solid var(--bevel-dark); overflow: hidden; margin: 8px 0; }
.meter i { display: block; height: 100%; width: var(--pct, 0%); background: linear-gradient(90deg, #c99a3e, #f2cf7c); }
.code { display: inline-block; max-width: 100%; overflow-wrap: anywhere; font-size: 16px; letter-spacing: 1px; padding: 6px 12px;
        border: 1px dashed var(--gold-dark); border-radius: 4px; background: #0b0c0f; }
pre.code { display: block; white-space: pre-wrap; }
input.copy { flex: 1; min-width: 220px; font-size: 13px; }
.qr { background: #fff; padding: 8px; border-radius: 6px; width: 190px; }
.qr svg { display: block; width: 100%; height: auto; }
.qr-side { flex: 0 1 460px; min-width: 0; }
.danger-zone { border-color: #5c1a0c; }
.table { width: 100%; border-collapse: collapse; margin-bottom: 16px; }
.table th, .table td { text-align: left; padding: 8px; border-top: 1px solid var(--line); }
.table th, .table td:not(:first-child) { white-space: nowrap; }
.table-scroll { overflow-x: auto; margin-bottom: 16px; }
.table-scroll .table { margin-bottom: 0; }
.table-scroll td:first-child { min-width: 160px; }
.table td:has(> form) { white-space: normal; }   /* as ações (Esconder, Apagar) podem ir uma embaixo da outra */
.table td > form.inline { margin: 2px 8px 2px 0; }
.grid > .card { margin-bottom: 0; }
.grid + * { margin-top: 18px; }   /* o espaço depois da última fileira de cartões */

footer { border-top: 1px solid var(--line); padding: 28px 0 40px; margin-top: 24px; }
footer .row a { color: var(--text-2); font-size: 13px; padding: 6px 0; }

@media (max-width: 860px) {
  .hero-grid, .split { grid-template-columns: 1fr; }
  .hero-art { max-width: 260px; }
  header.top .links, header.top .account, header.top .wrap > .langs { display: none; }
  .menu { display: block; }
}
@media (max-width: 520px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  .menu-panel { padding: 4px 16px 18px; }
  .card { padding: 16px; }
  details summary { padding: 14px 16px; }
  details p { padding: 0 16px 16px; }
  table.sha { width: calc(100% - 32px); margin: 0 16px 16px; }
  table.sha, table.sha tbody, table.sha tr, table.sha td { display: block; }
  table.sha td + td { border-top: 0; padding-top: 0; }
  .hero { padding: 36px 0 32px; }
  section { padding: 32px 0; }
  .btn.big { width: 100%; text-align: center; }
  .brand { font-size: 18px; }
  #profiles .list li > .row.between, #profiles .list li > .row.between > span, #computers .list li > span > .muted { display: block; }   /* a linha de baixo sempre embaixo */
}

/* o marketplace: a lista com filtros, os cartões (partes, vocações e tags, curtidas e downloads) e a página de cada perfil */
.market .filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 14px; margin: 18px 0 10px; }
.market .filters input[type=search] { flex: 2 1 220px; }
.market .filters input[type=number] { flex: 0 1 130px; }
.market .filters select { flex: 1 1 150px; }
.market .publish { max-width: 300px; text-align: center; padding: 14px 18px; }
.market .publish .item { width: 40px; height: 40px; object-fit: contain; }
@media (max-width: 860px) {
  .mdetail > p.small:first-child a { display: inline-block; padding: 10px 0; }   /* voltar: alvo maior no celular */
  .market .publish { max-width: none; width: 100%; display: flex; align-items: center; gap: 12px; text-align: left; margin: 0; }
  .market .publish p { flex: 1; margin: 0; }
  .market .filters input[type=number] { flex: 1 1 110px; }
}
@media (max-width: 520px) {
  .market .filters .btn { flex: 1 0 auto; }
}
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.chip { display: inline-block; font-size: 12px; line-height: 1.5; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line);
        background: var(--panel-2); color: var(--text-2); }
a.chip:hover { color: var(--gold-2); text-decoration: none; border-color: var(--gold-dark); }
.chip.on { background: var(--gold-dark); color: #fff; border-color: var(--gold); }
.chip.voc { color: var(--gold-2); border-color: var(--gold-dark); }
.chip.more { color: var(--muted); }
.mgrid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.mcard { position: relative; display: flex; flex-direction: column; }
.mcard h3 { margin: 8px 0 2px; }
.mcard p { margin: 0; }
.mcard .stretch::after { content: ""; position: absolute; inset: 0; }
.mcard:hover { border-color: var(--gold-dark); }
.mcard .mstats { margin-top: auto; padding-top: 10px; }
.mparts { display: flex; gap: 6px; }
.mparts .item { width: 28px; height: 28px; object-fit: contain; }
.mparts.big .item { width: 40px; height: 40px; }
.mstats { display: flex; gap: 14px; font-size: 13px; color: var(--muted); align-items: center; }
.mstats span { display: inline-flex; gap: 5px; align-items: center; }
.mstats .liked { color: #e0525a; }
.ico { width: 16px; height: 16px; fill: currentColor; flex: none; }
.heart { display: inline-flex; gap: 6px; align-items: center; background: var(--panel-2); border: 1px solid var(--line); border-radius: 999px;
         padding: 6px 14px; color: var(--text-2); cursor: pointer; font: 700 14px var(--font); }
.heart .ico { width: 20px; height: 20px; }
.heart.on, .heart:hover { color: #e0525a; border-color: #7a2a30; text-decoration: none; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; align-items: start; margin-top: 10px; }
@media (max-width: 860px) { .detail-grid { grid-template-columns: 1fr; } }
.mdetail h1 { margin-top: 10px; }
.mdetail .desc { margin: 12px 0 22px; }
.mdetail .desc p { margin: 0; }
.contents .item { width: 32px; height: 32px; object-fit: contain; }
.use .btn.wide { margin: 6px 0; text-align: center; }
.use h2 { margin-top: 16px; }
.use h3 { margin-top: 18px; }
.use form { margin: 0; }
textarea { font: inherit; color: var(--text); background: #0b0c0f; border: 1px solid var(--bevel-dark); border-radius: 4px; padding: 10px 12px;
           resize: vertical; }
textarea:focus { outline: 2px solid var(--gold-dark); outline-offset: 0; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); margin: 0 0 14px; padding: 10px 14px 12px; }
legend { font-size: 13px; color: var(--text-2); padding: 0 6px; }
.checks { display: flex; flex-wrap: wrap; gap: 8px 18px; }
label.check { font-size: 14px; color: var(--text); cursor: pointer; }
.pager { margin: 22px 0; gap: 16px; }

/* telas de toque: alvos maiores (no fim do arquivo, para valer sobre as regras de cima) */
@media (pointer: coarse) {
  .chip { padding: 5px 12px; }
  .btn.small { padding: 8px 14px; }
}
