/*
Theme Name: Especialista de SEO - Dark Minimalist
Theme URI: https://especialistadeseo.com.br
Author: Jonathan Pavão
Author URI: https://especialistadeseo.com.br/sobre
Description: Tema oficial do Especialista de SEO / Jonathan Pavão focado em Search Infrastructure, performance extrema, notas 100 nos Core Web Vitals e Schema Markup nativo.
Version: 1.0.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: especialista-de-seo
Tags: dark, minimal, seo, high-performance, blog, portfolio
*/

:root {
  --zinc-100: #f4f4f5;
  --zinc-300: #d4d4d8;
  --zinc-400: #a1a1aa;
  --zinc-500: #71717a;
  --zinc-600: #52525b;
  --zinc-700: #3f3f46;
  --zinc-800: #27272a;
  --zinc-900: #18181b;
  --zinc-950: #09090b;
  --white: #ffffff;
  --accent-blue: #3b82f6;
  --accent-blue-light: #60a5fa;
  --border-subtle: rgba(39, 39, 42, 0.4);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--zinc-950);
  color: var(--zinc-300);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background-color: var(--zinc-800);
  color: var(--white);
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--zinc-950);
  color: var(--zinc-300);
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.2s ease;
}

.container {
  width: 100%;
  max-width: 80rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (min-width: 1024px) {
  .container {
    padding: 0 3rem;
  }
}

/* ==========================================================================
   HEADER & NAVEGAÇÃO IDÊNTICA AO SITE PRINCIPAL
   ========================================================================== */
.header {
  position: relative;
  width: 100%;
  padding: 2rem 0;
  border-bottom: 1px solid var(--border-subtle);
  background-color: var(--zinc-950);
  z-index: 100;
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.brand {
  color: var(--white);
  font-weight: 500;
  letter-spacing: -0.025em;
  font-size: 0.875rem;
  text-transform: uppercase;
}

/* Mobile Toggle */
.nav-toggle {
  display: none;
}

.nav-toggle-label {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle-label span {
  display: block;
  width: 24px;
  height: 1px;
  background-color: var(--zinc-300);
  transition: all 0.2s ease;
}

.nav-menu {
  display: none;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  gap: 1.5rem;
  margin-top: 1.5rem;
  padding-bottom: 1rem;
}

.nav-toggle:checked ~ .nav-menu {
  display: flex;
}

.nav-toggle:checked ~ .nav-toggle-label span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}
.nav-toggle:checked ~ .nav-toggle-label span:nth-child(2) {
  opacity: 0;
}
.nav-toggle:checked ~ .nav-toggle-label span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

@media (min-width: 1024px) {
  .nav-toggle-label {
    display: none;
  }
  .nav-menu {
    display: flex !important;
    flex-direction: row;
    align-items: center;
    width: auto;
    margin-top: 0;
    padding-bottom: 0;
    gap: 1.75rem;
  }
}

.nav-link {
  font-size: 0.75rem;
  color: var(--zinc-400);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: color 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
  display: inline-block;
}

.nav-link:hover, .nav-link.active {
  color: var(--white);
}

.nav-link.active {
  border-bottom: 1px solid var(--zinc-700);
  padding-bottom: 2px;
}

/* ==== MegaMenu de Serviços ==== */
.megamenu-container {
  position: static;
}

.dropdown-title {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
}

.dropdown-title .arrow {
  font-size: 0.6rem;
  transition: transform 0.2s ease;
}

.megamenu-container:hover .dropdown-title .arrow,
.simple-dropdown-container:hover .dropdown-title .arrow {
  transform: rotate(180deg);
}

.megamenu-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background-color: #09090b;
  border-bottom: 1px solid var(--border-subtle);
  border-top: 1px solid var(--border-subtle);
  box-shadow: 0px 16px 32px rgba(0,0,0,0.8);
  z-index: 1000;
  padding: 3rem 1.5rem;
}

.megamenu-content::before {
  content: "";
  position: absolute;
  top: -40px;
  left: 0;
  width: 100%;
  height: 40px;
  background: transparent;
  z-index: -1;
}

.megamenu-grid {
  max-width: 80rem;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.5rem;
}

.megamenu-col {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.megamenu-col-title {
  color: var(--white);
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  border-bottom: 1px solid var(--zinc-800);
  padding-bottom: 0.75rem;
  margin-bottom: 0.5rem;
}

.megamenu-col a {
  color: var(--zinc-400);
  text-decoration: none;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: color 0.2s ease, padding-left 0.2s ease;
  display: inline-block;
  width: fit-content;
}

.megamenu-col a:hover {
  color: var(--white);
  padding-left: 4px;
}

.megamenu-container:hover .megamenu-content {
  display: block;
}

@media (max-width: 1023px) {
  .megamenu-container {
    width: 100%;
  }
  .dropdown-title {
    padding: 0.5rem 0;
  }
  .megamenu-content {
    display: none;
    position: static;
    background-color: transparent;
    border: none;
    box-shadow: none;
    margin-top: 0;
    padding: 0 0 0 1rem;
    width: 100%;
  }
  .megamenu-container:hover .megamenu-content {
    display: block;
  }
  .megamenu-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 1rem;
  }
}

/* ==== Dropdown Simples de Ferramentas ==== */
.simple-dropdown-container {
  position: relative;
  display: inline-block;
}

.simple-dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background-color: #09090b;
  border: 1px solid var(--zinc-800);
  border-radius: 4px;
  box-shadow: 0px 16px 32px rgba(0,0,0,0.8);
  padding: 1.25rem;
  min-width: 240px;
  flex-direction: column;
  gap: 0.85rem;
  z-index: 1000;
  margin-top: 0.5rem;
}

