/* SagaForge — estilos da plataforma (sem build: CSS puro) */
:root {
  --bg: #0b0908;
  --bg2: #14100d;
  --card: rgba(24, 19, 15, .82);
  --card-solid: #18130f;
  --glass: rgba(14, 11, 9, .62);
  --line: rgba(201, 164, 92, .22);
  --line-soft: rgba(255, 255, 255, .07);
  --gold: #c9a45c;
  --gold-2: #e8cc8a;
  --ember: #c4572e;
  --text: #ece4d6;
  --muted: #a99d8b;
  --ok: #5fb985;
  --warn: #e0b34f;
  --danger: #e06a5c;
  --radius: 14px;
  --shadow: 0 18px 50px rgba(0, 0, 0, .45);
  --f-head: 'Cinzel', Georgia, serif;
  --f-ui: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-read: 'Crimson Text', Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; overflow-x: clip; background: var(--bg); color: var(--text);
  font: 15px/1.6 var(--f-ui); -webkit-font-smoothing: antialiased;
}
body.app-body {
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(201, 164, 92, .08), transparent 60%),
    radial-gradient(900px 500px at 110% 10%, rgba(196, 87, 46, .07), transparent 60%),
    var(--bg);
}
a { color: var(--gold-2); text-decoration: none; }
a:hover { color: #fff3d4; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--f-head); font-weight: 700; letter-spacing: .02em; line-height: 1.2; margin: 0 0 .6em; }
h1 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
h2 { font-size: clamp(1.3rem, 2.2vw, 1.7rem); }
h3 { font-size: 1.1rem; }
p { margin: 0 0 1em; }
hr { border: 0; border-top: 1px solid var(--line-soft); margin: 1.5rem 0; }
small, .muted { color: var(--muted); }
.gold { color: var(--gold-2); }
.center { text-align: center; }
.mt-0 { margin-top: 0 } .mt-1 { margin-top: .5rem } .mt-2 { margin-top: 1rem } .mt-3 { margin-top: 1.5rem } .mt-4 { margin-top: 2.5rem }
.mb-0 { margin-bottom: 0 } .mb-1 { margin-bottom: .5rem } .mb-2 { margin-bottom: 1rem } .mb-3 { margin-bottom: 1.5rem } .mb-4 { margin-bottom: 2.5rem }
.flex { display: flex; gap: .75rem; align-items: center; }
.flex-wrap { flex-wrap: wrap; }
.between { justify-content: space-between; }
.grow { flex: 1; }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ----------------------------------------------------------- layout */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.page { padding: 28px 0 60px; }
.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.games-grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } .container { padding: 0 14px; } }

