/**
 * Design System: Beleza Garoto HUB
 * High-Tech / shadcn Real — Sem botões toscos, sem cantos exagerados.
 * Referências visuais: MakerWorld + Guia de TI + shadcn/ui official
 * Paleta: Zinc OLED + Laranja Maker (#f97316)
 */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400&family=JetBrains+Mono:wght@400;500;600&display=swap');

/* ─────────────────────────────────────────────
   TOKENS DE DESIGN (CSS Custom Properties)
   ───────────────────────────────────────────── */
:root {
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Modo Claro */
  --bg-page:    #ffffff;
  --bg-surface: #f9f9fb;
  --bg-card:    #ffffff;
  --bg-muted:   #f4f4f6;
  --bg-subtle:  #f0f0f3;

  --border:        rgba(0, 0, 0, 0.08);
  --border-strong: rgba(0, 0, 0, 0.14);
  --border-focus:  rgba(249, 115, 22, 0.5);

  --text-main:  #09090b;
  --text-sub:   #52525b;
  --text-muted: #71717a;
  --text-faint: #a1a1aa;

  /* Laranja Maker */
  --accent:         #f97316;
  --accent-hover:   #ea580c;
  --accent-subtle:  rgba(249, 115, 22, 0.08);
  --accent-border:  rgba(249, 115, 22, 0.25);
  --accent-glow:    rgba(249, 115, 22, 0.18);

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.05), 0 2px 4px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.06), 0 4px 6px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.08), 0 8px 10px rgba(0, 0, 0, 0.04);

  /* Radii */
  --r-sm:  6px;
  --r-md:  8px;  /* Botões e inputs — NÃO usar pill */
  --r-lg:  10px;
  --r-xl:  12px; /* Cards */
  --r-2xl: 16px; /* Seções e modais */

  /* Easing */
  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --t-fast: 0.15s;
  --t-mid:  0.25s;
}

[data-theme="dark"] {
  /* Dark Mode OLED Zinc */
  --bg-page:    #09090b;
  --bg-surface: #0f0f12;
  --bg-card:    #141418;
  --bg-muted:   #1c1c22;
  --bg-subtle:  #232329;

  --border:        rgba(255, 255, 255, 0.07);
  --border-strong: rgba(255, 255, 255, 0.12);
  --border-focus:  rgba(249, 115, 22, 0.55);

  --text-main:  #f4f4f5;
  --text-sub:   #a1a1aa;
  --text-muted: #71717a;
  --text-faint: #52525b;

  --accent-subtle: rgba(249, 115, 22, 0.1);
  --accent-border: rgba(249, 115, 22, 0.3);
  --accent-glow:   rgba(249, 115, 22, 0.22);

  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.35), 0 1px 2px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.3), 0 2px 4px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.4), 0 4px 6px rgba(0, 0, 0, 0.3);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.5), 0 8px 10px rgba(0, 0, 0, 0.35);
}

/* ─────────────────────────────────────────────
   RESET & BASE
   ───────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-family: var(--font-sans);
  background: var(--bg-page);
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
  transition: background-color var(--t-mid) var(--ease-smooth), color var(--t-mid) var(--ease-smooth);
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding-bottom: 68px; /* Mobile bottom bar */
}

@media (min-width: 768px) { body { padding-bottom: 0; } }

a { color: inherit; text-decoration: none; }
img, video { max-width: 100%; height: auto; display: block; }

/* ─────────────────────────────────────────────
   LAYOUT
   ───────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: 1280px;
  margin-inline: auto;
  padding-inline: clamp(1rem, 4vw, 2rem);
}

/* ─────────────────────────────────────────────
   TOPBAR HEADER — Glass sticky
   ───────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transition: background var(--t-mid) var(--ease-smooth), border-color var(--t-mid) var(--ease-smooth);
}

[data-theme="dark"] .site-header {
  background: rgba(9, 9, 11, 0.82);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  height: 60px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  flex-shrink: 0;
  color: var(--text-main);
  transition: opacity var(--t-fast) var(--ease-smooth);
}

.logo:hover { opacity: 0.8; }

.logo-chip {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--accent);
  color: #fff;
  padding: 2px 6px;
  border-radius: var(--r-sm);
}

/* Nav Links Desktop */
.nav-main {
  display: none;
  align-items: center;
  gap: 0.25rem;
  margin-left: 0.5rem;
}

