/* Lightbox da Do it! Print — paleta do site (#0A0B09 / #A8CF45 / Sora + Archivo) */

.doit-lb {
  position: fixed; inset: 0; z-index: 9999;
  display: none; align-items: center; justify-content: center;
  background: rgba(6, 7, 5, .94);
  backdrop-filter: blur(6px);
  padding: 64px 24px;
  opacity: 0;
  transition: opacity .22s ease;
}
.doit-lb.aberto { display: flex; opacity: 1; }

/* trava o scroll do fundo enquanto o lightbox está aberto */
body.doit-lb-travado { overflow: hidden; }

.doit-lb-palco {
  margin: 0; position: relative;
  max-width: 100%; max-height: 100%;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}

.doit-lb-img {
  display: block;
  max-width: min(1200px, 92vw);
  max-height: 78vh;
  width: auto; height: auto;
  border-radius: 14px;
  border: 1px solid rgba(242, 244, 236, .12);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .65);
  background: #12140F;
  opacity: 1;
  transition: opacity .18s ease;
}
.doit-lb.carregando .doit-lb-img { opacity: .25; }

.doit-lb-spinner {
  position: absolute; top: 50%; left: 50%;
  width: 34px; height: 34px; margin: -17px 0 0 -17px;
  border: 2px solid rgba(242, 244, 236, .18);
  border-top-color: #A8CF45;
  border-radius: 50%;
  opacity: 0; pointer-events: none;
  animation: doitLbGira .7s linear infinite;
}
.doit-lb.carregando .doit-lb-spinner { opacity: 1; }
@keyframes doitLbGira { to { transform: rotate(360deg); } }

.doit-lb-rodape {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  justify-content: center; text-align: center;
  font-family: 'Archivo', system-ui, sans-serif;
}
.doit-lb-legenda { font-size: 15px; color: rgba(242, 244, 236, .82); }
.doit-lb-contador {
  font-family: 'Sora', sans-serif; font-size: 13px; font-weight: 600;
  color: #A8CF45; letter-spacing: .06em;
  border: 1px solid rgba(168, 207, 69, .3); border-radius: 100px;
  padding: 4px 12px; white-space: nowrap;
}

/* ---- botões ---- */
.doit-lb-fechar, .doit-lb-nav {
  position: absolute; z-index: 2;
  background: rgba(242, 244, 236, .06);
  border: 1px solid rgba(242, 244, 236, .16);
  color: #F2F4EC;
  border-radius: 50%;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  line-height: 1; padding: 0;
  transition: background .18s ease, border-color .18s ease, color .18s ease, transform .18s ease;
}
.doit-lb-fechar:hover, .doit-lb-nav:hover {
  background: #A8CF45; border-color: #A8CF45; color: #0A0B09;
}
.doit-lb-fechar:focus-visible, .doit-lb-nav:focus-visible {
  outline: 2px solid #A8CF45; outline-offset: 3px;
}

.doit-lb-fechar {
  top: 20px; right: 24px;
  width: 46px; height: 46px; font-size: 30px;
}
.doit-lb-nav {
  top: 50%; margin-top: -26px;
  width: 52px; height: 52px; font-size: 34px;
}
.doit-lb-nav:hover { transform: scale(1.06); }
.doit-lb-ant  { left: 24px; }
.doit-lb-prox { right: 24px; }

/* ===================================================================== */
/* Miniaturas clicáveis (home + portfólio)                                */
/* ===================================================================== */

.doit-foto {
  display: block; position: relative;
  width: 100%; height: 100%;
  overflow: hidden; cursor: zoom-in;
}
.doit-foto img {
  transition: transform .5s cubic-bezier(.16, .84, .36, 1);
}
.doit-foto:hover img { transform: scale(1.06); }

/* véu escuro + lupa no hover */
.doit-foto::after {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(circle at center, rgba(168, 207, 69, .18) 0%, rgba(10, 11, 9, .55) 70%);
  opacity: 0;
  transition: opacity .3s ease;
  pointer-events: none;
}
.doit-foto:hover::after, .doit-foto:focus-visible::after { opacity: 1; }

.doit-foto-lupa {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(.8);
  width: 54px; height: 54px; border-radius: 50%;
  background: #A8CF45; color: #0A0B09;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; font-weight: 700;
  opacity: 0;
  transition: opacity .3s ease, transform .3s cubic-bezier(.16, .84, .36, 1);
  pointer-events: none; z-index: 1;
}
.doit-foto:hover .doit-foto-lupa,
.doit-foto:focus-visible .doit-foto-lupa {
  opacity: 1; transform: translate(-50%, -50%) scale(1);
}
.doit-foto:focus-visible { outline: 2px solid #A8CF45; outline-offset: -2px; }

/* ---- mobile / tablet ---- */
@media (max-width: 900px) {
  .doit-lb { padding: 56px 12px; }
  .doit-lb-img { max-height: 70vh; max-width: 96vw; }
  .doit-lb-fechar { top: 12px; right: 14px; width: 42px; height: 42px; }
  .doit-lb-nav { width: 44px; height: 44px; font-size: 28px; margin-top: -22px; }
  .doit-lb-ant  { left: 8px; }
  .doit-lb-prox { right: 8px; }
  .doit-lb-legenda { font-size: 14px; }

  /* sem hover no toque: a lupa fica sempre visível, discreta */
  .doit-foto-lupa { opacity: .85; transform: translate(-50%, -50%) scale(.85); }
  .doit-foto::after { opacity: .25; }
}

@media (prefers-reduced-motion: reduce) {
  .doit-foto img, .doit-foto::after, .doit-foto-lupa,
  .doit-lb, .doit-lb-img { transition: none; }
  .doit-lb-spinner { animation: none; }
}
