/* ==========================================================================
   FdLearn - Artigos & Publicações Técnicas CSS
   Clean & Minimalist Editorial Architecture | GEO/SEO Optimized
   ========================================================================== */

/* --------------------------------------------------------------------------
   Layout Base & Configurações da Página
   -------------------------------------------------------------------------- */
.mc-page,
.mc-page-light {
  background: #f8fafc !important;
  color: #0f172a !important;
  min-height: 100vh;
  display: block;
  overflow-x: clip;
}

/* Ocultar glow escuro da homepage nas páginas de artigos */
.mc-page .bg-glow-container,
.mc-page-light .bg-glow-container {
  display: none !important;
}

/* --------------------------------------------------------------------------
   Header Fixo e Sempre Visível no Topo (Sticky Header)
   Acompanha o scroll suavemente sem sobrepor o anúncio inicial
   -------------------------------------------------------------------------- */
.mc-page .header,
.mc-page-light .header {
  position: sticky !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  z-index: 1000 !important;
  background: rgba(7, 8, 11, 0.96) !important;
  backdrop-filter: blur(18px) saturate(160%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(160%) !important;
  border-bottom: 1px solid rgba(223, 183, 88, 0.22) !important;
  box-shadow: 0 8px 24px -6px rgba(0, 0, 0, 0.45) !important;
  padding: 0.85rem 0 !important;
  transition: padding 0.3s ease, background-color 0.3s ease;
}

.mc-page .brand-logo img,
.mc-page-light .brand-logo img {
  filter: none !important;
  opacity: 1 !important;
}

.mc-main {
  flex: 1;
  padding-top: 2.5rem;
  padding-bottom: 5.5rem;
}

/* --------------------------------------------------------------------------
   Breadcrumbs
   -------------------------------------------------------------------------- */
.mc-breadcrumbs {
  margin-bottom: 2rem;
  font-size: var(--font-size-xs);
  color: #64748b;
}

.mc-breadcrumbs ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  padding: 0;
  margin: 0;
}

.mc-breadcrumbs li+li::before {
  content: "/";
  margin-right: 0.5rem;
  color: #cbd5e1;
}

.mc-breadcrumbs a {
  color: #475569;
  text-decoration: none;
  transition: color 0.15s ease;
}

.mc-breadcrumbs a:hover {
  color: #9e7828;
}

.mc-breadcrumbs [aria-current="page"] {
  color: #9e7828;
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   Hub Header / Hero (Clean & Minimalist)
   -------------------------------------------------------------------------- */
.mc-hub-hero {
  text-align: center;
  max-width: 860px;
  margin: 0 auto 3.5rem auto;
}

.mc-hub-eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #9e7828;
  margin-bottom: 0.85rem;
}

.mc-hub-title {
  font-size: clamp(2.2rem, 1.8rem + 1.8vw, 3.4rem);
  line-height: 1.15;
  font-weight: 800;
  color: #090d16;
  margin-bottom: 1.25rem;
  letter-spacing: -0.025em;
}

.mc-hub-desc {
  font-size: var(--font-size-lg);
  color: #475569;
  line-height: 1.7;
  max-width: 720px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   Barra de Filtros (Padrão idêntico aos botões do restante do website)
   Formato levemente arredondado (border-radius: 6px), cores nobres
   -------------------------------------------------------------------------- */
.mc-filters-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 3.5rem;
}