@media (min-width: 900px) { .nav-main { display: flex; } }

.nav-link {
  display: inline-flex;
  align-items: center;
  padding: 5px 12px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: var(--r-md);
  transition: background var(--t-fast) var(--ease-smooth), color var(--t-fast) var(--ease-smooth);
}

.nav-link:hover { background: var(--bg-muted); color: var(--text-main); }
.nav-link.active { background: var(--accent-subtle); color: var(--accent); }

/* Search compact header */
.header-search {
  flex: 1;
  max-width: 340px;
  position: relative;
  display: none;
}

@media (min-width: 720px) { .header-search { display: block; } }

.header-search-input {
  width: 100%;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 0.45rem 0.9rem 0.45rem 2.5rem;
  font-size: 0.85rem;
  color: var(--text-main);
  font-family: var(--font-sans);
  outline: none;
  transition: border-color var(--t-fast) var(--ease-smooth), box-shadow var(--t-fast) var(--ease-smooth);
}

.header-search-input:focus {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.header-search-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-faint);
  width: 14px;
  height: 14px;
  pointer-events: none;
}

/* Header actions */
.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ─────────────────────────────────────────────
   BOTÕES (High-Tech — Sem pills, com gradiente)
   ───────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-family: var(--font-sans);
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  transition: all var(--t-mid) var(--ease-spring);
  text-decoration: none;
  white-space: nowrap;
  line-height: 1;
  -webkit-user-select: none;
  user-select: none;
}

.btn:active { transform: scale(0.975); }

/* Tamanhos */
.btn-sm { padding: 0.45rem 0.875rem; font-size: 0.8rem; }
.btn-md { padding: 0.6rem 1.1rem;   font-size: 0.875rem; }
.btn-lg { padding: 0.75rem 1.5rem;  font-size: 0.95rem; }

/* Variante Primária com Gradiente */
.btn-primary {
  background: linear-gradient(180deg, #fb923c 0%, #f97316 50%, #ea580c 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    0 1px 3px rgba(234, 88, 12, 0.35),
    0 4px 12px rgba(249, 115, 22, 0.2);
  color: #fff;
  border-color: rgba(234, 88, 12, 0.5);
}

.btn-primary:hover {
  background: linear-gradient(180deg, #fb923c 0%, #fb923c 50%, #f97316 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 2px 4px rgba(234, 88, 12, 0.4),
    0 8px 20px rgba(249, 115, 22, 0.28);
  transform: translateY(-1px);
}

/* Variante Ghost */
.btn-ghost {
  background: transparent;
  color: var(--text-sub);
  border-color: var(--border);
}

.btn-ghost:hover {
  background: var(--bg-muted);
  color: var(--text-main);
  border-color: var(--border-strong);
}

/* Variante Outline Accent */
.btn-outline-accent {
  background: var(--accent-subtle);
  color: var(--accent);
  border-color: var(--accent-border);
}

.btn-outline-accent:hover {
  background: rgba(249, 115, 22, 0.14);
  box-shadow: 0 0 0 3px var(--accent-glow);
  transform: translateY(-1px);
}

/* Theme Toggle */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--t-fast) var(--ease-smooth);
}

.theme-toggle:hover {
  background: var(--bg-subtle);
  border-color: var(--border-strong);
  color: var(--text-main);
}

.icon-sun  { display: none; }
.icon-moon { display: block; }
[data-theme="dark"] .icon-sun  { display: block; }
[data-theme="dark"] .icon-moon { display: none; }

/* ─────────────────────────────────────────────
   HERO — Busca Global Centralizada
   Inspirado no Guia de TI
   ───────────────────────────────────────────── */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(3.5rem, 7vw, 5rem) 0 clamp(2.5rem, 5vw, 3.5rem);
}

