/* ===== RESET / BASE ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  height: 100%;
  display: flex;
  flex-direction: column;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: #0b0c0f;
  color: #f5f6fa;
}

/* o main cresce, empurrando o footer para o fundo */
main { flex: 1 0 auto; }

/* footer fixo ao fim do ecrã */
.site-footer {
  flex-shrink: 0;
  margin-top: auto;
  position: relative;
  bottom: 0;
  width: 100%;
  background: #0a0b0d;
  border-top: 1px solid rgba(255,255,255,0.06);
  color: #b3b8c2;
  font-size: 14px;
  padding: 20px 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
}
.footer-links a {
  color: #b3b8c2;
  text-decoration: none;
  margin-right: 14px;
  transition: color .2s;
}
.footer-links a:hover { color: #fff; }

/* ===== CONTAINERS ===== */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
}

/* ===== HEADER ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: linear-gradient(180deg, rgba(0,0,0,.8), rgba(0,0,0,.3));
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
}
.brand-combo {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
}
.brand {
  display: block;
  height: 26px;
  object-fit: contain;
}
.brand-divider {
  display: inline-block;
  width: 1px;
  height: 20px;
  background: rgba(255,255,255,.3);
}
.brand-text {
  color: #fff;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: .4px;
}

/* idiomas */
.lang-switch a {
  color: #fff;
  text-decoration: none;
  margin-left: 8px;
  padding: 4px 8px;
  border-radius: 50%;
  border: 1px solid transparent;
  opacity: .7;
  font-size: 13px;
  font-weight: 600;
}
.lang-switch a:hover { opacity: 1; }
.lang-switch a.active {
  border-color: #fff;
  opacity: 1;
  background: #fff;
  color: #000;
}