.simple-dropdown-content::before {
  content: "";
  position: absolute;
  top: -20px;
  left: 0;
  width: 100%;
  height: 20px;
  background: transparent;
}

.simple-dropdown-container:hover .simple-dropdown-content {
  display: flex;
}

.simple-dropdown-content a {
  color: var(--zinc-400);
  text-decoration: none;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: color 0.2s ease, padding-left 0.2s ease;
  display: block;
  white-space: nowrap;
}

.simple-dropdown-content a:hover {
  color: var(--white);
  padding-left: 4px;
}

@media (max-width: 1023px) {
  .simple-dropdown-container {
    width: 100%;
  }
  .simple-dropdown-content {
    position: static;
    transform: none;
    display: flex;
    box-shadow: none;
    border: none;
    padding: 0 0 0 1rem;
    margin-top: 0.5rem;
    background: transparent;
    gap: 0.75rem;
  }
}

/* ==========================================================================
   BOTÕES & COMPONENTES GERAIS
   ========================================================================== */
.btn-outline {
  display: inline-block;
  border: 1px solid var(--zinc-700);
  color: var(--white);
  padding: 0.75rem 1.5rem;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: border-color 0.2s ease;
  background: transparent;
  cursor: pointer;
}

.btn-outline:hover {
  border-color: var(--zinc-500);
}

.btn-solid {
  display: inline-block;
  background-color: var(--zinc-100);
  color: var(--zinc-950);
  border: none;
  padding: 0.75rem 2rem;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  font-weight: 500;
  text-transform: uppercase;
  transition: background-color 0.2s ease;
  cursor: pointer;
  border-radius: 2px;
}

.btn-solid:hover {
  background-color: var(--white);
}

/* ==========================================================================
   BLOG LAYOUT, GRID & POST CARDS
   ========================================================================== */
.blog-hero {
  padding: 4.5rem 0 3.5rem 0;
  border-bottom: 1px solid var(--zinc-800);
  margin-bottom: 3.5rem;
}

.blog-badge {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  border: 1px solid var(--zinc-700);
  background-color: rgba(39, 39, 42, 0.4);
  color: var(--zinc-300);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
  border-radius: 9999px;
  margin-bottom: 1.5rem;
}

.blog-title {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--white);
  margin-bottom: 1.25rem;
}

.blog-subtitle {
  font-size: 1.125rem;
  color: var(--zinc-400);
  line-height: 1.6;
  max-width: 50rem;
}

.blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-bottom: 4rem;
}

@media (min-width: 768px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .blog-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.post-card {
  display: flex;
  flex-direction: column;
  background-color: #0d0d11;
  border: 1px solid var(--zinc-800);
  padding: 2rem;
  border-radius: 4px;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.post-card:hover {
  border-color: var(--zinc-600);
  transform: translateY(-2px);
  box-shadow: 0 12px 24px -10px rgba(0, 0, 0, 0.5);
}

.post-card-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--zinc-500);
  margin-bottom: 1rem;
}

