/*
Theme Name:  This Must Be Film
Description: Child theme para thismustbethefilm.com — revista de cinema
Author:      This Must Be Film
Template:    blocksy
Version:     1.0.0
Text Domain: thismustbethefilm
*/

/* ═══════════════════════════════════════════════════════════════════════════════
   VARIÁVEIS GLOBAIS
═══════════════════════════════════════════════════════════════════════════════ */
:root {
  --tmbtf-black:      #0a0a0a;
  --tmbtf-white:      #ffffff;
  --tmbtf-orange:     #e85d04;
  --tmbtf-orange-alt: #ff7a20;
  --tmbtf-gray-light: #f5f5f5;
  --tmbtf-gray-mid:   #767676;
  --tmbtf-gray-dark:  #2a2a2a;

  --tmbtf-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --tmbtf-sans:  'Inter', system-ui, -apple-system, sans-serif;
}


/* ═══════════════════════════════════════════════════════════════════════════════
   BASE
═══════════════════════════════════════════════════════════════════════════════ */
body {
  font-family: var(--tmbtf-sans);
  color: var(--tmbtf-black);
  background-color: var(--tmbtf-white);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--tmbtf-serif);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

a {
  color: var(--tmbtf-black);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--tmbtf-orange);
}

p {
  line-height: 1.75;
}


/* ═══════════════════════════════════════════════════════════════════════════════
   HEADER
═══════════════════════════════════════════════════════════════════════════════ */

/* Fundo preto — aplicado em todas as camadas do Blocksy */
#header,
#header .header-desktop,
#header [data-row="main"],
#header [data-row="top"],
#header [data-row="bottom"],
.ct-header {
  background-color: var(--tmbtf-black) !important;
}

/* Forçar texto branco em TODO o header */
#header,
#header * {
  color: var(--tmbtf-white) !important;
  border-color: transparent !important;
}

/* Hover laranja */
#header a:hover,
#header a:hover *,
#header .ct-menu-anchor:hover {
  color: var(--tmbtf-orange) !important;
}

/* Item de menu ativo */
#header .current-menu-item > a,
#header .current-menu-item > .ct-menu-anchor {
  color: var(--tmbtf-orange) !important;
}

/* Logo SVG: inverte para branco */
#header .ct-site-logo-container img {
  filter: brightness(0) invert(1);
}

/* Nome do site em texto */
#header .site-title a,
#header .ct-site-logo a {
  font-family: var(--tmbtf-serif) !important;
  font-size: 1.3rem !important;
  font-weight: 700 !important;
  letter-spacing: -0.02em !important;
}

/* Ícone de busca */
#header .ct-search-icon svg,
#header .ct-search-icon path {
  fill: var(--tmbtf-white) !important;
  stroke: var(--tmbtf-white) !important;
}

/* Dropdown: fundo preto, borda laranja no topo */
#header .sub-menu,
#header .ct-header-cart__dropdown {
  background-color: #111111 !important;
  border-top: 2px solid var(--tmbtf-orange) !important;
}

#header .sub-menu a {
  color: var(--tmbtf-white) !important;
}

#header .sub-menu a:hover {
  color: var(--tmbtf-orange) !important;
  background-color: #1a1a1a !important;
}


/* ═══════════════════════════════════════════════════════════════════════════════
   NAVEGAÇÃO PRINCIPAL
═══════════════════════════════════════════════════════════════════════════════ */
#header .primary-menu-ul > li > a,
#header .primary-menu-ul > li > .ct-menu-anchor {
  font-family: var(--tmbtf-sans) !important;
  font-size: 0.7rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.12em !important;
  padding: 8px 0 !important;
  position: relative !important;
}

/* Sublinhado laranja animado no hover */
#header .primary-menu-ul > li > a::after,
#header .primary-menu-ul > li > .ct-menu-anchor::after {
  content: '' !important;
  position: absolute !important;
  bottom: 4px !important;
  left: 0 !important;
  width: 0 !important;
  height: 2px !important;
  background-color: var(--tmbtf-orange) !important;
  transition: width 0.2s ease !important;
}

#header .primary-menu-ul > li > a:hover::after,
#header .primary-menu-ul > li > .ct-menu-anchor:hover::after,
#header .primary-menu-ul > li.current-menu-item > a::after {
  width: 100% !important;
}