/* ===== HERO ===== */
.hero {
  padding: 60px 0 40px;
  display: flex;
  justify-content: center;
}
.hero .panel {
  background: #f5f5f5;
  color: #1d1f22;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  padding: 32px;
  text-align: center;
  width: 100%;
}
.hero-title {
  font-size: 28px;
  font-weight: 700;
  color: #1e1e1e;
  margin-bottom: 6px;
}
.hero-sub {
  color: #555;
  margin-bottom: 20px;
}
.ctas {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* botões */
.btn {
  display: inline-block;
  padding: 10px 18px;
  border-radius: 10px;
  font-weight: 600;
  text-decoration: none;
  transition: all .2s;
  box-shadow: 0 3px 6px rgba(0,0,0,.15);
}
.btn:hover { transform: translateY(-2px); }
.btn { background: #70e389; color: #041307; }
.btn.alt { background: #49a7ff; color: #fff; }
.btn.ghost { background: #e7e7e7; color: #1c1c1c; }

/* ===== NEWS GRID ===== */
.section {
  padding: 40px 0;
}
.section-title {
  text-align: center;
  font-size: 22px;
  margin-bottom: 28px;
  font-weight: 700;
}

/* layout da grid */
.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  align-items: stretch;
}
@media (min-width: 768px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1100px) {
  .grid { grid-template-columns: repeat(3, 1fr); }
}

/* cards */
.card {
  background: #16181b;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 18px rgba(0,0,0,.25);
  display: flex;
  flex-direction: column;
  transition: transform .2s;
}
.card:hover { transform: translateY(-4px); }
.card .thumb img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}
.card .body {
  padding: 14px 16px 18px;
}
.card h3 {
  font-size: 17px;
  margin-bottom: 6px;
}
.card h3 a {
  color: #fff;
  text-decoration: none;
}
.card h3 a:hover {
  text-decoration: underline;
}
.card .summary {
  color: #b3b8c2;
  font-size: 14px;
  margin-bottom: 10px;
}
.card .meta {
  font-size: 13px;
  color: #9aa0aa;
}

/* paginação */
.pagination {
  text-align: center;
  margin-top: 30px;
}
.pagination .page {
  display: inline-block;
  color: #fff;
  background: #222;
  text-decoration: none;
  padding: 6px 12px;
  border-radius: 6px;
  margin: 0 4px;
  transition: background .2s;
}
.pagination .page:hover { background: #333; }
.pagination .current {
  background: #49a7ff;
}

/* ===== ARTICLE ===== */
.article-wrap {
  display: flex;
  justify-content: center;
  padding: 60px 16px;
}
.article {
  max-width: 800px;
  background: #fff;
  color: #111;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,.25);
}
.article h1 {
  font-size: 28px;
  margin-bottom: 8px;
}
.article .meta {
  font-size: 14px;
  color: #777;
  margin-bottom: 18px;
}
.article .heroimg img {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 18px;
}
.article .content {
  font-size: 16px;
  line-height: 1.6;
  color: #333;
}

/* ===== ADMIN (usa os mesmos botões/cores) ===== */
.admin-actions .btn {
  padding: 8px 14px;
  font-size: 14px;
}

/* ===== BG GAME ===== */
.bg-wrap {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: #0b0c0f url('/assets/img/website.png') center/cover no-repeat;
  opacity: 0.25;
}
/* ===================== ADMIN THEME ++ ===================== */

/* fundo do admin (reaproveita o bg do site) */
body.admin { background: #0b0c0f; }
body.admin .bg-wrap { opacity: .18; }

/* topbar já usa .site-header; só reforçamos o espaçamento */
.admin .header-inner { padding: 10px 0; }

/* layout principal do admin */
.admin main { padding: 18px 0 26px; }
.admin .admin-panel { 
  max-width: 1100px; margin: 14px auto; padding: 18px; 
  background: rgba(22,24,27,.85); border: 1px solid rgba(255,255,255,.06);
  border-radius: 12px; box-shadow: 0 8px 22px rgba(0,0,0,.35);
}

/* cards de estatísticas no topo do dashboard */
.stat-grid {
  display: grid; gap: 14px; grid-template-columns: repeat(1, 1fr); margin-bottom: 16px;
}
@media (min-width: 768px){ .stat-grid { grid-template-columns: repeat(3, 1fr); } }
.stat-card {
  background: #14161a; border: 1px solid rgba(255,255,255,.06); border-radius: 12px;
  padding: 14px 16px; display: flex; flex-direction: column; gap: 4px;
}
.stat-card .label { color:#9aa0aa; font-size:13px; }
.stat-card .value { font-size:22px; font-weight:800; color:#fff; }

/* tabela */
.admin-table { width:100%; border-collapse: collapse; }
.admin-table thead th {
  text-align:left; font-size:13px; color:#b3b8c2; font-weight:800;
  border-bottom:1px solid rgba(255,255,255,.08); padding:10px 12px;
  position: sticky; top: 58px; background:#16181b; /* cabeçalho “fixo” */
}
.admin-table td {
  padding:12px; border-bottom:1px solid rgba(255,255,255,.06); color:#f5f6fa;
}
.admin-table tbody tr:hover { background: rgba(255,255,255,.03); }

/* badges */
.badge { display:inline-block; font-size:12px; padding:4px 8px; border-radius:999px; background:#22252b; color:#d9dee6; border:1px solid rgba(255,255,255,.06); }

/* ações */
.table-actions a { text-decoration:none; margin-right:10px; color:#49a7ff; }
.table-actions a:hover { text-decoration: underline; }

/* formulário 2 colunas responsivo */
.form-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 820px){ .form-grid { grid-template-columns: 1.2fr 1fr; } }
.admin-form label { color:#e9edf5; font-weight:600; margin-bottom:6px; display:block; }
.input, .textarea, .select, .file {
  width:100%; padding:10px 12px; border-radius:10px; border:1px solid rgba(255,255,255,.09);
  background:#0f1115; color:#eef0f4; outline:none;
}
.textarea { min-height: 160px; resize: vertical; }
.file { padding:8px; background:#0f1115; }
.form-row { display:flex; flex-direction:column; gap:8px; }

.form-actions { display:flex; gap:10px; flex-wrap:wrap; margin-top: 8px; }

/* botões admin */
.btn { display:inline-block; padding:10px 16px; border-radius:10px; font-weight:700; text-decoration:none; box-shadow:0 3px 6px rgba(0,0,0,.15); }
.btn.alt { background:#49a7ff; color:#fff; }
.btn.ghost { background:#e7e7e7; color:#1c1c1c; }
.btn-danger { background:#e04f49; color:#fff; }

/* login box central */
.login-wrap {
  min-height: calc(100vh - 120px);
  display:grid; place-items:center; padding: 20px 16px;
}
.login-card {
  width:min(420px, 96%); background:rgba(22,24,27,.9); border:1px solid rgba(255,255,255,.08);
  border-radius:14px; padding:22px; box-shadow:0 12px 32px rgba(0,0,0,.5);
}
.login-card h2 { margin-bottom:8px; }
.login-card .desc { color:#b3b8c2; font-size:14px; margin-bottom:14px; }
.login-card .error { color:#ffb4ae; font-weight:700; margin-bottom:10px; }

/* sticky footer já herdado do site */