/* ============================================
   Haj Mussi Advogados — style.css
   Cor padrão (vinho): #5C1825
   ============================================ */

:root {
  --vinho: #5C1825;
  --vinho-escuro: #4a121d;
  --vinho-claro: #7a2233;
  --titulo: #3a3a3a;
  --texto: #2b2b2b;
  --texto-suave: #5a5a5a;
  --cinza-fundo: #f6f6f6;
  --branco: #ffffff;
  --borda: #cfcfcf;
  --borda-input: #2b2b2b;
  --max-width: 1140px;
  --radius: 2px;
  --transicao: 0.25s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Roboto', Arial, sans-serif;
  color: var(--texto);
  line-height: 1.6;
  background: var(--branco);
  overflow-x: hidden;
}

h1, h2, h3, h4, h5 {
  font-family: 'Rethink Sans', Arial, sans-serif;
  font-weight: 700;
  line-height: 1.2;
  color: var(--titulo);
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Botões ---------- */
.btn {
  display: inline-block;
  background: #800020;
  color: var(--branco);
  padding: 12px 40px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transicao);
}
.btn:hover { background: var(--vinho-escuro); }

/* ============================================
   HEADER
   ============================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--branco);
  transition: background var(--transicao), box-shadow var(--transicao), backdrop-filter var(--transicao);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: height var(--transicao);
}
.header-inner { height: 120px; }
.logo img { height: 46px; width: auto; transition: height var(--transicao); }
.site-header--dark .logo img{height: 28px}

/* ---------- Estado encolhido + vidro (ao rolar) ---------- */
.site-header.scrolled .header-inner { height: 76px; }
.site-header.scrolled .logo img { height: 38px; }
.site-header--dark.scrolled .logo img { height: 24px; }

/* header claro (home) — vidro branco */
.site-header.scrolled {
  background: rgba(255, 255, 255, 0.72);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  backdrop-filter: saturate(160%) blur(12px);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.08);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
/* header escuro (internas) — vidro vinho */
.site-header--dark.scrolled {
  background: rgba(60, 14, 24, 0.8);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  backdrop-filter: saturate(160%) blur(12px);
  box-shadow: 0 2px 18px rgba(0, 0, 0, 0.28);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.main-nav ul {
  display: flex;
  gap: 50px;
  align-items: center;
}
.main-nav a {
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--texto);
  transition: color var(--transicao);
}
.main-nav a:hover,
.main-nav a.active { color: var(--vinho);}
.main-nav a.active {font-weight: 600}

.nav-dropdown { position: relative; }
.nav-dropdown::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  height: 12px;
}
.nav-dropdown > a::after { content: " ▾"; font-size: 0.7rem; }
.main-nav ul.dropdown-menu {
  display: block;
  position: absolute;
  top: 100%;
  right: 0;
  background: var(--branco);
  width: 280px;
  padding: 8px 0;
  margin-top: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: var(--transicao);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}
.dropdown-menu li { width: 100%; }
.nav-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown-menu li a {
  display: block;
  width: 100%;
  padding: 11px 22px;
  font-size: 0.85rem;
  font-weight: 500;
  white-space: nowrap;
  color: var(--texto);
}
.dropdown-menu li a:hover { background: var(--cinza-fundo); color: var(--vinho); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.6rem;
  color: var(--vinho);
  cursor: pointer;
}