.mc-filter-btn {
  border-radius: var(--radius-sm, 6px) !important;
  padding: 0.55rem 1.15rem;
  font-size: var(--font-size-xs);
  font-weight: 600;
  letter-spacing: 0.03em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-sizing: border-box;
  border: 2px solid transparent;
  box-shadow: none;
  transform: none !important;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

/* 0. Todos os Artigos */
.mc-filter-btn[data-filter="all"] {
  background: #0f172a;
  border-color: #1e293b;
  color: #94a3b8;
}
.mc-filter-btn[data-filter="all"]:hover {
  background: #1e293b;
  border-color: #334155;
  color: #ffffff;
}
.mc-filter-btn[data-filter="all"].active {
  background: #ffffff;
  border-color: #0f172a;
  color: #0f172a;
  font-weight: 700;
}

/* 1. Produtos Estruturados (Verde) */
.mc-filter-btn[data-filter="estruturados"] {
  background: #0f2918;
  border-color: rgba(34, 197, 94, 0.35);
  color: #86efac;
}
.mc-filter-btn[data-filter="estruturados"]:hover {
  background: #164024;
  border-color: #22c55e;
  color: #bbf7d0;
}
.mc-filter-btn[data-filter="estruturados"].active {
  background: #ffffff;
  border-color: #16a34a;
  color: #15803d;
  font-weight: 700;
}

/* 2. Modelagem Matemática (Laranja/Bronze) */
.mc-filter-btn[data-filter="modelagem"] {
  background: #2e1409;
  border-color: rgba(249, 115, 22, 0.35);
  color: #fdba74;
}
.mc-filter-btn[data-filter="modelagem"]:hover {
  background: #451d0d;
  border-color: #f97316;
  color: #fed7aa;
}
.mc-filter-btn[data-filter="modelagem"].active {
  background: #ffffff;
  border-color: #ea580c;
  color: #c2410c;
  font-weight: 700;
}

/* 3. Opções de Barreira (Azul) */
.mc-filter-btn[data-filter="barreiras"] {
  background: #0c1f3d;
  border-color: rgba(59, 130, 246, 0.35);
  color: #93c5fd;
}
.mc-filter-btn[data-filter="barreiras"]:hover {
  background: #133261;
  border-color: #3b82f6;
  color: #bfdbfe;
}
.mc-filter-btn[data-filter="barreiras"].active {
  background: #ffffff;
  border-color: #2563eb;
  color: #1d4ed8;
  font-weight: 700;
}

/* 4. Volatilidade & Risco (Roxo) */
.mc-filter-btn[data-filter="volatilidade"] {
  background: #230d38;
  border-color: rgba(168, 85, 247, 0.35);
  color: #d8b4fe;
}
.mc-filter-btn[data-filter="volatilidade"]:hover {
  background: #371457;
  border-color: #a855f7;
  color: #e9d5ff;
}
.mc-filter-btn[data-filter="volatilidade"].active {
  background: #ffffff;
  border-color: #9333ea;
  color: #7e22ce;
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   Grid de Cards de Artigos (Clean White Minimalist Cards)
   -------------------------------------------------------------------------- */
.mc-hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.mc-article-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 2.25rem 2rem 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.05);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
  color: #0f172a;
}

.mc-article-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px -4px rgba(15, 23, 42, 0.08);
  border-color: #cbd5e1;
}