/* Gradiente radial âmbar no topo */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%,
      rgba(249, 115, 22, 0.12) 0%,
      rgba(251, 146, 60, 0.05) 50%,
      transparent 75%);
  pointer-events: none;
}

[data-theme="dark"] .hero::before {
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%,
      rgba(249, 115, 22, 0.18) 0%,
      rgba(234, 88, 12, 0.08) 50%,
      transparent 75%);
}

.hero-content {
  position: relative;
  text-align: center;
  max-width: 760px;
  margin-inline: auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 5px 12px;
  background: var(--accent-subtle);
  border: 1px solid var(--accent-border);
  border-radius: var(--r-md);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.hero-headline {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.04em;
  color: var(--text-main);
  margin-bottom: 1rem;
}

.hero-headline span {
  background: linear-gradient(135deg, #f97316 0%, #fb923c 50%, #fdba74 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-muted);
  line-height: 1.6;
  max-width: 560px;
  margin: 0 auto 2.5rem;
  font-weight: 400;
}

/* Barra de Busca Global */
.search-bar {
  position: relative;
  max-width: 640px;
  margin: 0 auto 1.5rem;
}

.search-input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-xl);
  padding: 1rem 5.5rem 1rem 3.5rem;
  font-size: 1rem;
  color: var(--text-main);
  font-family: var(--font-sans);
  outline: none;
  box-shadow: var(--shadow-lg);
  transition: border-color var(--t-mid) var(--ease-spring), box-shadow var(--t-mid) var(--ease-spring);
}

.search-input::placeholder { color: var(--text-faint); }

.search-input:focus {
  border-color: var(--border-focus);
  box-shadow: var(--shadow-lg), 0 0 0 4px var(--accent-glow);
}

.search-icon-left {
  position: absolute;
  left: 1.1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-faint);
  width: 20px;
  height: 20px;
  pointer-events: none;
}

.search-btn {
  position: absolute;
  right: 0.4rem;
  top: 50%;
  transform: translateY(-50%);
  padding: 0.55rem 1.1rem;
  font-size: 0.875rem;
}

/* Tags de Busca Rápida */
.search-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
}

.search-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 5px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--t-fast) var(--ease-smooth);
  box-shadow: var(--shadow-xs);
}

.search-tag:hover {
  background: var(--accent-subtle);
  border-color: var(--accent-border);
  color: var(--accent);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm), 0 0 0 2px var(--accent-glow);
}

/* ─────────────────────────────────────────────
   BARRA DE CATEGORIAS GLOBAL (Estilo Guia de TI / Printables)
   ───────────────────────────────────────────── */
.cat-bar {
  border-bottom: 1px solid var(--border);
  background: var(--bg-surface);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 0.35rem 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  position: sticky;
  top: 60px;
  z-index: 40;
  transition: background-color var(--t-mid) var(--ease-smooth), border-color var(--t-mid) var(--ease-smooth);
}
.cat-bar::-webkit-scrollbar { display: none; }

.cat-bar-inner {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.2rem 0;
}

.cat-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 1rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  cursor: pointer;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  transition: all var(--t-fast) var(--ease-smooth);
}

.cat-pill:hover {
  color: var(--text-main);
  background: var(--bg-muted);
  border-color: var(--border);
}

.cat-pill.active {
  color: #fff;
  background: linear-gradient(180deg, #f97316 0%, #ea580c 100%);
  border-color: rgba(234, 88, 12, 0.5);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 2px 8px rgba(249, 115, 22, 0.3);
}

/* ─────────────────────────────────────────────
   SEÇÃO DO CATÁLOGO DE CONTEÚDO
   ───────────────────────────────────────────── */
.catalog-section {
  width: 100%;
  padding-bottom: 3.5rem;
}

/* Barra de Controles do Catálogo */
.catalog-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.catalog-title {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.controls-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Botão "Filtros" (toggle) */
.filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-sub);
  cursor: pointer;
  transition: all var(--t-fast) var(--ease-smooth);
}