.post-card-category {
  color: var(--accent-blue-light);
  font-weight: 500;
}

.post-card-title {
  font-size: 1.25rem;
  line-height: 1.35;
  font-weight: 500;
  color: var(--white);
  margin-bottom: 0.85rem;
  letter-spacing: -0.02em;
}

.post-card-title a {
  color: inherit;
}

.post-card-title a:hover {
  color: #93c5fd;
}

.post-card-excerpt {
  font-size: 0.925rem;
  color: var(--zinc-400);
  line-height: 1.6;
  margin-bottom: 1.75rem;
  flex-grow: 1;
}

.post-card-footer {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid rgba(39, 39, 42, 0.4);
}

.post-read-more {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--white);
  transition: gap 0.2s ease;
}

.post-read-more:hover {
  gap: 0.7rem;
  color: var(--accent-blue-light);
}

/* ==========================================================================
   SINGLE ARTICLE TEMPLATE
   ========================================================================== */
.article-wrapper {
  max-width: 52rem;
  margin: 0 auto;
  padding: 2rem 0 4rem 0;
}

.article-header {
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--zinc-800);
}

.article-main-title {
  font-size: clamp(2.25rem, 5vw, 3.25rem);
  line-height: 1.15;
  letter-spacing: -0.035em;
  color: var(--white);
  font-weight: 600;
  margin-bottom: 1.75rem;
}

.article-meta-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 0.875rem;
  color: var(--zinc-400);
}

.article-body {
  font-size: 1.075rem;
  line-height: 1.8;
  color: var(--zinc-300);
}

.article-body h2 {
  font-size: 1.75rem;
  color: var(--white);
  font-weight: 500;
  letter-spacing: -0.025em;
  margin-top: 3rem;
  margin-bottom: 1.25rem;
  scroll-margin-top: 2rem;
}

.article-body h3 {
  font-size: 1.35rem;
  color: var(--white);
  font-weight: 500;
  margin-top: 2.25rem;
  margin-bottom: 1rem;
  scroll-margin-top: 2rem;
}

.article-body h4 {
  font-size: 1.15rem;
  color: #93c5fd;
  font-weight: 500;
  margin-top: 1.75rem;
  margin-bottom: 0.75rem;
}