/* Acentos Sutis de Cor no Topo do Card */
.mc-article-card.tone-green { border-top: 3px solid #16a34a; }
.mc-article-card.tone-green .mc-card-category {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid rgba(22, 163, 74, 0.2);
}

.mc-article-card.tone-orange { border-top: 3px solid #ea580c; }
.mc-article-card.tone-orange .mc-card-category {
  background: #fff7ed;
  color: #c2410c;
  border: 1px solid rgba(234, 88, 12, 0.2);
}

.mc-article-card.tone-blue { border-top: 3px solid #2563eb; }
.mc-article-card.tone-blue .mc-card-category {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid rgba(37, 99, 235, 0.2);
}

.mc-article-card.tone-purple { border-top: 3px solid #9333ea; }
.mc-article-card.tone-purple .mc-card-category {
  background: #faf5ff;
  color: #7e22ce;
  border: 1px solid rgba(147, 51, 234, 0.2);
}

.mc-article-card.tone-cyan { border-top: 3px solid #0891b2; }
.mc-article-card.tone-cyan .mc-card-category {
  background: #ecfeff;
  color: #0e7490;
  border: 1px solid rgba(8, 145, 178, 0.2);
}

.mc-card-top-meta {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 1.15rem;
}

/* Pill de Categoria: Levemente Arredondada (4px), sem cápsula 999px */
.mc-card-category {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.28rem 0.65rem;
  border-radius: var(--radius-xs, 4px) !important;
  transition: all 0.2s ease;
}

.mc-card-title {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.35;
  color: #0f172a;
  margin-bottom: 0.85rem;
}

.mc-card-title a {
  color: #0f172a;
  text-decoration: none;
  transition: color 0.2s ease;
}

.mc-card-title a:hover {
  color: #b88a29;
}

.mc-card-stats {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #64748b;
  font-size: 0.82rem;
  font-weight: 500;
  margin-bottom: 1.25rem;
}

.mc-card-stats .clock-icon {
  color: #64748b;
}

.mc-card-desc {
  font-size: 0.92rem;
  color: #475569;
  line-height: 1.65;
  margin-bottom: 1.75rem;
  flex: 1;
}

.mc-card-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-top: 1.25rem;
  border-top: 1px solid #f1f5f9;
  margin-top: auto;
}

/* Botão Sólido Minimalista Levemente Arredondado (Padrão do site, border-radius: 6px/8px) */
.mc-card-cta-solid,
.mc-card-cta-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  background: #0f172a;
  color: #ffffff !important;
  font-weight: 600;
  font-size: 0.86rem;
  padding: 0.72rem 1.4rem;
  border-radius: var(--radius-sm, 6px) !important;
  text-decoration: none;
  border: 1px solid #0f172a;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.mc-card-cta-solid:hover,
.mc-card-cta-gold:hover {
  background: #1e293b;
  border-color: #1e293b;
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.2);
}

.mc-card-cta-solid svg,
.mc-card-cta-gold svg {
  transition: transform 0.2s ease;
}

.mc-card-cta-solid:hover svg,
.mc-card-cta-gold:hover svg {
  transform: translateX(3px);
}

/* --------------------------------------------------------------------------
   Página Individual do Artigo (Article & Transcript Layout - Clara & Minimalista)
   -------------------------------------------------------------------------- */
.mc-article-header {
  max-width: 860px;
  margin: 0 auto 2.5rem auto;
}

.mc-meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
  font-size: var(--font-size-xs);
  color: #64748b;
}

.mc-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.mc-meta-item svg {
  color: #9e7828;
}

.mc-article-title {
  font-size: clamp(2rem, 1.7rem + 1.8vw, 3.2rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.025em;
  color: #0f172a !important;
  margin-bottom: 1.25rem;
}

.mc-article-title,
.mc-article-title * {
  color: #0f172a !important;
  background: none !important;
  -webkit-text-fill-color: #0f172a !important;
  text-shadow: none !important;
  filter: none !important;
}

.mc-article-lead {
  font-size: var(--font-size-lg);
  color: #475569;
  line-height: 1.75;
}

/* Video Embed Wrapper - Reduzido e Centralizado conforme pedido */
.mc-video-wrapper {
  max-width: 640px !important;
  width: 100%;
  margin: 0 auto 3rem auto !important;
  border-radius: var(--radius-md, 10px);
  overflow: hidden;
  border: 1px solid #cbd5e1;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.08), 0 0 20px rgba(15, 23, 42, 0.03);
  background: #000;
  aspect-ratio: 16 / 9;
  position: relative;
}

.mc-video-wrapper iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* GEO / AI DIRECT ANSWER NUGGETS CALLOUT BOX (Otimização RAG / Perplexity) */
.mc-geo-nuggets {
  max-width: 860px;
  margin: 0 auto 3.5rem auto;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #dfb758;
  border-radius: 12px;
  padding: 2.25rem 2rem;
  position: relative;
  box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.05);
}

.mc-geo-nuggets-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #0f172a;
  color: #ffffff;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-xs, 4px);
  margin-bottom: 1rem;
}

.mc-geo-nuggets h2 {
  font-size: var(--font-size-xl);
  font-weight: 700;
  margin-bottom: 1rem;
  color: #0f172a;
}

.mc-nuggets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 1.25rem;
}

.mc-nugget-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1.25rem;
}

.mc-nugget-card h3 {
  font-size: 0.95rem;
  color: #0f172a;
  font-weight: 700;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.mc-nugget-card h3 svg {
  color: #9e7828;
}

.mc-nugget-card p {
  font-size: 0.875rem;
  color: #475569;
  line-height: 1.6;
  margin: 0;
}

/* Article Content Layout */
.mc-content-layout {
  max-width: 860px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

/* Timestamps Accordion / Section */
.mc-timestamps-section {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.75rem 2rem;
  margin-bottom: 3rem;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.03);
}

.mc-timestamps-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.mc-timestamps-header h3 {
  font-size: var(--font-size-lg);
  font-weight: 700;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.mc-timestamps-header h3 svg {
  color: #9e7828;
}

.mc-timestamp-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mc-timestamp-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 0.65rem 0.85rem;
  border-radius: 6px;
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  transition: all 0.15s ease;
}

.mc-timestamp-item:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.mc-timestamp-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  color: #ffffff;
  background: #0f172a;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  text-decoration: none;
  white-space: nowrap;
}

.mc-timestamp-desc {
  font-size: 0.9rem;
  color: #334155;
  font-weight: 500;
  line-height: 1.4;
}