.filter-toggle:hover { background: var(--bg-subtle); border-color: var(--border-strong); color: var(--text-main); }
.filter-toggle.open { background: var(--accent-subtle); border-color: var(--accent-border); color: var(--accent); }

/* Painel de Filtros Deslizante */
.filters-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 1.25rem;
  margin-bottom: 1.25rem;
  display: none;
  box-shadow: var(--shadow-md);
}

.filters-panel.open { display: block; }

.filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}

.filter-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-faint);
  margin-bottom: 0.5rem;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.filter-chip {
  padding: 4px 10px;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--t-fast) var(--ease-smooth);
}

.filter-chip:hover, .filter-chip.selected {
  background: var(--accent-subtle);
  border-color: var(--accent-border);
  color: var(--accent);
}

/* ─────────────────────────────────────────────
   CARDS DE CONTEÚDO (High-Tech — MakerWorld Style)
   ───────────────────────────────────────────── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

@media (min-width: 1280px) {
  .cards-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform var(--t-mid) var(--ease-spring),
              box-shadow var(--t-mid) var(--ease-spring),
              border-color var(--t-mid) var(--ease-spring);
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-xl), 0 0 0 1px var(--accent-border);
  border-color: rgba(249, 115, 22, 0.3);
}

.card-thumb {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--bg-muted);
}

.card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--t-mid) var(--ease-spring);
}

.card:hover .card-thumb img { transform: scale(1.04); }

/* Badges sobrepostas no thumb */
.thumb-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 8px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: var(--r-sm);
  background: var(--accent);
  color: #fff;
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.35);
}

.thumb-badge-dark {
  background: rgba(9, 9, 11, 0.8);
  color: var(--text-main);
  backdrop-filter: blur(8px);
}

.thumb-score {
  position: absolute;
  bottom: 10px;
  right: 10px;
  padding: 3px 8px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  background: rgba(9, 9, 11, 0.85);
  color: #f4f4f5;
  border-radius: var(--r-sm);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.card-body {
  padding: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}

.card-category {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.card-title {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-main);
  letter-spacing: -0.01em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.78rem;
  color: var(--text-faint);
  margin-top: auto;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border);
}

.card-meta-item {
  display: flex;
  align-items: center;
  gap: 3px;
}

.card-meta-item svg { width: 12px; height: 12px; opacity: 0.6; }

/* ─────────────────────────────────────────────
   BADGES
   ───────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--r-sm);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge-accent   { background: var(--accent-subtle); color: var(--accent); border: 1px solid var(--accent-border); }
.badge-success  { background: rgba(16, 185, 129, 0.1); color: #10b981; border: 1px solid rgba(16, 185, 129, 0.25); }
.badge-neutral  { background: var(--bg-muted); color: var(--text-sub); border: 1px solid var(--border); }
.badge-dark     { background: rgba(9, 9, 11, 0.8); color: #f4f4f5; border: 1px solid rgba(255,255,255,0.08); }

/* ─────────────────────────────────────────────
   SEÇÃO HERO REVIEW (Artigo em Destaque)
   ───────────────────────────────────────────── */
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-2xl);
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr;
  transition: box-shadow var(--t-mid) var(--ease-spring), border-color var(--t-mid) var(--ease-spring);
}

@media (min-width: 768px) { .feature-card { grid-template-columns: 1.1fr 1fr; } }

.feature-card:hover {
  box-shadow: var(--shadow-xl), 0 0 0 1px var(--accent-border);
  border-color: rgba(249, 115, 22, 0.2);
}

.feature-thumb {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--bg-muted);
}

@media (min-width: 768px) { .feature-thumb { aspect-ratio: auto; height: 100%; } }

.feature-thumb img { width: 100%; height: 100%; object-fit: cover; }

.feature-body {
  padding: clamp(1.25rem, 3vw, 2rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.75rem;
}

.feature-meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.8rem;
  color: var(--text-faint);
  font-weight: 500;
}

.feature-title {
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.025em;
  color: var(--text-main);
}

