/* Lucas Bonny — página de portfólio. Complementa proposta.css (mesmas variáveis e componentes). */
.visualmente-oculto { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* abertura */
.pf-abertura { position: relative; padding: 150px 0 clamp(64px, 8vw, 110px);
  background: radial-gradient(60% 70% at 85% 20%, rgba(38, 56, 46, .9), transparent 70%), radial-gradient(40% 50% at 5% 95%, rgba(217, 164, 65, .08), transparent 70%), var(--noite); }
.pf-volta { margin-bottom: 2.4rem; }
.pf-abertura .rec { display: flex; margin-bottom: 1.4rem; }
.pf-abertura .titulo--mega { margin-bottom: 2.4rem; }
.pf-abertura__grade { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(28px, 5vw, 72px); align-items: end; }
.pf-abertura .lede { margin: 0; max-width: 46ch; }
.pf-numeros { margin: 0; }
.numeros b i { font-style: italic; font-size: .42em; letter-spacing: 0; vertical-align: .55em; margin-right: .1em; }

/* barra: filtro + índice */
.pf-trabalhos { padding-top: clamp(24px, 3vw, 40px); }
.pf-barra { position: sticky; top: 82px; z-index: 20; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: clamp(40px, 5vw, 72px); pointer-events: none; }
.pf-barra > * { pointer-events: auto; }
.pf-barra .filtro { margin: 0; background: rgba(28, 43, 35, .82); -webkit-backdrop-filter: blur(18px) saturate(150%); backdrop-filter: blur(18px) saturate(150%); box-shadow: 0 12px 32px -18px rgba(0, 0, 0, .8); }
.pf-indice { position: relative; }
.pf-indice summary { list-style: none; display: inline-flex; align-items: center; gap: .6rem; min-height: 52px; padding: 0 1.2rem; border-radius: 999px; background: rgba(28, 43, 35, .82); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); font-family: var(--mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--marfim-2); cursor: pointer; box-shadow: 0 12px 32px -18px rgba(0, 0, 0, .8); }
.pf-indice summary::-webkit-details-marker { display: none; }
.pf-indice summary::after { content: ""; width: 7px; height: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform .2s; }
.pf-indice[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.pf-indice summary:hover { color: var(--marfim); }
.pf-indice ol { position: absolute; right: 0; top: calc(100% + 8px); width: min(380px, calc(100vw - 24px)); max-height: min(60vh, 520px); overflow: auto; margin: 0; padding: 10px; list-style: none; border-radius: 24px; background: rgba(28, 43, 35, .96); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px); border: 1px solid rgba(244, 239, 227, .1); box-shadow: 0 24px 60px -24px rgba(0, 0, 0, .9); }
.pf-indice a { display: flex; gap: .9rem; align-items: baseline; padding: .6rem .8rem; border-radius: 14px; text-decoration: none; font-size: .95rem; line-height: 1.3; }
.pf-indice a:hover { background: rgba(244, 239, 227, .06); }
.pf-indice a b { font-family: var(--mono); font-size: .7rem; font-weight: 500; color: var(--urucum-claro); }

/* projetos */
.projetos { display: grid; gap: clamp(72px, 9vw, 128px); }
.projeto { scroll-margin-top: 160px; display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.projeto__cabeca { position: sticky; top: 168px; display: grid; gap: .9rem; justify-items: start; }
.projeto__cabeca .titulo--2 { margin: 0; }
.projeto__meta { margin: 0; font-family: var(--mono); font-size: .72rem; line-height: 1.6; letter-spacing: .1em; text-transform: uppercase; color: var(--marfim-2); }
.projeto .texto { margin: 0; color: var(--marfim-2); max-width: 40ch; }
.projeto .elo { margin-top: .3rem; }

/* galeria: mosaico de linhas com altura parecida */
.galeria { display: flex; flex-wrap: wrap; gap: clamp(8px, 1vw, 14px); }
.galeria::after { content: ""; flex-grow: 999; }
.foto { position: relative; display: block; flex-grow: 1; height: clamp(180px, 22vw, 300px); overflow: hidden; border-radius: 18px; background: var(--painel); }
.foto--paisagem { flex-basis: 300px; }
.foto--retrato { flex-basis: 170px; }
.galeria--1 .foto { height: auto; flex-basis: 100%; aspect-ratio: 16 / 10; border-radius: var(--raio-midia); }
.galeria--2 .foto { height: clamp(220px, 30vw, 420px); }
.foto img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--mola-t) var(--mola), opacity .3s; }
.foto:hover img { transform: scale(1.04); }
.foto:active { transform: scale(.99); transition: transform 100ms ease-out; }
.foto::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(244, 239, 227, .06); pointer-events: none; }
.projeto.escondido { display: none; }