/* Technical Prose / Article Body */
.mc-prose {
  color: #334155;
  font-size: 1.05rem;
  line-height: 1.8;
}

.mc-prose h2 {
  font-size: clamp(1.4rem, 1.2rem + 0.6vw, 1.85rem);
  font-weight: 700;
  color: #0f172a;
  margin-top: 3rem;
  margin-bottom: 1.25rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.mc-prose h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #0f172a;
  margin-top: 2rem;
  margin-bottom: 0.85rem;
}

.mc-prose p {
  margin-bottom: 1.5rem;
  color: #334155;
}

.mc-prose ul, .mc-prose ol {
  margin-bottom: 1.75rem;
  padding-left: 1.5rem;
  color: #334155;
}

.mc-prose li {
  margin-bottom: 0.6rem;
}

.mc-prose strong {
  color: #0f172a;
  font-weight: 700;
}

.mc-prose a {
  color: #b88a29;
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 500;
}

.mc-prose a:hover {
  color: #9e7828;
}

/* Mathematical / Code Formula Box */
.mc-formula-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #dfb758;
  border-radius: 8px;
  padding: 1.25rem 1.5rem;
  margin: 1.75rem 0;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: #0f172a;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.03);
  overflow-x: auto;
}

.mc-formula-caption {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  color: #64748b;
  margin-top: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

/* Technical Glossary Section */
.mc-glossary {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 2rem;
  margin: 3.5rem 0;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.03);
}

.mc-glossary h2 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  color: #0f172a;
}

.mc-glossary dl {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.mc-glossary dt {
  font-weight: 700;
  color: #0f172a;
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.mc-glossary dd {
  margin-left: 0;
  color: #475569;
  font-size: 0.925rem;
  line-height: 1.6;
}

/* Author Box */
.mc-author-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 2rem;
  margin: 3.5rem 0;
  display: flex;
  align-items: center;
  gap: 1.75rem;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
}

.mc-author-avatar {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  border: 2px solid #dfb758;
  object-fit: cover;
  flex-shrink: 0;
}

.mc-author-info h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 0.35rem;
  display: flex;
  align-items: center;
}

.author-linkedin-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0a66c2;
  margin-left: 0.5rem;
  vertical-align: middle;
  text-decoration: none;
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  box-shadow: none !important;
  outline: none !important;
  line-height: 1;
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.author-linkedin-link:hover {
  opacity: 0.8;
  transform: translateY(-1px);
}

.author-linkedin-link svg {
  width: 19px;
  height: 19px;
  fill: #0a66c2;
  display: block;
}

.mc-author-creds {
  font-size: 0.85rem;
  color: #9e7828;
  font-weight: 600;
  margin-bottom: 0.65rem;
}

.mc-author-bio {
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.6;
  margin: 0;
}

/* Next / Prev Navigation */
.mc-lessons-nav {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 3.5rem 0;
}

.mc-nav-card {
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.03);
  transition: all 0.2s ease;
}

.mc-nav-card:hover {
  border-color: #cbd5e1;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
}

.mc-nav-direction {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #9e7828;
  margin-bottom: 0.5rem;
}

.mc-nav-title {
  font-size: 1rem;
  font-weight: 600;
  color: #0f172a;
  line-height: 1.4;
}

/* CTA Box at Bottom of Article */
.mc-article-cta {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-top: 3px solid #dfb758;
  border-radius: 14px;
  padding: 3rem 2rem;
  text-align: center;
  margin-top: 4rem;
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.06);
}

.mc-article-cta h3 {
  font-size: clamp(1.4rem, 1.2rem + 0.8vw, 2rem);
  font-weight: 800;
  margin-bottom: 1rem;
  color: #0f172a;
}

.mc-article-cta p {
  color: #475569;
  font-size: 1.05rem;
  max-width: 600px;
  margin: 0 auto 1.75rem auto;
  line-height: 1.6;
}

/* Responsividade */
@media (max-width: 768px) {
  .mc-hub-grid {
    grid-template-columns: 1fr;
  }
  .mc-geo-nuggets {
    padding: 1.5rem;
  }
  .mc-author-box {
    flex-direction: column;
    text-align: center;
  }
  .mc-author-avatar {
    margin: 0 auto;
  }
  .mc-timestamp-item {
    flex-direction: column;
    gap: 0.4rem;
  }
  .mc-card-cta-solid,
  .mc-card-cta-gold {
    width: 100%;
    justify-content: center;
    box-sizing: border-box;
  }
}