/* ----------------------------------------------------------- topbar */
.topbar {
  position: sticky; top: 0; z-index: 40; backdrop-filter: blur(12px);
  background: rgba(11, 9, 8, .82); border-bottom: 1px solid var(--line-soft);
}
.topbar .container { display: flex; align-items: center; gap: 18px; height: 62px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--f-head); font-weight: 700; font-size: 1.15rem; color: var(--text); letter-spacing: .06em; }
.brand img { width: 30px; height: 30px; }
.brand:hover { color: var(--gold-2); }
.nav-links { display: flex; gap: 4px; align-items: center; }
.nav-links a { padding: 8px 12px; border-radius: 9px; color: var(--muted); font-weight: 500; font-size: .93rem; }
.nav-links a:hover, .nav-links a.active { color: var(--text); background: rgba(255, 255, 255, .05); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.credit-pill {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px;
  background: rgba(201, 164, 92, .12); border: 1px solid var(--line); color: var(--gold-2); font-weight: 600; font-size: .9rem;
}
.pro-badge { font-size: .7rem; font-weight: 700; letter-spacing: .08em; padding: 3px 8px; border-radius: 6px; background: linear-gradient(135deg, #e8cc8a, #b8873b); color: #1b1309; }
.avatar { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line); }
.menu-toggle { display: none; background: none; border: 0; color: var(--text); font-size: 1.5rem; cursor: pointer; }
.dropdown { position: relative; }
.dropdown-menu {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 210px; background: var(--card-solid);
  border: 1px solid var(--line); border-radius: 12px; padding: 6px; box-shadow: var(--shadow); display: none; z-index: 50;
}
.dropdown.open .dropdown-menu { display: block; }
.dropdown-menu a, .dropdown-menu button {
  display: block; width: 100%; text-align: left; padding: 9px 12px; border-radius: 8px; color: var(--text);
  background: none; border: 0; font: inherit; cursor: pointer;
}
.dropdown-menu a:hover, .dropdown-menu button:hover { background: rgba(255, 255, 255, .06); }
@media (max-width: 820px) {
  .menu-toggle { display: block; }
  .nav-links { display: none; position: absolute; top: 62px; left: 0; right: 0; flex-direction: column; align-items: stretch; background: var(--card-solid); border-bottom: 1px solid var(--line); padding: 10px; }
  .nav-links.open { display: flex; }
  .nav-right .credit-pill .pill-label { display: none; }
}

/* ----------------------------------------------------------- language switch */
.lang-switch { display: inline-flex; gap: 2px; padding: 3px; border-radius: 10px; background: rgba(255, 255, 255, .05); border: 1px solid var(--line-soft); }
.lang-switch a { padding: 4px 8px; border-radius: 7px; font-size: .75rem; font-weight: 700; color: var(--muted); letter-spacing: .04em; }
.lang-switch a.active { background: rgba(201, 164, 92, .2); color: var(--gold-2); }

/* ----------------------------------------------------------- cards */
.card { background: var(--card); border: 1px solid var(--line-soft); border-radius: var(--radius); padding: 22px; box-shadow: 0 8px 30px rgba(0, 0, 0, .25); }
.card-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.card-title h2, .card-title h3 { margin: 0; }
.glass { background: var(--glass); backdrop-filter: blur(14px) saturate(120%); -webkit-backdrop-filter: blur(14px) saturate(120%); border: 1px solid rgba(255, 255, 255, .09); border-radius: 18px; box-shadow: var(--shadow); }

.stat { padding: 18px; }
.stat .num { font-family: var(--f-head); font-size: 1.8rem; color: var(--gold-2); line-height: 1.1; }
.stat .lbl { color: var(--muted); font-size: .85rem; }

/* ----------------------------------------------------------- game cards */
.game-card { position: relative; border-radius: 16px; overflow: hidden; background: var(--card-solid); border: 1px solid var(--line-soft); transition: transform .25s, border-color .25s, box-shadow .25s; display: flex; flex-direction: column; }
.game-card:hover { transform: translateY(-4px); border-color: var(--line); box-shadow: 0 18px 40px rgba(0, 0, 0, .5); }
.game-card .thumb { aspect-ratio: 16 / 10; background: #000 center/cover no-repeat; position: relative; }
.game-card .thumb::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(10, 8, 6, .95)); }
.game-card .badges { position: absolute; top: 10px; left: 10px; z-index: 2; display: flex; gap: 6px; }
.game-card .body { padding: 14px 16px 16px; margin-top: -48px; position: relative; z-index: 2; flex: 1; display: flex; flex-direction: column; }
.game-card h3 { font-size: 1.15rem; margin-bottom: 4px; color: #fff; }
.game-card p { color: var(--muted); font-size: .9rem; margin-bottom: 12px; flex: 1; }
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 999px; font-size: .72rem; font-weight: 600; letter-spacing: .03em; background: rgba(0, 0, 0, .55); border: 1px solid var(--line); color: var(--gold-2); backdrop-filter: blur(6px); }
.badge.green { color: #9be3b9; border-color: rgba(95, 185, 133, .35); }
.badge.red { color: #ffb0a6; border-color: rgba(224, 106, 92, .35); }
.badge.gray { color: var(--muted); border-color: var(--line-soft); }

.adv-card { display: flex; gap: 14px; align-items: stretch; padding: 12px; border-radius: 14px; background: var(--card); border: 1px solid var(--line-soft); transition: border-color .2s; }
.adv-card:hover { border-color: var(--line); }
.adv-card .thumb { width: 120px; min-height: 76px; border-radius: 10px; background: #000 center/cover; flex-shrink: 0; }
.adv-card .info { flex: 1; min-width: 0; }
.adv-card h4 { margin: 0 0 4px; font-size: 1rem; }
.adv-card .meta { color: var(--muted); font-size: .82rem; }

/* ----------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 18px; border-radius: 11px;
  border: 1px solid var(--line-soft); background: rgba(255, 255, 255, .06); color: var(--text); font: 600 .95rem var(--f-ui);
  cursor: pointer; transition: all .2s; white-space: nowrap; text-decoration: none;
}
.btn:hover { background: rgba(255, 255, 255, .11); color: #fff; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-gold { background: linear-gradient(135deg, #e8cc8a, #c9a45c 45%, #9c7433); color: #1b1309; border-color: transparent; box-shadow: 0 6px 20px rgba(201, 164, 92, .25); }
.btn-gold:hover { color: #000; filter: brightness(1.08); background: linear-gradient(135deg, #f1d999, #d4af67 45%, #a77d3b); }
.btn-ember { background: linear-gradient(135deg, #d9693c, #a7411f); color: #fff; border-color: transparent; }
.btn-danger { background: rgba(224, 106, 92, .14); border-color: rgba(224, 106, 92, .35); color: #ffb3aa; }
.btn-danger:hover { background: rgba(224, 106, 92, .25); }
.btn-ghost { background: transparent; }
.btn-sm { padding: 7px 12px; font-size: .84rem; border-radius: 9px; }
.btn-block { width: 100%; }
.btn-social { width: 100%; background: #fff; color: #1f1f1f; border-color: #fff; }
.btn-social:hover { background: #f0f0f0; color: #000; }
.btn-social.github { background: #1d2025; color: #fff; border-color: #33373d; }
.btn-social.github:hover { background: #2a2e35; color: #fff; }
.btn-social svg { width: 18px; height: 18px; }

/* ----------------------------------------------------------- forms */
.form-row { margin-bottom: 14px; }
.form-row label, .label { display: block; font-size: .85rem; font-weight: 600; color: #d8cdb9; margin-bottom: 6px; }
.input, select.input, textarea.input {
  width: 100%; padding: 11px 13px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .12); background: rgba(0, 0, 0, .35);
  color: var(--text); font: 15px var(--f-ui); transition: border-color .2s, box-shadow .2s; outline: none;
}
.input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201, 164, 92, .18); }
textarea.input { min-height: 110px; resize: vertical; line-height: 1.5; }
textarea.input.code { font: 13px/1.55 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; min-height: 220px; }
select.input option { background: #18130f; }
.input[type=color] { height: 42px; padding: 4px; cursor: pointer; }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: .92rem; color: var(--text); }
.check input { width: 17px; height: 17px; accent-color: var(--gold); }
.help { font-size: .8rem; color: var(--muted); margin-top: 4px; }
.error-text { color: #ffb0a6; font-size: .82rem; margin-top: 4px; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: .8rem; margin: 16px 0; text-transform: uppercase; letter-spacing: .1em; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: rgba(255, 255, 255, .1); }

/* ----------------------------------------------------------- alerts */
.alert { padding: 12px 16px; border-radius: 12px; margin-bottom: 16px; border: 1px solid; font-size: .93rem; }
.alert-success { background: rgba(95, 185, 133, .12); border-color: rgba(95, 185, 133, .35); color: #b9efcf; }
.alert-error { background: rgba(224, 106, 92, .12); border-color: rgba(224, 106, 92, .35); color: #ffc4bc; }
.alert-info { background: rgba(120, 170, 220, .1); border-color: rgba(120, 170, 220, .3); color: #cfe3f7; }
.alert ul { margin: 0; padding-left: 18px; }

/* ----------------------------------------------------------- tables */
.table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid var(--line-soft); }
table.table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.table th { text-align: left; font-weight: 600; color: var(--muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .06em; padding: 11px 14px; background: rgba(255, 255, 255, .03); white-space: nowrap; }
.table td { padding: 11px 14px; border-top: 1px solid var(--line-soft); vertical-align: middle; }
.table tr:hover td { background: rgba(255, 255, 255, .02); }
.amount-pos { color: #9be3b9; font-weight: 600; }
.amount-neg { color: #ffb0a6; font-weight: 600; }

/* ----------------------------------------------------------- tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line-soft); margin-bottom: 20px; overflow-x: auto; scrollbar-width: none; }
.tabs a, .tabs button { padding: 10px 14px; color: var(--muted); border: 0; background: none; font: 600 .9rem var(--f-ui); cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap; }
.tabs .active { color: var(--gold-2); border-bottom-color: var(--gold); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ----------------------------------------------------------- packages */
.package { position: relative; text-align: center; padding: 26px 20px; display: flex; flex-direction: column; gap: 6px; }
.package.featured { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold), 0 18px 40px rgba(201, 164, 92, .15); }
.package .ribbon { position: absolute; top: -11px; left: 50%; transform: translateX(-50%); }
.package .credits { font-family: var(--f-head); font-size: 2.3rem; color: var(--gold-2); line-height: 1; }
.package .price { font-size: 1.25rem; font-weight: 700; margin: 6px 0 2px; }
.package .actions { display: flex; flex-direction: column; gap: 8px; margin-top: auto; padding-top: 12px; }

/* ----------------------------------------------------------- modal */
.modal { position: fixed; inset: 0; z-index: 100; display: none; align-items: center; justify-content: center; padding: 16px; background: rgba(0, 0, 0, .7); backdrop-filter: blur(4px); }
.modal.open { display: flex; }
.modal-box { width: 100%; max-width: 520px; max-height: 90vh; overflow: auto; background: var(--card-solid); border: 1px solid var(--line); border-radius: 16px; padding: 22px; box-shadow: var(--shadow); }

/* ----------------------------------------------------------- pagination */
.pagination { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; margin-top: 18px; }
.pagination a, .pagination span { min-width: 36px; padding: 7px 11px; border-radius: 9px; text-align: center; border: 1px solid var(--line-soft); color: var(--muted); font-size: .88rem; }
.pagination .active { background: rgba(201, 164, 92, .18); color: var(--gold-2); border-color: var(--line); }
.pagination .disabled { opacity: .4; }

/* ----------------------------------------------------------- landing / guest */
.guest-body { min-height: 100vh; position: relative; overflow-x: hidden; background: #050403; }
.guest-bg { position: fixed; inset: 0; background: center/cover no-repeat; transform: scale(1.04); animation: bgdrift 40s ease-in-out infinite alternate; }
.guest-bg::after { content: ''; position: absolute; inset: 0; background:
  linear-gradient(90deg, rgba(5, 4, 3, .88) 0%, rgba(5, 4, 3, .55) 45%, rgba(5, 4, 3, .35) 70%, rgba(5, 4, 3, .75) 100%),
  linear-gradient(180deg, rgba(5, 4, 3, .4), transparent 30%, transparent 70%, rgba(5, 4, 3, .9)); }
@keyframes bgdrift { from { transform: scale(1.04) translate(0, 0); } to { transform: scale(1.1) translate(-1.5%, -1%); } }
.embers { position: fixed; inset: 0; pointer-events: none; overflow: hidden; }
.embers i { position: absolute; bottom: -10px; width: 3px; height: 3px; border-radius: 50%; background: #ffb46b; box-shadow: 0 0 8px 2px rgba(255, 140, 60, .7); opacity: 0; animation: ember linear infinite; }
@keyframes ember { 0% { transform: translate(0, 0); opacity: 0; } 10% { opacity: .9; } 100% { transform: translate(60px, -105vh); opacity: 0; } }
.guest-wrap { position: relative; z-index: 2; min-height: 100vh; display: flex; flex-direction: column; }
.guest-top { display: flex; align-items: center; justify-content: space-between; padding: 22px 28px; }
.guest-main { flex: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: center; padding: 20px 28px 40px; max-width: 1240px; width: 100%; margin: 0 auto; }
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.9rem); line-height: 1.05; margin-bottom: 18px; text-shadow: 0 4px 30px rgba(0, 0, 0, .6); }
.hero h1 span { background: linear-gradient(135deg, #f6e1a8, #c9a45c 60%, #a8742f); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lead { font: 1.25rem/1.55 var(--f-read); color: #e6dccb; max-width: 560px; margin-bottom: 26px; }
.hero-features { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 26px; }
.hero-features div { display: flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 12px; background: rgba(10, 8, 6, .55); border: 1px solid rgba(255, 255, 255, .08); font-size: .88rem; color: #e6dccb; backdrop-filter: blur(8px); }
.hero-games { display: flex; gap: 10px; }
.hero-games a { width: 92px; aspect-ratio: 3/4; border-radius: 10px; background: center/cover; border: 1px solid rgba(255, 255, 255, .14); box-shadow: 0 8px 20px rgba(0, 0, 0, .5); transition: transform .2s; }
.hero-games a:hover { transform: translateY(-4px) rotate(-1deg); }
.auth-panel { padding: 26px; width: 100%; max-width: 430px; justify-self: end; }
.auth-panel h2 { text-align: center; margin-bottom: 4px; }
.auth-panel .sub { text-align: center; color: var(--muted); margin-bottom: 18px; font-size: .92rem; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: rgba(0, 0, 0, .35); border-radius: 12px; margin-bottom: 18px; }
.auth-tabs button { padding: 9px; border: 0; border-radius: 9px; background: none; color: var(--muted); font: 600 .92rem var(--f-ui); cursor: pointer; }
.auth-tabs button.active { background: rgba(201, 164, 92, .2); color: var(--gold-2); }
.guest-footer { text-align: center; padding: 16px; color: rgba(236, 228, 214, .5); font-size: .8rem; }
.auth-single { display: flex; justify-content: center; align-items: center; flex: 1; padding: 20px; }
.auth-single .auth-panel { justify-self: center; }
@media (max-width: 920px) {
  .guest-main { grid-template-columns: 1fr; gap: 26px; padding-top: 0; }
  .auth-panel { justify-self: center; }
  .hero { text-align: center; }
  .hero .lead { margin-left: auto; margin-right: auto; }
  .hero-features { justify-content: center; }
  .hero-games { display: none; }
  .guest-top { padding: 16px; }
}

.empty { text-align: center; padding: 40px 20px; color: var(--muted); border: 1px dashed var(--line); border-radius: var(--radius); }
.footer { border-top: 1px solid var(--line-soft); padding: 22px 0; color: var(--muted); font-size: .82rem; text-align: center; }

.game-hero { position: relative; border-radius: 20px; overflow: hidden; min-height: 340px; display: flex; align-items: flex-end; background: #000 center/cover; border: 1px solid var(--line-soft); }
.game-hero::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, .1), rgba(8, 6, 5, .95) 85%); }
.game-hero .content { position: relative; padding: 30px; max-width: 760px; }
.game-hero .content p { font: 1.12rem/1.6 var(--f-read); color: #e6dccb; }
.loading-overlay { position: fixed; inset: 0; z-index: 200; display: none; flex-direction: column; gap: 16px; align-items: center; justify-content: center; background: rgba(5, 4, 3, .88); color: var(--gold-2); font-family: var(--f-head); letter-spacing: .08em; text-align: center; padding: 20px; }
.loading-overlay.open { display: flex; }
.spinner { width: 46px; height: 46px; border-radius: 50%; border: 3px solid rgba(201, 164, 92, .25); border-top-color: var(--gold); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ----------------------------------------------------------- ícones SVG (sprite) */
.i { width: 1.1em; height: 1.1em; display: inline-block; vertical-align: -.2em; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
.i-lg { width: 1.5em; height: 1.5em; }
.i-xl { width: 3rem; height: 3rem; }
.i-hero { width: 4rem; height: 4rem; color: var(--gold-2); }
.btn .i { width: 1.15em; height: 1.15em; }
.ico-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(44px, 1fr)); gap: 6px; max-height: 190px; overflow-y: auto; padding: 6px; border: 1px solid rgba(255, 255, 255, .1); border-radius: 10px; background: rgba(0, 0, 0, .25); }
.ico-pick label { display: flex; align-items: center; justify-content: center; height: 40px; border-radius: 8px; cursor: pointer; color: var(--muted); border: 1px solid transparent; }
.ico-pick label:hover { color: var(--text); background: rgba(255, 255, 255, .06); }
.ico-pick input { position: absolute; opacity: 0; pointer-events: none; }
.ico-pick input:checked + .i { color: var(--gold-2); }
.ico-pick label:has(input:checked) { border-color: var(--gold); background: rgba(201, 164, 92, .15); }
.ico-pick .i { width: 22px; height: 22px; }
.item-ico { width: 1.4em; height: 1.4em; color: var(--gold-2); vertical-align: middle; }
.hero-features .i, .badge .i, .dropdown-menu .i, .admin-side nav .i { color: var(--gold-2); }
.credit-pill .i { width: 1em; height: 1em; }
.admin-side nav a .i { width: 18px; height: 18px; }

/* ----------------------------------------------------------- ajustes de layout (v1.1) */
.brand { white-space: nowrap; min-width: 0; }
.brand img { flex-shrink: 0; }
.credit-pill { white-space: nowrap; line-height: 1; padding: 8px 12px; }
.credit-pill .num { font-weight: 700; }
.credit-pill .pill-label { font-weight: 500; font-size: .82rem; opacity: .85; }
.avatar-btn { display: block; line-height: 0; }
.dropdown-head { padding: 8px 12px 10px; display: flex; flex-direction: column; gap: 2px; border-bottom: 1px solid var(--line-soft); margin-bottom: 4px; }
.dropdown-head strong { color: var(--text); }
.dropdown-head small { color: var(--muted); overflow: hidden; text-overflow: ellipsis; }
.dropdown-menu a, .dropdown-menu button { display: flex; align-items: center; gap: 10px; }
.nav-lang { display: none; }

.badge { white-space: nowrap; line-height: 1.4; }
.game-card .badges { left: 10px; right: 10px; flex-wrap: wrap; }
.game-card .badges .badge { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.game-card .body { margin-top: -40px; }
.game-card h3 { text-shadow: 0 2px 10px rgba(0, 0, 0, .8); }
.game-card .flex.between { gap: 10px; }
.game-card small { min-width: 0; }

.stat .num { display: flex; align-items: center; gap: 8px; }
.stat .num .i { width: .8em; height: .8em; }
.package .credits { display: flex; align-items: center; justify-content: center; gap: 8px; }
.package .credits .i { width: .75em; height: .75em; }
.packages-grid { margin: 22px 0 32px; }
.credits-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; flex-wrap: wrap; margin-bottom: 18px; }
.credits-head > div:first-child { flex: 1 1 320px; }
.credits-head .stat { min-width: 220px; }

@media (max-width: 820px) {
  .topbar .container { gap: 10px; }
  .desk-lang { display: none; }
  .nav-lang { display: block; padding: 10px 12px 4px; }
  .nav-right { gap: 8px; }
  .nav-right .credit-pill .pill-label { display: none; }
  .brand { font-size: 1.02rem; gap: 8px; }
  .brand img { width: 26px; height: 26px; }
}
@media (max-width: 520px) {
  .nav-right .pro-badge { display: none; }
  .credit-pill { padding: 7px 10px; font-size: .85rem; }
  .page { padding-top: 20px; }
  .game-hero { min-height: 280px; }
  .game-hero .content { padding: 20px; }
  .card { padding: 18px; }
  h1 { font-size: 1.6rem; }
}
@media (max-width: 380px) {
  .brand-name { display: none; }
}
.game-card .badges .badge-star { margin-left: auto; padding: 4px 7px; }
.badge-star .i { fill: currentColor; }
@media (max-width: 640px) {
  .credits-head .stat { flex: 1 1 100%; }
  .packages-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .package { padding: 20px 12px; }
  .package .credits { font-size: 1.7rem; }
  .package p { display: none; }
}
@media (max-width: 400px) {
  .packages-grid { grid-template-columns: 1fr; }
  .package p { display: block; }
}

/* ----------------------------------------------------------- biblioteca */
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.library-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; flex-wrap: wrap; margin-bottom: 18px; }
.library-head > div { flex: 1 1 320px; }
.library-search { position: relative; flex: 0 1 340px; width: 100%; }
.library-search .i { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.library-search input { width: 100%; padding: 11px 14px 11px 40px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, .12); background: rgba(0, 0, 0, .35); color: var(--text); font: 15px var(--f-ui); outline: none; }
.library-search input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201, 164, 92, .18); }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 22px; scrollbar-width: thin; }
.chip { flex: 0 0 auto; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-soft); background: rgba(255, 255, 255, .04); color: var(--muted); font-size: .88rem; font-weight: 500; white-space: nowrap; }
.chip:hover { color: var(--text); border-color: var(--line); }
.chip.active { background: rgba(201, 164, 92, .18); border-color: var(--gold); color: var(--gold-2); }
.featured-row { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.feature-card { position: relative; min-height: 260px; border-radius: 18px; overflow: hidden; background: #000 center/cover; border: 1px solid var(--line); display: flex; align-items: flex-end; transition: transform .25s, box-shadow .25s; }
.feature-card::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, .05) 25%, rgba(8, 6, 5, .95)); }
.feature-card:hover { transform: translateY(-4px); box-shadow: 0 20px 44px rgba(0, 0, 0, .55); }
.feature-body { position: relative; padding: 20px; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.feature-body h3 { font-size: 1.45rem; margin: 0; color: #fff; text-shadow: 0 2px 12px rgba(0, 0, 0, .8); }
.feature-body p { margin: 0; color: #e6dccb; font: 1.05rem/1.45 var(--f-read); }
@media (max-width: 640px) {
  .library-search { flex-basis: 100%; }
  .featured-row { grid-template-columns: 1fr; }
  .feature-card { min-height: 220px; }
}
