/* Plenário Slides · galeria de apresentações.
   Reproduz o visual de felipelamarca.com (felipelmc.github.io): tokens de src/styles/global.css,
   cabeçalho de Header.astro, títulos de seção de SectionHeader.astro, cards de ProjectCard.astro
   e rodapé de Footer.astro. O tema claro/escuro usa a mesma chave (localStorage.theme) e a
   mesma classe (.dark) do site, então a escolha vale nos dois. */

:root {
  --bg: 246 246 243;
  --surface: 255 255 255;
  --sunken: 237 237 232;
  --line: 222 222 216;
  --line-strong: 201 201 193;
  --ink: 14 17 22;
  --ink-2: 68 74 84;
  --ink-3: 95 101 110;
  --accent: 10 111 105;
  --accent-ink: 255 255 255;
  --shadow: 14 17 22;
  --d1: 90 192 171;
  --d2: 46 157 142;
  --d3: 24 121 112;
  --d4: 14 86 82;
  --d5: 5 53 53;
  --link: 10 111 105;
  --sans: "Geist", ui-sans-serif, system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --serif: "Newsreader", Georgia, serif;
  color-scheme: light;
}

.dark {
  --bg: 11 13 16;
  --surface: 18 21 26;
  --sunken: 24 28 34;
  --line: 36 42 50;
  --line-strong: 52 60 70;
  --ink: 236 238 241;
  --ink-2: 179 186 196;
  --ink-3: 138 146 157;
  --accent: 63 208 190;
  --accent-ink: 4 32 29;
  --shadow: 0 0 0;
  --d1: 34 81 76;
  --d2: 38 119 111;
  --d3: 47 163 149;
  --d4: 63 208 190;
  --d5: 168 239 228;
  --link: 94 190 178;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5rem; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: rgb(var(--bg));
  color: rgb(var(--ink));
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
::selection { background: rgb(var(--accent) / 0.2); color: rgb(var(--ink)); }
:focus-visible { outline: 2px solid rgb(var(--accent)); outline-offset: 2px; border-radius: 4px; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
svg { flex: none; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.pular { position: absolute; left: -9999px; }
.pular:focus { left: 12px; top: 12px; z-index: 60; padding: 8px 16px; border-radius: 8px; background: rgb(var(--surface)); color: rgb(var(--accent)); }

.container { width: 100%; max-width: 75rem; margin: 0 auto; padding-left: 1rem; padding-right: 1rem; }
@media (min-width: 640px) { .container { padding-left: 1.5rem; padding-right: 1.5rem; } }
@media (min-width: 1024px) { .container { padding-left: 2rem; padding-right: 2rem; } }

.meta, .eyebrow { font-family: var(--mono); font-size: 0.75rem; line-height: 1rem; letter-spacing: 0.01em; color: rgb(var(--ink-3)); }
.eyebrow { text-transform: uppercase; letter-spacing: 0.08em; }

/* ── Cabeçalho (Header.astro) ───────────────────────────────────────────── */
.topo {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgb(var(--line));
  background: rgb(var(--bg) / 0.85);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
.topo nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: 3.5rem; }
.topo .casa { display: flex; align-items: center; gap: 0.625rem; border-radius: 8px; }
.topo .casa svg { width: 1.5rem; height: 1.5rem; transition: transform 300ms; }
.topo .casa:hover svg { transform: rotate(90deg); }
.topo .casa span { font-size: 0.9375rem; font-weight: 500; letter-spacing: -0.01em; transition: color 150ms; }
.topo .casa:hover span { color: rgb(var(--accent)); }
.topo .direita { display: flex; align-items: center; gap: 0.25rem; }
.topo .links { display: none; align-items: center; gap: 0.25rem; }
.topo .links a { display: block; padding: 0.375rem 0.75rem; border-radius: 8px; font-size: 0.875rem; color: rgb(var(--ink-2)); transition: color 150ms; }
.topo .links a:hover { color: rgb(var(--ink)); }
.topo .links a[aria-current="page"] { color: rgb(var(--ink)); position: relative; }
.topo .links a[aria-current="page"]::after { content: ""; position: absolute; left: 0.75rem; right: 0.75rem; bottom: -13px; height: 2px; background: rgb(var(--accent)); }
.icone-btn { display: grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: 8px; color: rgb(var(--ink-3)); transition: background 150ms, color 150ms; }
.icone-btn:hover { background: rgb(var(--sunken)); color: rgb(var(--ink)); }
.icone-btn svg { width: 18px; height: 18px; }
.tema .sol { display: none; }
.dark .tema .sol { display: block; }
.dark .tema .lua { display: none; }
#menu-movel { display: none; border-top: 1px solid rgb(var(--line)); }
#menu-movel.aberto { display: block; }
#menu-movel ul { padding: 0.5rem 0; }
#menu-movel a { display: flex; justify-content: space-between; align-items: center; padding: 0.75rem 0; border-bottom: 1px solid rgb(var(--line)); font-size: 1rem; }
#menu-movel li:last-child a { border-bottom: 0; }
#menu-movel a svg { width: 1rem; height: 1rem; color: rgb(var(--ink-3)); }
@media (min-width: 768px) {
  .topo .links { display: flex; }
  .topo .direita { gap: 0.5rem; }
  #menu-toggle { display: none; }
  #menu-movel, #menu-movel.aberto { display: none; }
}

/* ── Página ─────────────────────────────────────────────────────────────── */
main { flex: 1; padding-top: 2.5rem; padding-bottom: 6rem; }
@media (min-width: 640px) { main { padding-top: 3.5rem; } }

.cabecalho-pagina { max-width: 48rem; margin-bottom: 3rem; }
@media (min-width: 640px) { .cabecalho-pagina { margin-bottom: 4rem; } }
.cabecalho-pagina .eyebrow { margin-bottom: 1rem; }
.cabecalho-pagina h1 { font-size: 2.25rem; font-weight: 600; line-height: 1.05; letter-spacing: -0.03em; }
@media (min-width: 640px) { .cabecalho-pagina h1 { font-size: 2.75rem; } }
.cabecalho-pagina .subtitulo { margin-top: 1rem; font-size: 1.125rem; line-height: 1.625; color: rgb(var(--ink-2)); text-wrap: pretty; }
.cabecalho-pagina .subtitulo a { color: rgb(var(--link)); text-decoration: underline; text-decoration-color: rgb(var(--link) / 0.35); text-underline-offset: 3px; }
.cabecalho-pagina .subtitulo a:hover { text-decoration-color: rgb(var(--link)); text-decoration-thickness: 2px; }

.grade-pagina { display: grid; gap: 2.5rem; }
@media (min-width: 1024px) { .grade-pagina { grid-template-columns: 12rem minmax(0, 1fr); gap: 4rem; } }
.secoes { min-width: 0; display: flex; flex-direction: column; gap: 5rem; }

/* Índice lateral (PageIndex.astro) */
.indice { margin: 0 -1rem; padding: 0 1rem; overflow-x: auto; }
.indice ol { display: flex; gap: 1.25rem; width: max-content; padding: 0.75rem 0; border-top: 1px solid rgb(var(--line)); border-bottom: 1px solid rgb(var(--line)); font-family: var(--mono); font-size: 0.75rem; line-height: 1rem; }
.indice a { display: flex; gap: 0.5rem; white-space: nowrap; color: rgb(var(--ink-2)); transition: color 150ms; }
.indice a:hover { color: rgb(var(--accent)); }
.indice a[aria-current="true"] { color: rgb(var(--ink)); }
.indice a span { color: rgb(var(--accent)); }
@media (min-width: 1024px) {
  .indice { position: sticky; top: 6rem; align-self: start; margin: 0; padding: 0; overflow: visible; }
  .indice ol { flex-direction: column; gap: 0; width: auto; padding: 0; border: 0; border-left: 1px solid rgb(var(--line)); }
  .indice a { margin-left: -1px; padding: 0.375rem 0 0.375rem 1rem; border-left: 2px solid transparent; white-space: normal; }
  .indice a[aria-current="true"] { border-left-color: rgb(var(--accent)); }
}

/* Título de seção (SectionHeader.astro): 01  Título ──────────── */
.titulo-secao { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1.75rem; }
@media (min-width: 640px) { .titulo-secao { gap: 1rem; } }
.titulo-secao .num { flex: none; font-family: var(--mono); font-size: 0.75rem; color: rgb(var(--accent)); }
.titulo-secao h2 { min-width: 0; scroll-margin-top: 6rem; font-size: 1.5rem; font-weight: 600; line-height: 1.25; letter-spacing: -0.02em; text-wrap: balance; }
@media (min-width: 640px) { .titulo-secao h2 { font-size: 1.625rem; } }
.titulo-secao .linha { flex: 1; min-width: 1rem; height: 1px; background: rgb(var(--line)); }
.titulo-secao .conta { flex: none; font-family: var(--mono); font-size: 0.75rem; color: rgb(var(--ink-3)); }

/* ── Cards (ProjectCard.astro) ──────────────────────────────────────────── */
.cards { display: grid; gap: 1.5rem; }
@media (min-width: 768px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgb(var(--line));
  border-radius: 12px;
  background: rgb(var(--surface));
  box-shadow: 0 1px 2px rgb(var(--shadow) / 0.06);
  transition: border-color 150ms, box-shadow 150ms;
}
.dark .card { box-shadow: none; }
.card:hover { border-color: rgb(var(--line-strong)); box-shadow: 0 14px 30px -14px rgb(var(--shadow) / 0.28); }

.card .barra { display: flex; align-items: center; gap: 0.5rem; height: 1.75rem; padding: 0 0.75rem; border-bottom: 1px solid rgb(var(--line)); background: rgb(var(--sunken)); }
.card .barra .ponto { width: 0.5rem; height: 0.5rem; border-radius: 999px; border: 1px solid rgb(var(--line-strong)); flex: none; }
.card .barra .dominio { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--mono); font-size: 0.75rem; color: rgb(var(--ink-3)); }

.card .capa { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; border-bottom: 1px solid rgb(var(--line)); background: rgb(var(--sunken)); }
.card .capa img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform 300ms ease-out, filter 300ms ease-out; }
.card .capa.quatro-tercos img { object-fit: contain; object-position: center; }
.card:hover .capa img { transform: translateY(-4px); }
.dark .card .capa img { filter: brightness(0.8); }
.dark .card:hover .capa img { filter: brightness(1); }
.card .capa .sem-capa { display: grid; place-items: center; width: 100%; height: 100%; }
.card .capa .sem-capa svg { width: 3rem; height: 3rem; opacity: 0.8; }

.card .corpo { display: flex; flex: 1; flex-direction: column; gap: 0.625rem; padding: 1.25rem; }
.card h3 { font-size: 1.1875rem; font-weight: 600; line-height: 1.35; letter-spacing: -0.015em; text-wrap: balance; }
.card h3 a { transition: color 150ms; }
.card h3 a:hover { color: rgb(var(--accent)); }
.card .subtitulo { font-family: var(--serif); font-style: italic; font-size: 1.0625rem; line-height: 1.4; color: rgb(var(--ink-2)); }
.card .evento { font-size: 0.9375rem; line-height: 1.6; color: rgb(var(--ink-2)); text-wrap: pretty; }
.card .rodape { display: flex; flex-direction: column; gap: 0.75rem; margin-top: auto; padding-top: 0.5rem; }
.chips { display: flex; flex-wrap: wrap; gap: 0.375rem; }
.chip { display: inline-flex; align-items: center; gap: 0.25rem; padding: 0.125rem 0.5rem; border: 1px solid rgb(var(--line)); border-radius: 6px; font-family: var(--mono); font-size: 0.75rem; line-height: 1rem; letter-spacing: 0.02em; color: rgb(var(--ink-3)); }
.chip.acento { border-color: transparent; background: rgb(var(--accent) / 0.1); color: rgb(var(--accent)); }
.acoes { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.5rem 1.25rem; padding-top: 0.75rem; border-top: 1px solid rgb(var(--line)); }
.acao { display: inline-flex; align-items: center; gap: 0.25rem; font-family: var(--mono); font-size: 0.75rem; line-height: 1rem; color: rgb(var(--ink-2)); text-decoration: underline; text-decoration-color: rgb(var(--line-strong)); text-underline-offset: 4px; transition: color 150ms, text-decoration-color 150ms; }
.acao:hover { color: rgb(var(--accent)); text-decoration-color: rgb(var(--accent)); }
.acao svg { width: 0.75rem; height: 0.75rem; }

/* ── Rodapé (Footer.astro) ──────────────────────────────────────────────── */
.rodape-site { border-top: 1px solid rgb(var(--line)); }
.rodape-site .container { display: grid; gap: 2rem; padding-top: 2.5rem; padding-bottom: 2.5rem; }
@media (min-width: 768px) { .rodape-site .container { grid-template-columns: 1fr auto; align-items: start; } }
.rodape-site .quem { display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem 0.625rem; }
.rodape-site .quem svg { width: 1.25rem; height: 1.25rem; }
.rodape-site .quem .nome { white-space: nowrap; font-weight: 500; }
.rodape-site .quem .cargo { flex-basis: 100%; font-size: 0.875rem; color: rgb(var(--ink-3)); }
@media (min-width: 640px) { .rodape-site .quem .cargo { flex-basis: auto; } }
.rodape-site .navegacao { display: flex; flex-wrap: wrap; gap: 0.25rem 1rem; margin-top: 0.75rem; font-size: 0.875rem; }
.rodape-site .navegacao a { color: rgb(var(--ink-2)); transition: color 150ms; }
.rodape-site .navegacao a:hover { color: rgb(var(--accent)); }
.rodape-site .redes { display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem; }
.rodape-site .redes svg { width: 1rem; height: 1rem; }
.rodape-site .colofao { padding-top: 1.25rem; border-top: 1px solid rgb(var(--line)); }
@media (min-width: 768px) { .rodape-site .colofao { grid-column: span 2; } }
.rodape-site .colofao a { text-decoration: underline; text-decoration-color: rgb(var(--line-strong)); text-underline-offset: 3px; }
.rodape-site .colofao a:hover { color: rgb(var(--accent)); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