/* ═══════════════════════════════════════════════════════════════════════════════
   HOMEPAGE / LISTAGEM DE POSTS
═══════════════════════════════════════════════════════════════════════════════ */

/* Título da categoria/tag no topo das páginas de arquivo */
.page-title,
.ct-archive-title {
  font-family: var(--tmbtf-serif) !important;
  font-size: clamp(2rem, 5vw, 3.5rem) !important;
  font-weight: 700 !important;
  letter-spacing: -0.03em !important;
  border-bottom: 3px solid var(--tmbtf-black);
  padding-bottom: 1rem;
  margin-bottom: 2.5rem !important;
}

/* Cards de post */
.ct-post-card {
  border: none !important;
  box-shadow: none !important;
  transition: transform 0.2s ease !important;
}

.ct-post-card:hover {
  transform: translateY(-3px);
}

/* Imagem do card */
.ct-post-card .ct-media-container {
  overflow: hidden;
}

.ct-post-card .ct-media-container img {
  transition: transform 0.4s ease !important;
}

.ct-post-card:hover .ct-media-container img {
  transform: scale(1.04);
}

/* Categoria acima do título no card */
.ct-post-card .ct-post-meta .entry-category,
.ct-post-card .cat-links a,
.ct-post-card .entry-meta .cat-links a {
  font-size: 0.68rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.12em !important;
  color: var(--tmbtf-orange) !important;
}

/* Título do card */
.ct-post-card .entry-title {
  font-family: var(--tmbtf-serif) !important;
  font-size: clamp(1.1rem, 2.5vw, 1.4rem) !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: -0.02em !important;
  margin-top: 0.5rem !important;
}

.ct-post-card .entry-title a {
  color: var(--tmbtf-black) !important;
}

.ct-post-card .entry-title a:hover {
  color: var(--tmbtf-orange) !important;
}

/* Excerpt do card */
.ct-post-card .entry-excerpt,
.ct-post-card .entry-summary {
  font-size: 0.88rem !important;
  color: var(--tmbtf-gray-dark) !important;
  line-height: 1.6 !important;
}

/* Metadados (autor, data) no card */
.ct-post-card .entry-meta,
.ct-post-card time,
.ct-post-card .posted-on {
  font-size: 0.72rem !important;
  color: var(--tmbtf-gray-mid) !important;
  text-transform: uppercase !important;
  letter-spacing: 0.06em !important;
}


/* ═══════════════════════════════════════════════════════════════════════════════
   POST INDIVIDUAL
═══════════════════════════════════════════════════════════════════════════════ */

/* Título do post — centralizado */
.single .entry-title,
.single h1.entry-title {
  font-family: var(--tmbtf-serif) !important;
  font-size: clamp(2rem, 5vw, 3.2rem) !important;
  font-weight: 700 !important;
  line-height: 1.1 !important;
  letter-spacing: -0.03em !important;
  margin-bottom: 1rem !important;
  text-align: center !important;
}

/* Metadados do post — centralizados */
.single .entry-meta,
.single .ct-post-meta {
  font-size: 0.75rem !important;
  color: var(--tmbtf-gray-mid) !important;
  text-transform: uppercase !important;
  letter-spacing: 0.08em !important;
  border-top: 1px solid #e0e0e0;
  border-bottom: 1px solid #e0e0e0;
  padding: 0.75rem 0;
  margin-bottom: 2.5rem !important;
  text-align: center !important;
  justify-content: center !important;
}

.single .entry-meta a,
.single .ct-post-meta a {
  color: var(--tmbtf-gray-mid) !important;
}

.single .entry-meta a:hover,
.single .ct-post-meta a:hover {
  color: var(--tmbtf-orange) !important;
}

/* Corpo do texto */
.single .entry-content,
.single .ct-post-content {
  font-size: 1.05rem !important;
  line-height: 1.8 !important;
  color: var(--tmbtf-black) !important;
  max-width: 720px;
  margin-left: auto !important;
  margin-right: auto !important;
}

/* Bloco de nota/veredito — centralizado */
.tmbtf-rating-block {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center !important;
}

/* Parágrafos do post */
.single .entry-content p {
  margin-bottom: 1.5rem;
}

/* Primeiro parágrafo maior (lead) */
.single .entry-content > p:first-of-type {
  font-size: 1.15rem !important;
  font-weight: 400 !important;
  color: var(--tmbtf-gray-dark) !important;
  line-height: 1.7 !important;
}