.article-body h5 {
  font-size: 1rem;
  color: var(--zinc-200);
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.article-body h6 {
  font-size: 0.875rem;
  color: #60a5fa;
  font-weight: 600;
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.featured-article-image {
  margin: 2rem 0 3rem 0;
}

.featured-article-image img {
  width: 100%;
  height: auto;
  border-radius: 6px;
  border: 1px solid var(--zinc-800);
  display: block;
}

.featured-article-image figcaption {
  font-size: 0.8rem;
  color: var(--zinc-500);
  margin-top: 0.75rem;
  text-align: center;
}

/* ==== Table of Contents Estilizado & Agradável ==== */
.toc-list {
  background: linear-gradient(180deg, #111116 0%, #0c0c0f 100%);
  border: 1px solid rgba(59, 130, 246, 0.25);
  border-left: 4px solid #3b82f6;
  border-radius: 8px;
  padding: 2rem 2.25rem 2rem 2.75rem;
  margin: 2.5rem 0 3.5rem 0;
  box-shadow: 0 8px 24px -6px rgba(0, 0, 0, 0.4);
}

.toc-list li {
  margin-bottom: 0.75rem;
  color: var(--zinc-400);
  font-size: 0.95rem;
  line-height: 1.5;
}

.toc-list > li > a {
  color: var(--white);
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease, padding-left 0.2s ease;
  display: inline-block;
}

.toc-list > li > a:hover {
  color: #60a5fa;
  padding-left: 4px;
}

.toc-list ul {
  margin-top: 0.6rem;
  margin-bottom: 0.6rem;
  padding-left: 1.25rem;
  list-style-type: none;
  border-left: 1px dashed var(--zinc-800);
}

.toc-list ul li {
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.toc-list ul li a {
  color: var(--zinc-400);
  text-decoration: none;
  transition: color 0.2s ease;
}

.toc-list ul li a:hover {
  color: #93c5fd;
}

.article-body a {
  color: #60a5fa;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.article-body a:hover {
  color: #93c5fd;
}

/* Author Box */
.author-card {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  background-color: #0c0c0f;
  border: 1px solid var(--zinc-800);
  padding: 2rem;
  margin-top: 4rem;
  border-radius: 4px;
}

.author-avatar {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background-color: var(--zinc-800);
  border: 1px solid var(--zinc-700);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: var(--white);
  flex-shrink: 0;
}

.author-bio h3 {
  color: var(--white);
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 0.35rem;
}

.author-bio p {
  color: var(--zinc-400);
  font-size: 0.9rem;
  line-height: 1.5;
}

/* CTA Banner */
.cta-banner {
  background: linear-gradient(180deg, #121217 0%, #09090b 100%);
  border: 1px solid var(--zinc-800);
  padding: 3rem 2rem;
  margin: 4.5rem 0;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .cta-banner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 3.5rem 3rem;
  }
}

.cta-title {
  font-size: 1.5rem;
  color: var(--white);
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.cta-desc {
  color: var(--zinc-400);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ==========================================================================
   FOOTER COM TODOS OS NICHOS
   ========================================================================== */
.footer {
  width: 100%;
  padding: 4rem 0 3rem 0;
  margin-top: auto;
  border-top: 1px solid var(--border-subtle);
  background-color: var(--zinc-950);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.footer-copy {
  color: var(--zinc-500);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-nav a {
  color: var(--zinc-400);
  font-size: 0.85rem;
  transition: color 0.2s;
}

.footer-nav a:hover {
  color: var(--white);
}

/* Paginação */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin: 3rem 0;
}

.pagination .page-numbers {
  padding: 0.5rem 1rem;
  border: 1px solid var(--zinc-800);
  color: var(--zinc-300);
  border-radius: 2px;
}

.pagination .page-numbers.current,
.pagination .page-numbers:hover {
  background-color: var(--zinc-800);
  color: var(--white);
  border-color: var(--zinc-600);
}

/* ==========================================================================
   WHATSAPP FLUTUANTE & MODAL OVERLAY
   ========================================================================== */
.whatsapp-flutuante {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 58px;
  height: 58px;
  background-color: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1500;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.2s ease, box-shadow 0.25s ease;
}

.whatsapp-flutuante:hover {
  transform: scale(1.08) translateY(-2px);
  background-color: #22bf5b;
  box-shadow: 0 10px 25px rgba(37, 211, 102, 0.35);
}

.whatsapp-flutuante svg {
  width: 30px;
  height: 30px;
  fill: #ffffff;
}

.form-modal-overlay {
  display: none !important;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(9, 9, 11, 0.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  align-items: center;
  justify-content: center;
  z-index: 2500;
  padding: 1.5rem;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.form-modal-overlay.is-active {
  display: flex !important;
  opacity: 1;
}

.form-modal-content {
  background-color: #121217;
  border: 1px solid var(--zinc-800);
  border-radius: 8px;
  padding: 2.25rem;
  max-width: 480px;
  width: 100%;
  color: var(--white);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
  position: relative;
  animation: modalFadeIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.form-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--zinc-800);
}

.form-modal-header h3 {
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--white);
  margin: 0;
}

.form-modal-content .close-btn {
  background: transparent;
  border: none;
  color: var(--zinc-400);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.25rem;
  transition: color 0.2s ease;
}

.form-modal-content .close-btn:hover {
  color: var(--white);
}

.form-modal-content .form-group {
  margin-bottom: 1rem;
}

.form-modal-content input,
.form-modal-content textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  background-color: #09090b;
  border: 1px solid var(--zinc-700);
  color: var(--white);
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.9rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
}

.form-modal-content input:focus,
.form-modal-content textarea:focus {
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.form-modal-content textarea {
  resize: vertical;
  min-height: 80px;
}

.form-modal-content .btn-solid {
  background-color: var(--white);
  color: var(--zinc-950);
  border: 1px solid var(--white);
  padding: 0.85rem 1.5rem;
  font-weight: 500;
  font-size: 0.95rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
}

.form-modal-content .btn-solid:hover {
  background-color: var(--zinc-200);
  border-color: var(--zinc-200);
}

.form-modal-content .btn-solid:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