.feature-excerpt {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ─────────────────────────────────────────────
   SECTION HEADINGS
   ───────────────────────────────────────────── */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1.25rem;
}

.section-title {
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: -0.025em;
}

.section-link {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent);
  transition: opacity var(--t-fast);
}
.section-link:hover { opacity: 0.75; }

/* ─────────────────────────────────────────────
   MOBILE BOTTOM BAR (App-like)
   ───────────────────────────────────────────── */
.bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: stretch;
  z-index: 50;
}

[data-theme="dark"] .bottom-bar { background: rgba(9, 9, 11, 0.92); }

@media (min-width: 768px) { .bottom-bar { display: none; } }

.bottom-bar-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 0.6rem;
  font-weight: 600;
  color: var(--text-faint);
  letter-spacing: 0.02em;
  transition: color var(--t-fast) var(--ease-smooth);
}

.bottom-bar-item svg { width: 20px; height: 20px; }
.bottom-bar-item.active { color: var(--accent); }

/* ─────────────────────────────────────────────
   FOOTER
   ───────────────────────────────────────────── */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  background: var(--bg-surface);
  padding: 2.5rem 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 640px) { .footer-grid { grid-template-columns: 1fr auto; align-items: center; } }

/* ─────────────────────────────────────────────
   ESTILOS DE BLOCOS DE ANÚNCIO (GOOGLE ADSENSE)
   ───────────────────────────────────────────── */
.bg-ad-wrapper {
  margin: 2rem 0;
  text-align: center;
  width: 100%;
  clear: both;
}

.bg-ad-wrapper.in-article {
  margin: 2.25rem 0;
}

.bg-ad-wrapper.sidebar-ad {
  margin: 0;
}

.bg-ad-label {
  display: block;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 0.35rem;
}

.bg-ad-container {
  min-height: 90px;
  background: rgba(255, 255, 255, 0.015);
  border: 1px dashed var(--border-subtle);
  border-radius: var(--r-md);
  padding: 0.5rem;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.bg-ad-wrapper.sidebar-ad .bg-ad-container {
  min-height: 250px;
}

/* ─────────────────────────────────────────────
   AUTOCOMPLETE DROPDOWN & RESULTADOS SEARCH
   ───────────────────────────────────────────── */
.bg-autocomplete-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--bg-surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-lg);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 100;
  max-height: 440px;
  overflow-y: auto;
  display: none;
  text-align: left;
  animation: bgDropdownFade 0.15s ease-out;
}

@keyframes bgDropdownFade {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.bg-autocomplete-dropdown.active {
  display: block;
}

.bg-autocomplete-header {
  padding: 0.65rem 1rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-faint);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.bg-autocomplete-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem 1rem;
  text-decoration: none;
  color: var(--text-main);
  border-bottom: 1px solid var(--border-subtle);
  transition: background var(--t-fast) ease, transform var(--t-fast) ease;
}

.bg-autocomplete-item:last-child {
  border-bottom: none;
}

.bg-autocomplete-item:hover,
.bg-autocomplete-item.selected {
  background: var(--bg-muted);
}

.bg-autocomplete-thumb {
  width: 44px;
  height: 44px;
  border-radius: var(--r-md);
  object-fit: cover;
  background: var(--bg-card);
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.bg-autocomplete-info {
  flex-grow: 1;
  min-width: 0;
}

.bg-autocomplete-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0.2rem;
}

.bg-autocomplete-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.bg-autocomplete-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--r-sm);
  color: #fff;
  white-space: nowrap;
}

.bg-autocomplete-empty {
  padding: 1.5rem 1rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.bg-autocomplete-footer {
  padding: 0.6rem 1rem;
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  text-align: center;
  font-size: 0.78rem;
}

.bg-autocomplete-footer a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.bg-autocomplete-footer a:hover {
  text-decoration: underline;
}

/* ─────────────────────────────────────────────
   UTILITÁRIOS
   ───────────────────────────────────────────── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

.divider {
  height: 1px;
  background: var(--border);
  margin: 2rem 0;
}

section { padding: 2.5rem 0; }