/* Citações */
.single .entry-content blockquote {
  border-left: 3px solid var(--tmbtf-orange) !important;
  padding-left: 1.5rem !important;
  margin: 2rem 0 !important;
  font-family: var(--tmbtf-serif) !important;
  font-style: italic !important;
  font-size: 1.15rem !important;
  color: var(--tmbtf-gray-dark) !important;
}

/* Subtítulos dentro do post */
.single .entry-content h2 {
  font-size: 1.6rem !important;
  margin-top: 3rem !important;
  margin-bottom: 1rem !important;
  padding-top: 2rem;
  border-top: 1px solid #e0e0e0;
}

.single .entry-content h3 {
  font-size: 1.25rem !important;
  margin-top: 2rem !important;
  margin-bottom: 0.75rem !important;
}


/* ═══════════════════════════════════════════════════════════════════════════════
   COMPONENTES DA REVISTA
═══════════════════════════════════════════════════════════════════════════════ */

/* Nota da crítica */
.tmbtf-rating {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--tmbtf-serif);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--tmbtf-orange);
  border: 2px solid var(--tmbtf-orange);
  padding: 6px 16px;
  line-height: 1;
}

.tmbtf-rating__label {
  font-family: var(--tmbtf-sans);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--tmbtf-gray-mid);
}

/* Metadados do filme */
.tmbtf-film-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  font-size: 0.75rem;
  font-family: var(--tmbtf-sans);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--tmbtf-gray-mid);
  margin-bottom: 2rem;
}

.tmbtf-film-meta a {
  color: var(--tmbtf-gray-mid);
}

.tmbtf-film-meta a:hover {
  color: var(--tmbtf-orange);
}

/* Tag de seção */
.tmbtf-section-tag,
.entry-categories a,
.cat-links a {
  font-size: 0.68rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.12em !important;
  color: var(--tmbtf-orange) !important;
}

/* Separador */
.tmbtf-divider {
  border: none;
  border-top: 1px solid var(--tmbtf-black);
  margin: 2.5rem 0;
}


/* ═══════════════════════════════════════════════════════════════════════════════
   HERO
═══════════════════════════════════════════════════════════════════════════════ */

.tmbtf-hero {
  position: relative;
  width: 100%;
  height: 85vh;
  min-height: 520px;
  max-height: 780px;
  overflow: hidden;
  background-color: var(--tmbtf-black);
}

.tmbtf-hero__link {
  display: block;
  width: 100%;
  height: 100%;
  color: inherit;
}

.tmbtf-hero__image {
  position: absolute;
  inset: 0;
}

.tmbtf-hero__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: transform 0.6s ease;
}

.tmbtf-hero:hover .tmbtf-hero__image img {
  transform: scale(1.02);
}

.tmbtf-hero__image--empty {
  background-color: var(--tmbtf-gray-dark);
}

.tmbtf-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.90) 0%,
    rgba(0,0,0,0.55) 40%,
    rgba(0,0,0,0.10) 70%,
    transparent 100%
  );
}

.tmbtf-hero__content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 3rem 4rem;
  max-width: 860px;
}

.tmbtf-hero__cat {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--tmbtf-orange);
  margin-bottom: 0.75rem;
}

.tmbtf-hero__title {
  font-family: var(--tmbtf-serif) !important;
  font-size: clamp(2rem, 4.5vw, 3.8rem) !important;
  font-weight: 700 !important;
  line-height: 1.08 !important;
  letter-spacing: -0.03em !important;
  color: var(--tmbtf-white) !important;
  margin: 0 0 1rem !important;
}