/* ---------- Header escuro (páginas internas) ---------- */
.site-header--dark {
  background: linear-gradient(105deg, var(--vinho) 0%, var(--vinho-escuro) 55%, #2e0b12 100%);
  border-bottom: none;
}
.site-header--dark .main-nav a { color: var(--branco); }
/*.site-header--dark .main-nav a:hover,
.site-header--dark .main-nav a.active { color: rgba(255,255,255,0.7); }*/
.site-header--dark .nav-toggle { color: var(--branco); }
/* dropdown continua claro, então textos voltam ao escuro */
.site-header--dark .dropdown-menu li a { color: var(--texto); }
.site-header--dark .dropdown-menu li a:hover { color: var(--vinho); }

/* ============================================
   BANNER DE PÁGINA INTERNA
   ============================================ */
.page-banner {
  background: var(--cinza-fundo);
  padding: 90px 0;
  border-bottom: 6px solid var(--vinho);
}
.page-banner h1 {
  color: var(--vinho);
  font-size: 3rem;
  text-transform: uppercase;
  line-height: 1.1;
}

/* ============================================
   CONTEÚDO DE PÁGINA INTERNA
   ============================================ */
.page-content { padding: 80px 0; }
.page-content .rich { max-width: 920px; }
.page-content .rich p {
  margin-bottom: 22px;
  text-align: justify;
  color: var(--texto);
  font-size: 1rem;
}
.page-content .rich ul {
  list-style: disc;
  padding-left: 22px;
  margin-bottom: 22px;
}
.page-content .rich li {
  margin-bottom: 8px;
  text-align: justify;
}
.page-content .btn { margin-top: 14px; }

/* ============================================
   SOBRE — BANNER COM DESCRIÇÃO
   ============================================ */
.banner-split {
  display: flex;
  grid-template-columns: auto 1fr;
  align-items: center;
  justify-content: center;
  gap: 48px;
}
.banner-split h1 {
  color: var(--vinho);
  font-size: 3.6rem;
  text-transform: uppercase;
  line-height: 1.1;
  padding-right: 48px;
  border-right: 1px solid var(--borda);
}
.banner-split p {
  color: var(--texto);
  font-size: 1.05rem;
  max-width: 520px;
}

/* ---------- Blocos Estrutura / Atendimento / Sede ---------- */
.sobre-blocos { max-width: 760px; margin: 0 auto; }
.sobre-bloco { margin-bottom: 56px; }
.sobre-bloco h3 {
  font-size: 1.7rem;
  text-transform: uppercase;
  margin-bottom: 22px;
  position: relative;
  padding-left: 72px;
}
.sobre-bloco h3::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 1px;
  background: var(--titulo);
}
.sobre-bloco p {
  color: var(--texto-suave);
  text-align: justify;
  padding-left: 72px;
}

/* ============================================
   PERFIL DE ADVOGADO
   ============================================ */
.perfil-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 56px;
  align-items: start;
}
.perfil-info h1 {
  color: var(--vinho);
  font-size: 2.6rem;
  text-transform: uppercase;
  line-height: 1.1;
  margin-bottom: 8px;
}
.perfil-info .oab {
  font-size: 0.95rem;
  color: var(--texto-suave);
  margin-bottom: 14px;
}
.perfil-email {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.92rem;
  color: var(--vinho);
  margin-bottom: 32px;
  transition: color var(--transicao);
}
.perfil-email:hover { color: var(--vinho-escuro); text-decoration: underline; }
.perfil-email img {
  width: 17px; height: 17px;
  /* ícone é branco (feito p/ footer); recolore para vinho no fundo claro */
  filter: brightness(0) saturate(100%) invert(11%) sepia(38%) saturate(3200%) hue-rotate(322deg) brightness(95%) contrast(95%);
}
.perfil-info p {
  margin-bottom: 22px;
  text-align: justify;
  color: var(--texto);
}
.perfil-quali {
  list-style: none;
  margin: 0 0 26px;
  padding: 0;
}
.perfil-quali li {
  position: relative;
  padding-left: 22px;
  margin-bottom: 12px;
  color: var(--texto);
  text-align: left;
}
.perfil-quali li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 8px;
  height: 8px;
  background: var(--vinho);
  border-radius: 50%;
}
.perfil-foto {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  position: relative;
  min-height: 740px;
  display: flex;
  align-items: center;
  color: var(--branco);
  background: url('assets/img/hero.jpg') center/cover no-repeat;
}
.hero-content { width: 100%; }
.hero h1 {
  font-size: 2.8rem;
  text-transform: uppercase;
  margin-bottom: 20px;
  color: var(--branco);
  max-width: 750px;
}
.hero p {
  font-size: 1.05rem;
  margin-bottom: 50px;
  max-width: 460px;
  color: var(--branco);
  border-bottom: 1px solid #fff;
  padding-bottom: 50px;
}

/* ============================================
   ÁREAS DE ATUAÇÃO
   ============================================ */
.section { padding: 80px 0; }
.eyebrow {
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 3px;
  font-size: 1rem;
  color: var(--texto-suave);
  font-family: 'Rethink Sans', Arial, sans-serif;
  font-weight: 400;
  margin-bottom: 10px;
}

