/*
Theme Name: PlayFilme
Theme URI: https://playfilme.com
Author: PlayFilme
Description: Tema escuro para portal de cinema, séries e cultura pop. Destaque principal, cartões laterais, grade de posts, menu por categorias e aviso de cookies.
Version: 1.0.11
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: playfilme
*/

:root {
  --bg: #0d1630;
  --bg-card: #1a2540;
  --bg-card-hover: #223056;
  --header: #05070d;
  --nav: #2a3fd1;
  --text: #ffffff;
  --muted: #9fb0d4;
  --purple: #a21be0;
  --cyan: #1ee6e0;
  --blue: #2438c8;
  --magenta: #c026d3;
  --radius: 16px;
  --wrap: 1640px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Roboto", "Segoe UI", Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.screen-reader-text { position: absolute; left: -9999px; }

/* ---------- Cabeçalho ---------- */
.site-header { background: var(--header); padding: 18px 0; }
.header-inner { display: flex; align-items: center; gap: 28px; }
.site-logo { display: flex; align-items: center; flex-shrink: 0; }
.site-logo svg, .site-logo img { height: 52px; width: auto; }
.menu-toggle {
  display: none; background: none; border: 0; color: #fff; cursor: pointer; padding: 6px;
}
.search-form {
  flex: 1; display: flex; align-items: center; gap: 10px;
  background: #1a2238; border-radius: 999px; padding: 0 20px; height: 48px;
}
.search-form svg { flex-shrink: 0; color: var(--muted); }
.search-form input[type="search"] {
  flex: 1; background: none; border: 0; outline: 0; color: #fff; font-size: 16px; height: 100%;
}
.search-form input::placeholder { color: var(--muted); }
.user-link { color: #fff; display: flex; flex-shrink: 0; }

/* ---------- Menu ---------- */
.main-nav { background: var(--nav); }
.main-nav ul {
  list-style: none; margin: 0; padding: 0; display: flex; gap: 26px;
  overflow-x: auto; scrollbar-width: none;
}
.main-nav ul::-webkit-scrollbar { display: none; }
.main-nav a {
  display: block; padding: 15px 0; font-weight: 700; font-size: 17px;
  text-transform: uppercase; white-space: nowrap; letter-spacing: .2px;
  border-bottom: 3px solid transparent;
}
.main-nav a:hover, .main-nav .current-menu-item > a, .main-nav .current-cat > a { border-bottom-color: var(--cyan); }

/* ---------- Etiquetas ---------- */
.tag {
  display: inline-block; padding: 4px 11px; border-radius: 6px; font-weight: 700;
  font-size: 15px; text-transform: uppercase; background: var(--blue); color: #fff; line-height: 1.3;
}
.tag.cat-critica, .tag.cat-criticas { background: var(--purple); color: #fff; }
.tag.cat-serie, .tag.cat-series, .tag.cat-lista, .tag.cat-listas { background: var(--cyan); color: #04202a; }
.tag.cat-noticia, .tag.cat-noticias { background: var(--blue); color: #fff; }
.tag.cat-marvel { background: #e11d48; color: #fff; }
.tag.cat-games { background: #16a34a; color: #fff; }
.tag.cat-anime { background: #f97316; color: #fff; }

/* ---------- Home: destaque ---------- */
.home-top { display: grid; grid-template-columns: minmax(0, 1.9fr) minmax(0, 1fr); gap: 28px; align-items: stretch; padding: 50px 0 28px; }
.hero {
  position: relative; width: 100%; min-width: 0; align-self: start; border-radius: var(--radius); overflow: hidden; min-height: 0; aspect-ratio: 16 / 9;
  display: flex; align-items: flex-end; background: #111a33;
}
.hero img.bg-blur { position: absolute; inset: -30px; width: calc(100% + 60px); height: calc(100% + 60px); max-width: none; object-fit: cover; filter: blur(28px) brightness(.55); }
.hero img.bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; object-position: center center; }
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.92) 5%, rgba(0,0,0,.35) 55%, rgba(0,0,0,0) 100%);
}
.hero .tag { position: absolute; top: 20px; left: 20px; z-index: 2; }
.hero-body { position: relative; z-index: 2; padding: 28px 28px 32px; }
.hero h2 { margin: 0; font-size: clamp(26px, 3.4vw, 44px); line-height: 1.15; font-weight: 800; }

.side-list { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.side-list .side-card { flex: 1 1 0; min-height: 0; }
.side-card {
  display: flex; flex: 1; background: var(--bg-card); border-radius: var(--radius);
  overflow: hidden; transition: background .2s;
}
.side-card:hover { background: var(--bg-card-hover); }
.side-card .thumb { width: 42%; flex-shrink: 0; position: relative; background: #111a33; }
.side-card .thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.side-card .info { padding: 14px 18px; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; justify-content: center; }
.side-card h3 { margin: 0; font-size: 19px; line-height: 1.3; font-weight: 700; }

/* ---------- Grade ---------- */
.grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 24px; padding: 20px 0 40px; }
.card { background: var(--bg-card); border-radius: var(--radius); overflow: hidden; transition: transform .2s, background .2s; display: flex; flex-direction: column; }
.card:hover { transform: translateY(-4px); background: var(--bg-card-hover); }
.card .thumb { aspect-ratio: 16/10; position: relative; background: #111a33; }
.card .thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card .info { padding: 16px; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.card h3 { margin: 0; font-size: 18px; line-height: 1.3; font-weight: 700; }
.card .date { color: var(--muted); font-size: 14px; }
.placeholder { background: linear-gradient(135deg, #3b1c8c, #1b2a6b 55%, #0a6b78); width: 100%; height: 100%; position: absolute; inset: 0; }

.section-title { font-size: 30px; font-weight: 800; margin: 40px 0 0; }
.section-title span { color: var(--cyan); }

.pagination { display: flex; gap: 8px; justify-content: center; padding: 10px 0 50px; flex-wrap: wrap; }
.pagination a, .pagination span {
  background: var(--bg-card); padding: 10px 16px; border-radius: 10px; font-weight: 700;
}
.pagination .current, .pagination a:hover { background: var(--nav); }

/* ---------- Post / página ---------- */
article.single { max-width: 800px; margin: 0 auto; padding: 50px 20px 60px; }
article.single h1 { font-size: clamp(30px, 4vw, 46px); line-height: 1.15; margin: 16px 0 12px; font-weight: 800; }
article.single .meta { color: var(--muted); font-size: 15px; margin-bottom: 26px; }
article.single .featured { border-radius: var(--radius); overflow: hidden; margin-bottom: 30px; }
article.single .featured img { width: 100%; height: auto; display: block; }
.entry { font-size: 19px; line-height: 1.8; color: #e6ecfb; }
.entry h2, .entry h3 { color: #fff; line-height: 1.25; margin-top: 1.8em; }
.entry a { color: var(--cyan); text-decoration: underline; }
.entry blockquote { border-left: 4px solid var(--purple); margin: 1.5em 0; padding: 4px 0 4px 20px; color: var(--muted); }
.entry img { border-radius: 12px; }
.entry iframe { max-width: 100%; }
.post-tags a { display: inline-block; background: var(--bg-card); padding: 4px 12px; border-radius: 999px; margin: 20px 8px 0 0; font-size: 14px; }
.archive-head { padding: 50px 0 0; }
.archive-head h1 { margin: 0; font-size: 38px; }
.archive-head p { color: var(--muted); margin: 6px 0 0; }
.comments-area { margin-top: 50px; }
.comments-area input[type="text"], .comments-area input[type="email"], .comments-area input[type="url"], .comments-area textarea {
  width: 100%; background: var(--bg-card); border: 1px solid #2d3b63; color: #fff; padding: 12px; border-radius: 10px;
}
.comments-area input[type="submit"] { background: var(--nav); color: #fff; border: 0; padding: 12px 24px; border-radius: 10px; font-weight: 700; cursor: pointer; }
.comments-area ol { list-style: none; padding: 0; }
.comments-area li { background: var(--bg-card); border-radius: 12px; padding: 16px; margin-bottom: 14px; }

/* ---------- Rodapé ---------- */
.site-footer { background: var(--header); padding: 40px 0 110px; margin-top: 30px; color: var(--muted); }
.footer-inner { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; align-items: center; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 22px; flex-wrap: wrap; }
.site-footer a:hover { color: var(--cyan); }
.site-footer .copy { width: 100%; font-size: 14px; border-top: 1px solid #1a2238; padding-top: 20px; }

/* ---------- Cookies ---------- */
.cookie-bar {
  position: fixed; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 999;
  width: min(1100px, calc(100% - 24px)); background: #0a0f1d; border: 1px solid #1f2b4d; border-radius: 12px;
  padding: 18px 22px; display: none; align-items: center; justify-content: space-between; gap: 20px;
  box-shadow: 0 10px 40px rgba(0,0,0,.5); font-size: 16px;
}
.cookie-bar.show { display: flex; }
.cookie-bar a { text-decoration: underline; }
.cookie-bar button {
  background: var(--nav); color: #fff; border: 0; font-weight: 700; padding: 12px 26px; border-radius: 8px;
  cursor: pointer; font-size: 16px; flex-shrink: 0;
}

/* ---------- Autor e Leia a seguir ---------- */
.author-box { display: flex; gap: 18px; align-items: center; background: var(--bg-card); border-radius: 12px; padding: 20px; margin: 36px 0; }
.author-box img { border-radius: 50%; flex-shrink: 0; }
.author-box p { margin: 6px 0 0; color: #c9d6f2; font-size: 16px; }
.read-next h2 { margin: 10px 0 16px; font-size: 26px; }
.read-next-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.rn-card { background: var(--bg-card); border-radius: 12px; overflow: hidden; display: block; }
.rn-card img { width: 100%; height: 130px; object-fit: cover; display: block; }
.rn-card span { display: block; padding: 12px 14px 16px; font-weight: 700; font-size: 16px; line-height: 1.3; }
@media (max-width: 640px) { .read-next-grid { grid-template-columns: 1fr; } .author-box { flex-direction: column; text-align: center; } }

/* ---------- Responsivo ---------- */
@media (min-width: 1001px) { .main-nav ul { justify-content: space-between; } .main-nav a { font-size: 18px; } }
@media (min-width: 1201px) { .grid { grid-template-columns: repeat(5, minmax(0, 253px)); justify-content: space-between; } }
@media (max-width: 1200px) { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 1000px) {
  .home-top { grid-template-columns: 1fr; }
  .hero { min-height: 0; aspect-ratio: 16 / 10; }
  .grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .site-header { padding: 12px 0; }
  .header-inner { flex-wrap: wrap; gap: 12px; }
  .site-logo svg, .site-logo img { height: 40px; }
  .search-form { order: 3; flex-basis: 100%; height: 44px; }
  .user-link { margin-left: auto; }
  .main-nav ul { gap: 22px; }
  .main-nav a { font-size: 16px; padding: 12px 0; }
  .home-top { padding-top: 24px; }
  .hero { min-height: 340px; }
  .side-card h3 { font-size: 17px; }
  .grid { grid-template-columns: 1fr; }
  .cookie-bar { flex-direction: column; align-items: stretch; text-align: left; font-size: 14px; }
  .entry { font-size: 17px; }
}

/* ---------- Painel de login (lateral) ---------- */
body.no-scroll { overflow: hidden; }
.user-overlay { position: fixed; inset: 0; background: rgba(5,7,13,.6); opacity: 0; transition: opacity .25s; z-index: 998; }
.user-overlay.open { opacity: 1; }
.user-panel {
  position: fixed; top: 0; right: 0; height: 100%; width: min(480px, 100%);
  background: #4a54e8; color: #fff; padding: 56px 40px 40px; overflow-y: auto;
  transform: translateX(100%); transition: transform .25s ease; z-index: 999;
}
.user-panel.open { transform: translateX(0); }
.user-panel[hidden], .user-overlay[hidden] { display: none; }
.user-close { position: absolute; top: 14px; right: 18px; background: none; border: 0; color: #fff; font-size: 34px; line-height: 1; cursor: pointer; }
.user-panel h2 { font-size: 44px; margin: 0 0 6px; letter-spacing: .5px; text-transform: uppercase; }
.user-panel h2::after { content: ""; display: block; width: 64px; height: 3px; background: var(--cyan); margin-top: 10px; }
.user-sub { color: #dfe4ff; margin: 14px 0 22px; }
.user-form label { display: block; font-size: 12px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; margin: 18px 0 6px; }
.user-form input[type="text"], .user-form input[type="password"] {
  width: 100%; padding: 13px 14px; border: 2px solid transparent; border-radius: 4px; font-size: 16px; background: #fff; color: #111;
}
.user-form input:focus { outline: none; border-color: var(--cyan); }
.user-row { display: flex; justify-content: space-between; align-items: center; margin: 16px 0 22px; font-size: 13px; }
.user-row a { text-decoration: underline; color: #dfe4ff; }
.user-form .user-check { display: flex; gap: 8px; align-items: center; margin: 0; letter-spacing: .4px; }
.user-btn { display: block; width: 100%; text-align: center; background: #0d1cc2; color: #fff; border: 2px solid #0d1cc2; padding: 14px; font-size: 14px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; border-radius: 4px; cursor: pointer; }
.user-btn:hover { background: #0a169b; }
.user-btn-alt { background: transparent; border-color: #fff; margin-top: 10px; }
.user-btn-alt:hover { background: rgba(255,255,255,.12); }
.user-new { text-align: center; margin: 30px 0 12px; }
.user-actions { margin-top: 10px; }

.user-note { font-size: 13px; color: #dfe4ff; margin: 16px 0 20px; }
.user-note a { text-decoration: underline; }
.user-form input[type="email"] { width: 100%; padding: 13px 14px; border: 2px solid transparent; border-radius: 4px; font-size: 16px; background: #fff; color: #111; }
.user-form input[type="email"]:focus { outline: none; border-color: var(--cyan); }
.admin-bar .user-panel { top: 32px; height: calc(100% - 32px); }
.admin-bar .user-close { top: 10px; }
@media (max-width: 782px) { .admin-bar .user-panel { top: 46px; height: calc(100% - 46px); } }

.user-or { text-align: center; margin: 22px 0 12px; }
.user-social { display: flex; justify-content: center; }
.user-social .nsl-container-buttons { width: 100%; }
.user-social a { display: block; }