/* na mídia */
.materias { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2vw, 28px); }
.materia { display: grid; gap: .8rem; align-content: start; text-decoration: none; color: inherit; }
.materia__img { display: block; overflow: hidden; border-radius: var(--raio-midia); aspect-ratio: 16 / 10; background: var(--painel); }
.materia__img img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--mola-t) var(--mola); }
.materia:hover .materia__img img { transform: scale(1.04); }
.materia__titulo { font-family: var(--display); font-variation-settings: "SOFT" 100; font-weight: 500; font-size: 1.2rem; line-height: 1.25; }
.materia:hover .elo svg { transform: translateX(4px); }

/* chamada final */
.pf-cta { display: grid; justify-items: center; text-align: center; gap: 1.2rem; }
.pf-cta .titulo--1 { margin: 0; max-width: 16ch; }
.pf-cta .lede { margin: 0; max-width: 44ch; }
.pf-cta .botoes { justify-content: center; margin-top: .6rem; }

/* luz (foto ampliada) */
.luz { width: 100vw; height: 100svh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: transparent; color: var(--marfim); overflow: hidden; opacity: 0; transition: opacity .25s ease; }
.luz[open] { display: grid; place-items: center; }
.luz.visivel { opacity: 1; }
.luz::backdrop { background: rgba(8, 13, 10, .9); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.luz figure { margin: 0; display: grid; gap: 14px; justify-items: center; padding: 64px 76px 20px; max-width: 100%; }
.luz img { max-width: min(1600px, calc(100vw - 152px)); max-height: calc(100svh - 140px); width: auto; height: auto; border-radius: 18px; transform: scale(.96); transition: transform var(--rapida-t) var(--rapida), opacity .2s; }
.luz.visivel img { transform: none; }
.luz img.trocando { opacity: 0; }
.luz figcaption { display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; justify-content: center; text-align: center; }
.luz__fechar { position: absolute; top: 14px; right: 14px; }
.luz__seta { position: absolute; top: 50%; margin-top: -22px; }
.luz__seta--ant { left: 16px; }
.luz__seta--prox { right: 16px; }

/* responsivo */
@media (max-width: 960px) {
  .pf-abertura { padding-top: 116px; }
  .pf-abertura__grade { grid-template-columns: 1fr; }
  .projeto { grid-template-columns: 1fr; }
  .projeto__cabeca { position: static; }
  .materias { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .pf-barra { top: 76px; flex-wrap: nowrap; }
  .pf-barra .filtro { flex: 1 1 auto; min-width: 0; }
  .pf-indice summary { min-height: 52px; padding: 0 1rem; }
  .pf-indice summary span { display: none; }
  .pf-indice ol { position: fixed; left: 12px; right: 12px; top: 140px; width: auto; }
  .foto { height: 150px; border-radius: 14px; }
  .foto--paisagem { flex-basis: 220px; }
  .foto--retrato { flex-basis: 110px; }
  .galeria--2 .foto { height: 200px; }
  .materias { grid-template-columns: 1fr; }
  .luz figure { padding: 64px 8px 20px; }
  .luz img { max-width: calc(100vw - 16px); max-height: calc(100svh - 170px); border-radius: 12px; }
  .luz__seta { top: auto; bottom: max(14px, env(safe-area-inset-bottom)); margin: 0; }
  .luz__seta--ant { left: calc(50% - 56px); }
  .luz__seta--prox { right: calc(50% - 56px); }
}
@media (prefers-reduced-motion: reduce) {
  .luz img { transform: none; }
}
@media (prefers-reduced-transparency: reduce) {
  .pf-barra .filtro, .pf-indice summary, .pf-indice ol { background: var(--painel); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .luz::backdrop { background: rgba(8, 13, 10, .97); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