.eyebrow--solo { margin-bottom: 52px; }

.areas-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 64px;
}
.area-card { border-left: 1px solid var(--borda); padding: 4px 0 4px 32px; }
.area-card h3 {
  font-size: 1.5rem;
  text-transform: uppercase;
  margin-bottom: 20px;
}
.area-card p {
  color: var(--texto-suave);
  font-size: 0.95rem;
  margin-bottom: 16px;
  text-align: justify;
}
.area-card .btn { margin-top: 8px; }

/* ============================================
   FAIXA DESTAQUE
   ============================================ */
.faixa {
  border-top: 6px solid var(--vinho);
  border-bottom: 6px solid var(--vinho);
  text-align: center;
  padding: 64px 0;
}
.faixa h2 {
  color: var(--vinho);
  font-size: 2rem;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.faixa p {
  max-width: 560px;
  margin: 0 auto 28px;
  color: var(--texto);
}

/* ============================================
   ADVOGADOS
   ============================================ */
.advogados { background: var(--cinza-fundo); }
.section-title {
  text-align: center;
  font-size: 2.1rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 56px;
}
.time-grid {
  display: flex;
  flex-direction: column;
  gap: 40px;
  max-width: 860px;
  margin: 0 auto;
}
.time-linha {
  display: flex;
  justify-content: center;
  gap: 40px;
}
.time-linha .advogado {
  flex: 0 1 260px;
  max-width: 260px;
}
.advogado { text-align: center; }
.advogado-foto {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  margin-bottom: 18px;
}
.advogado h4 {
  font-size: 1.05rem;
  text-transform: uppercase;
  line-height: 1.3;
}
.advogado .oab {
  font-size: 0.78rem;
  color: var(--texto-suave);
  margin: 6px 0 14px;
}
.advogado .btn { padding: 8px 22px; font-size: 0.72rem; }

/* ============================================
   CONTATO
   ============================================ */
.contato-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.contato h2 {
  font-size: 1.9rem;
  text-transform: uppercase;
  margin-bottom: 32px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.form-group { margin-bottom: 26px; }
.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--titulo);
  margin-bottom: 10px;
}
.form-group input,
.form-group textarea {
  width: 100%;
  padding: 15px 16px;
  border: 1px solid var(--borda-input);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 0.9rem;
  transition: border-color var(--transicao);
}
.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--vinho);
}
.form-group textarea { resize: vertical; min-height: 150px; }
.mapa {
  width: 100%;
  height: 100%;
  min-height: 620px;
  border: 0;
  border-radius: var(--radius);
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: var(--vinho);
  color: rgba(255,255,255,0.85);
  padding: 56px 0 24px;
}
.footer-logo { text-align: center; margin: 0 auto 40px; border-bottom: 1px solid #fff;padding-bottom: 30px;width: 75%;}
.footer-logo img { height: 50px; margin: 0 auto; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1.5fr 1fr 1.7fr;
  gap: 32px;
}
.footer-grid h5 {
  font-family: 'Roboto', sans-serif;
  text-transform: uppercase;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin-bottom: 18px;
  color: var(--branco);
}
.footer-grid p,
.footer-grid li {
  font-size: 0.85rem;
  margin-bottom: 10px;
  line-height: 1.5;
}
.footer-grid a:hover { color: var(--branco); text-decoration: underline; }
.footer-social { display: flex; gap: 20px; margin-top: 16px; }
.footer-social a {
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  transition: var(--transicao);
}
.footer-social a img {
  width: 28px; height: 28px;
  transition: var(--transicao);
}
/*.footer-social a:hover { background: var(--branco); border-color: var(--branco); }*/
/* inverte o ícone branco para vinho no hover (fundo branco) */
.footer-social a:hover img {
  transform: scale(1.1);
}
.footer-contato-item { display: flex; gap: 10px; align-items: flex-start; }
.footer-ico {
  width: 18px; height: 18px;
  flex-shrink: 0;
  margin-top: 2px;
}
.copyright {
  text-align: center;
  margin-top: 44px;
  padding-top: 22px;
  border-top: 1px solid #fff;
  font-size: 0.78rem;
}

/* ============================================
   SCROLL REVEAL
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
  will-change: opacity, transform;
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}
/* atraso escalonado para itens em sequência */
.reveal[data-delay="1"] { transition-delay: 0.08s; }
.reveal[data-delay="2"] { transition-delay: 0.16s; }
.reveal[data-delay="3"] { transition-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ============================================
   RESPONSIVO
   ============================================ */
@media (max-width: 900px) {
  .areas-grid,
  .contato-grid,
  .footer-grid { grid-template-columns: 1fr; }
  .time-linha { flex-wrap: wrap; }
  .footer-grid { gap: 36px; }
  .banner-split { grid-template-columns: 1fr; gap: 24px; }
  .banner-split h1 { border-right: none; padding-right: 0; }
  .perfil-grid { grid-template-columns: 1fr; gap: 32px; }
  .perfil-foto { max-width: 360px; }
}

@media (max-width: 768px) {
  .nav-toggle { display: block; }
  .main-nav {
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--branco);
    border-bottom: 1px solid var(--borda);
    display: none;
  }
  /* menu mobile herda fundo claro mesmo no header escuro, p/ legibilidade */
  .site-header--dark .main-nav { background: var(--vinho-escuro); border-bottom-color: rgba(255,255,255,0.12); }
  .site-header--dark .main-nav li { border-bottom-color: rgba(255,255,255,0.12); }
  .main-nav.open { display: block; }
  .main-nav ul {
    flex-direction: column;
    gap: 0;
    padding: 12px 24px;
  }
  .main-nav li { width: 100%; border-bottom: 1px solid var(--borda); }
  .main-nav a { display: block; padding: 14px 0; }
  .main-nav ul.dropdown-menu {
    position: static;
    opacity: 1; visibility: visible;
    transform: none; box-shadow: none; border: none;
    width: auto; margin-top: 0;
    background: transparent;
    /* recolhido por padrão no mobile */
    max-height: 0;
    overflow: hidden;
    padding: 0 0 0 16px;
    transition: max-height 0.32s ease;
  }
  .nav-dropdown.submenu-open ul.dropdown-menu {
    max-height: 420px;
  }
  /* seta do "Serviços" gira quando aberto */
  .nav-dropdown > a::after { transition: transform var(--transicao); display: inline-block; }
  .nav-dropdown.submenu-open > a::after { transform: rotate(180deg); }
  .site-header--dark .dropdown-menu li a { color: var(--branco); }

  .hero h1 { font-size: 2rem; }
  .form-row { grid-template-columns: 1fr; }

  /* banner interno menor */
  .page-banner { padding: 56px 0; }
  .page-banner h1 { font-size: 2.2rem; }
  .banner-split { min-height: 0; }
  .banner-split h1 { font-size: 2.4rem; }

  /* blocos do Sobre: tirar recuo grande no mobile */
  .sobre-bloco h3 { padding-left: 56px; font-size: 1.4rem; }
  .sobre-bloco h3::before { width: 40px; }
  .sobre-bloco p { padding-left: 0; }

  /* perfil mobile */
  .perfil-info h1 { font-size: 2rem; }

  /* seções com menos respiro vertical */
  .section { padding: 56px 0; }
  .page-content { padding: 48px 0; }
}
/* ============================================
   WHATSAPP FLUTUANTE + POPUP
   ============================================ */
.wa-float {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 900;
}
.wa-btn {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25D366;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.wa-btn:hover { transform: scale(1.06); box-shadow: 0 8px 26px rgba(0,0,0,0.32); }
.wa-btn svg { width: 34px; height: 34px; fill: #fff; }

.wa-pulse::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(37,211,102,0.6);
  animation: wa-pulse 2.2s infinite;
}
@keyframes wa-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(37,211,102,0.55); }
  70%  { box-shadow: 0 0 0 18px rgba(37,211,102,0); }
  100% { box-shadow: 0 0 0 0 rgba(37,211,102,0); }
}

