/* =========================================================
   legal.css — Política de Privacidade e Termos de Uso
   Mesmo visual da home. Carregar DEPOIS do styles.css.
   ========================================================= */

html { scroll-behavior: smooth; }

body {
  background-image: radial-gradient(circle at 50% -5%, rgba(0,140,255,.22), transparent 45%) !important;
  background-repeat: no-repeat !important;
}

::selection { background: #25d5ff; color: #020817; }

/* ---------- Menu (item atual + submenu Artigos, igual à home) ---------- */
.top-menu a[aria-current="page"] { color: #70e9ff; text-decoration: underline; }
.top-menu a:hover { color: #70e9ff; }

.cw-dropdown { position: relative; display: inline-block; }
.cw-dropdown > summary {
  list-style: none; cursor: pointer; margin: .5rem; color: #fff;
  font-weight: bold; font-size: clamp(12px, 2vw, 16px); font-family: 'VT323', monospace;
}
.cw-dropdown > summary::-webkit-details-marker { display: none; }
.cw-dropdown > summary:hover,
.cw-dropdown[open] > summary { color: #70e9ff; text-decoration: underline; }
.cw-dropdown-panel {
  position: absolute; top: 100%; left: 0; z-index: 1100; min-width: 260px; padding: 8px;
  display: flex; flex-direction: column; text-align: left;
  border: 1px solid #25d5ff; border-radius: 10px; background: #020918;
  box-shadow: 0 10px 28px rgba(0,0,0,.6), 0 0 18px rgba(0,180,255,.15);
}
.top-menu .cw-dropdown-panel a {
  display: block; margin: 0; padding: 9px 12px; border-radius: 6px;
  color: #fff; white-space: nowrap; text-decoration: none;
}
.top-menu .cw-dropdown-panel a:hover,
.top-menu .cw-dropdown-panel a:focus-visible { background: rgba(0,150,255,.22); color: #70e9ff; text-decoration: none; }
.top-menu .cw-dropdown-panel a.cw-dropdown-all {
  margin-top: 4px; border-top: 1px solid rgba(57,217,255,.3); border-radius: 0 0 6px 6px; color: #70e9ff;
}
@media (max-width: 699px) {
  .cw-dropdown { position: static; }
  .cw-dropdown-panel {
    position: fixed; top: var(--nav-h, 60px); left: 8px; right: 8px; min-width: 0;
    max-height: calc(100vh - var(--nav-h, 60px) - 60px); overflow-y: auto;
  }
}

/* ---------- Painel principal ---------- */
.page-content.legal {
  max-width: 960px;
  width: calc(100% - 24px);
  margin: calc(var(--nav-h, 60px) + 24px) auto 90px !important; /* topo: menu fixo / base: rodapé fixo */
  padding: 28px clamp(14px, 3vw, 32px) 32px !important;
  background: linear-gradient(145deg, rgba(3,12,30,.97), rgba(1,6,18,.98)) !important;
  border: 1px solid rgba(57,217,255,.35);
  border-radius: 18px;
  box-shadow: 0 0 35px rgba(0,153,255,.18), inset 0 0 30px rgba(0,120,255,.06);
  color: #e8f7ff;
  font: 400 17px/1.7 'Source Sans Pro', Arial, sans-serif;
  -webkit-user-select: text; user-select: text;
}

/* ---------- Cabeçalho ---------- */
.legal-hero {
  text-align: center;
  padding: 8px 0 26px;
  margin-bottom: 22px;
  border-bottom: 1px solid rgba(57,217,255,.22);
}
.legal h1 {
  margin: 0 0 18px;
  font-family: 'Press Start 2P', monospace;
  font-size: clamp(18px, 3.6vw, 32px);
  line-height: 1.45;
  color: #fff !important;
  text-shadow: 0 0 12px #00aaff, 0 0 30px rgba(0,170,255,.55);
}
.legal .legal-hero p {
  max-width: 780px; margin: 0 auto; padding: 0;
  text-align: center; text-indent: 0; color: #d7edff;
}

/* ---------- Texto ---------- */
.legal p {
  margin: 0 0 14px; padding: 0;
  font-size: 1.06rem; line-height: 1.7;
  text-align: left; text-indent: 0;
}
.legal strong { color: #fff; font-weight: 700; }
.legal em { color: #bfe9ff; }
.legal a {
  color: #7eeaff; text-decoration: underline;
  text-decoration-color: rgba(126,234,255,.4); text-underline-offset: 3px;
}
.legal a:hover { color: #fff; text-decoration-color: #fff; }
.legal a:focus-visible { outline: 3px solid #fff; outline-offset: 3px; border-radius: 3px; }

.legal ul {
  list-style: none; margin: 6px 0 16px; padding: 0;
  font-size: 1.06rem; text-align: left; text-indent: 0;
}
.legal li { position: relative; margin: 0 0 10px; padding-left: 24px; }
.legal li::before {
  content: ""; position: absolute; left: 3px; top: .7em;
  width: 7px; height: 7px; background: #25d5ff;
  transform: rotate(45deg); box-shadow: 0 0 8px rgba(37,213,255,.7);
}
.legal li:last-child { margin-bottom: 0; }

/* ---------- Seções ---------- */
.legal-card {
  margin: 18px 0;
  padding: 22px clamp(14px, 3vw, 26px);
  border: 1px solid rgba(0,190,255,.3);
  border-left: 3px solid #24cfff;
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(7,24,52,.95), rgba(3,8,20,.95));
  box-shadow: inset 0 0 25px rgba(0,120,255,.05);
  scroll-margin-top: calc(var(--nav-h, 60px) + 14px);
}
.legal-card > :last-child { margin-bottom: 0; }

.legal h2 {
  margin: 0 0 12px;
  font-family: 'VT323', monospace; font-weight: 400;
  font-size: clamp(26px, 4vw, 34px); line-height: 1.15;
  text-align: left; color: #63dcff !important;
  text-shadow: 0 2px 4px #000;
}
.legal h3 {
  margin: 22px 0 8px;
  font-family: 'VT323', monospace; font-weight: 400;
  font-size: 1.65rem; line-height: 1.2;
  text-align: left; color: #fff !important;
  text-shadow: 0 2px 4px #000;
}
.legal h3.deny  { color: #ff6f8c !important; }
.legal h3.allow { color: #70ffab !important; }

/* Seção em destaque (partidas oficiais, com dinheiro envolvido) */
.legal-card.is-key {
  border-color: rgba(255,207,90,.45); border-left-color: #ffcf5a;
  box-shadow: 0 0 28px rgba(255,190,60,.08), inset 0 0 25px rgba(255,190,60,.04);
}
.legal-card.is-key h2 { color: #ffd878 !important; }
.legal-card.is-key li::before { background: #ffcf5a; box-shadow: 0 0 8px rgba(255,207,90,.6); }

/* Aviso dentro do texto */
.legal p.legal-note {
  padding: 12px 16px; margin-top: 14px;
  border-left: 3px solid #ffcf5a; border-radius: 0 9px 9px 0;
  background: rgba(255,200,60,.08);
}

/* ---------- Índice ---------- */
.legal-toc {
  padding: 16px 18px;
  border: 1px solid rgba(0,210,255,.32); border-radius: 14px;
  background: rgba(0,20,45,.65);
}
.legal-toc-title {
  margin-bottom: 10px;
  font-family: 'VT323', monospace; font-size: 1.6rem; color: #58d9ff;
}
.legal-toc-grid {
  display: grid; gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.legal .legal-toc-grid a {
  display: flex; align-items: center; min-height: 42px; padding: 6px 12px;
  border: 1px solid rgba(0,210,255,.3); border-radius: 9px;
  background: rgba(0,30,65,.75);
  color: #fff; text-decoration: none; font-size: 1rem; line-height: 1.3;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.legal .legal-toc-grid a:hover {
  transform: translateY(-2px); border-color: #61e7ff; box-shadow: 0 0 18px rgba(0,210,255,.2);
}

/* ---------- Data de atualização ---------- */
.legal p.legal-updated {
  margin: 26px 0 0; text-align: center; color: #9fc4d8; font-size: .98rem;
}
.legal p.legal-updated strong { color: #70e9ff; }

@media (max-width: 600px) {
  .legal-card { padding: 16px 14px; }
  .legal li { padding-left: 20px; }
  .legal-toc { padding: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .legal .legal-toc-grid a { transition: none; }
}