.tmbtf-hero__excerpt {
  font-size: 1rem;
  color: rgba(255,255,255,0.75);
  line-height: 1.6;
  margin-bottom: 1rem;
  max-width: 600px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tmbtf-hero__meta {
  font-size: 0.72rem !important;
  color: rgba(255,255,255,0.55) !important;
  text-transform: uppercase !important;
  letter-spacing: 0.08em !important;
  margin: 0 !important;
}

@media (max-width: 768px) {
  .tmbtf-hero { height: 70vh; }
  .tmbtf-hero__content { padding: 2rem 1.5rem; }
  .tmbtf-hero__title { font-size: clamp(1.6rem, 6vw, 2.5rem) !important; }
}


/* ═══════════════════════════════════════════════════════════════════════════════
   HOMEPAGE
═══════════════════════════════════════════════════════════════════════════════ */

/* Seção introdutória */
.tmbtf-home__intro {
  max-width: 820px;
  margin: 0 auto;
  padding: 6rem 2rem 5rem;
  text-align: center;
  border-bottom: 1px solid #e0e0e0;
  margin-bottom: 3rem;
}

/* Linha laranja decorativa acima do título */
.tmbtf-home__intro::before {
  content: '';
  display: block;
  width: 40px;
  height: 3px;
  background-color: var(--tmbtf-orange);
  margin: 0 auto 2rem;
}

/* Texto da intro editável no WordPress */
.tmbtf-home__intro h1,
.tmbtf-home__intro h2 {
  font-size: clamp(2.6rem, 5vw, 4.5rem) !important;
  line-height: 1.05 !important;
  letter-spacing: -0.04em !important;
  margin-bottom: 1.5rem !important;
}

.tmbtf-home__intro p {
  font-size: 1.05rem;
  color: var(--tmbtf-gray-dark);
  line-height: 1.8;
  max-width: 560px;
  margin: 0 auto 1rem;
}

/* Separador com label "Leituras" */
.tmbtf-home__divider {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2rem 2.5rem;
}

.tmbtf-home__divider::before,
.tmbtf-home__divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background-color: var(--tmbtf-black);
}

.tmbtf-home__divider span {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--tmbtf-gray-mid);
  white-space: nowrap;
}

/* Grid de artigos */
.tmbtf-home__featured {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2rem 5rem;
}

.tmbtf-home__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}

/* Card */
.tmbtf-home__card {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.tmbtf-home__card-image {
  display: block;
  overflow: hidden;
  aspect-ratio: 3 / 2;
}

.tmbtf-home__card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.tmbtf-home__card:hover .tmbtf-home__card-image img {
  transform: scale(1.04);
}

.tmbtf-home__card-body {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.tmbtf-home__card-title {
  font-family: var(--tmbtf-serif);
  font-size: 1.1rem !important;
  font-weight: 700 !important;
  line-height: 1.25 !important;
  letter-spacing: -0.02em !important;
  margin: 0 !important;
}

.tmbtf-home__card-title a {
  color: var(--tmbtf-black);
}

.tmbtf-home__card-title a:hover {
  color: var(--tmbtf-orange);
}

.tmbtf-home__card-meta {
  font-size: 0.7rem !important;
  color: var(--tmbtf-gray-mid) !important;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin: 0 !important;
}

/* Responsive: 2 colunas no tablet, 1 no mobile */
@media (max-width: 900px) {
  .tmbtf-home__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 540px) {
  .tmbtf-home__grid {
    grid-template-columns: 1fr;
  }

  .tmbtf-home__intro {
    padding: 3rem 1.5rem 2.5rem;
  }
}


/* ═══════════════════════════════════════════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════════════════════════════════════════ */
#footer,
.site-footer {
  background-color: var(--tmbtf-black) !important;
  color: var(--tmbtf-white) !important;
  border-top: 3px solid var(--tmbtf-orange) !important;
}

#footer a,
.site-footer a {
  color: var(--tmbtf-gray-mid) !important;
}

#footer a:hover,
.site-footer a:hover {
  color: var(--tmbtf-orange) !important;
}

#footer .ct-footer-copyright,
.site-footer .site-info {
  font-size: 0.75rem !important;
  color: var(--tmbtf-gray-mid) !important;
  text-transform: uppercase !important;
  letter-spacing: 0.08em !important;
}

/* Widgets do footer */
#footer .widget-title {
  font-family: var(--tmbtf-sans) !important;
  font-size: 0.7rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.12em !important;
  color: var(--tmbtf-white) !important;
  border-bottom: 1px solid #2a2a2a !important;
  padding-bottom: 0.75rem !important;
  margin-bottom: 1rem !important;
}

#footer p,
#footer li {
  color: var(--tmbtf-gray-mid) !important;
  font-size: 0.85rem !important;
}


/* ═══════════════════════════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .single .entry-title,
  .single h1.entry-title {
    font-size: clamp(1.8rem, 7vw, 2.5rem) !important;
  }

  .page-title,
  .ct-archive-title {
    font-size: clamp(1.6rem, 6vw, 2.5rem) !important;
  }

  .primary-menu-ul > li > a,
  .primary-menu-ul > li > .ct-menu-anchor {
    font-size: 0.85rem !important;
  }
}