.wa-popup {
  position: fixed;
  right: 22px;
  bottom: 94px;
  width: 320px;
  max-width: calc(100vw - 44px);
  background: var(--branco);
  border-radius: 14px;
  box-shadow: 0 16px 44px rgba(0,0,0,0.28);
  overflow: hidden;
  z-index: 901;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px) scale(0.98);
  transform-origin: bottom right;
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
}
.wa-popup.open { opacity: 1; visibility: visible; transform: translateY(0) scale(1); }
.wa-popup__head {
  background: #075E54;
  color: #fff;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.wa-popup__head .wa-avatar {
  width: 40px; height: 40px; border-radius: 50%;
  background: #25D366; display:flex; align-items:center; justify-content:center; flex-shrink:0;
}
.wa-popup__head .wa-avatar svg { width: 22px; height: 22px; fill:#fff; }
.wa-popup__head strong { font-family: 'Rethink Sans', sans-serif; font-size: 0.95rem; display:block; }
.wa-popup__head span { font-size: 0.72rem; opacity: 0.85; }
.wa-popup__close {
  margin-left: auto; background: none; border: none; color:#fff;
  font-size: 1.3rem; cursor: pointer; line-height: 1; opacity: 0.8;
}
.wa-popup__close:hover { opacity: 1; }
.wa-popup__body { padding: 18px; }
.wa-popup__body p { font-size: 0.85rem; color: var(--texto-suave); margin-bottom: 14px; }
.wa-popup__body input {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--borda);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9rem;
  margin-bottom: 10px;
}
.wa-popup__body input:focus { outline: none; border-color: #25D366; }
.wa-popup__send {
  width: 100%;
  background: #25D366;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: background 0.2s ease;
}
.wa-popup__send:hover { background: #1ebe5b; }
.wa-popup__send svg { width: 18px; height: 18px; fill:#fff; }

@media (max-width: 480px) {
  .wa-float { right: 16px; bottom: 16px; }
  .wa-popup { right: 16px; bottom: 86px; }
}

/* ============================================
   GALERIA + LIGHTBOX
   ============================================ */
.galeria {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 200px;
  grid-auto-flow: dense;
  gap: 12px;
}
.galeria-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  border-radius: 3px;
  background: var(--cinza-fundo);
}
.galeria-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  display: block;
}
.galeria-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(92,24,37,0.45), rgba(92,24,37,0) 55%);
  opacity: 0;
  transition: opacity 0.35s ease;
}
.galeria-item:hover img { transform: scale(1.06); }
.galeria-item:hover::after { opacity: 1; }
.galeria-item .galeria-zoom {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(0.85);
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,0.92);
  display: flex; align-items: center; justify-content: center;
  opacity: 0;
  transition: opacity 0.35s ease, transform 0.35s ease;
  z-index: 2;
}
.galeria-item:hover .galeria-zoom { opacity: 1; transform: translate(-50%,-50%) scale(1); }
.galeria-item .galeria-zoom svg { width: 20px; height: 20px; fill: var(--vinho); }

/* padrão de destaque: alguns itens ocupam mais espaço */
.galeria-item.wide { grid-column: span 2; }
.galeria-item.tall { grid-row: span 2; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(20, 6, 10, 0.92);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox__img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  transform: scale(0.96);
  transition: transform 0.3s ease;
}
.lightbox.open .lightbox__img { transform: scale(1); }
.lightbox__close,
.lightbox__nav {
  position: absolute;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  color: #fff;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s ease;
  z-index: 2;
}
.lightbox__close:hover,
.lightbox__nav:hover { background: rgba(255,255,255,0.28); }
.lightbox__close {
  top: 22px; right: 22px;
  width: 46px; height: 46px;
  border-radius: 50%;
  font-size: 1.5rem;
  line-height: 1;
}
.lightbox__nav {
  top: 50%;
  transform: translateY(-50%);
  width: 52px; height: 52px;
  border-radius: 50%;
  font-size: 1.6rem;
}
.lightbox__nav.prev { left: 24px; }
.lightbox__nav.next { right: 24px; }
.lightbox__counter {
  position: absolute;
  bottom: 24px; left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,0.85);
  font-size: 0.85rem;
  letter-spacing: 1px;
}

@media (max-width: 900px) {
  .galeria { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 160px; }
  .galeria-item.wide { grid-column: span 1; }
  .galeria-item.tall { grid-row: span 1; }
}
@media (max-width: 560px) {
  .galeria { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 130px; gap: 8px; }
  .lightbox__nav { width: 42px; height: 42px; }
  .lightbox__nav.prev { left: 10px; }
  .lightbox__nav.next { right: 10px; }
  .lightbox__close { top: 14px; right: 14px; }
}