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

html { scroll-behavior: smooth; }

body {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  background: #fff;
  color: #111;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── NAV ─────────────────────────────────────────── */

.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px 24px;
  pointer-events: none;
}

.site-nav a {
  pointer-events: all;
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  text-decoration: none;
  color: #111;
}

.site-nav.over-hero a { color: #fff; }

/* ── EVENTS GRID ─────────────────────────────────── */

.events-grid {
  padding: 80px 24px 80px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px 24px;
}

@media (max-width: 900px) {
  .events-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px 16px;
  }
}

@media (max-width: 540px) {
  .events-grid {
    grid-template-columns: 1fr;
    gap: 48px 0;
    padding: 72px 0 60px;
  }
}

.event-card {
  display: block;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.event-card-thumb {
  width: 100%;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  display: block;
  background: #f0f0f0;
}

.event-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .45s cubic-bezier(.25,.46,.45,.94), opacity .3s;
}

.event-card:hover .event-card-thumb img {
  transform: scale(1.03);
  opacity: .9;
}

.event-card-info {
  padding: 14px 0 0;
}

@media (max-width: 540px) {
  .event-card-info { padding: 12px 24px 0; }
}

.event-card-title {
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  line-height: 1.3;
  margin-bottom: 5px;
}

.event-card-date {
  font-size: .62rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: #999;
}

/* ── FOOTER ──────────────────────────────────────── */

.site-footer {
  text-align: center;
  padding: 48px 0 40px;
  font-size: .58rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #bbb;
}

/* ── EVENT PAGE HERO ──────────────────────────────── */

.event-hero {
  width: 100%;
  height: 100svh;
  position: relative;
  overflow: hidden;
}

.event-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.event-hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(8,10,12,.12) 0%, rgba(8,10,12,.26) 34%, rgba(8,10,12,.72) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 0 24px 58px;
  text-align: center;
  color: #fff;
}

.event-hero-logo {
  font-size: .64rem;
  font-weight: 700;
  letter-spacing: .24em;
  text-transform: uppercase;
  opacity: .84;
  margin-bottom: 20px;
  text-decoration: none;
  color: #fff;
}

.event-hero-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.2rem, 6vw, 5.2rem);
  font-weight: 700;
  letter-spacing: .01em;
  line-height: .98;
  max-width: 980px;
  text-wrap: balance;
}

.event-hero-date {
  margin-top: 16px;
  font-size: .68rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  opacity: .74;
}

/* ── EVENT NAV (categories) ───────────────────────── */

.event-nav {
  position: sticky;
  top: 0;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid #e8e8e8;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 62px;
  overflow: auto;
  padding: 0 20px;
}

.event-nav-back {
  display: flex;
  align-items: center;
  font-size: .6rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  text-decoration: none;
  color: #8c8c8c;
  padding: 0;
  flex-shrink: 0;
  transition: color .15s;
  white-space: nowrap;
}

.event-nav-back:hover { color: #111; }

.event-nav-title {
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #111;
  white-space: nowrap;
  flex-shrink: 0;
}

.event-nav-cats {
  display: flex;
  overflow-x: auto;
  flex: 1;
  justify-content: flex-end;
  scrollbar-width: none;
}

.event-nav-cats::-webkit-scrollbar { display: none; }

.event-nav-cat {
  display: flex;
  align-items: center;
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  padding: 10px 14px;
  border: 1px solid transparent;
  background: #f3f3f1;
  cursor: pointer;
  color: #7f7f7a;
  white-space: nowrap;
  transition: color .15s, border-color .15s, background .15s;
  flex-shrink: 0;
  margin: 0 0 0 8px;
}

.event-nav-cat.active,
.event-nav-cat:hover {
  color: #111;
  border-color: #d8d5cd;
  background: #fff;
}


/* ── MASONRY GRID ─────────────────────────────────── */

.photo-masonry {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 3px;
}

.photo-masonry-batch {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 3px;
}

.photo-load-more {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #9e968a;
  opacity: 0;
  transition: opacity .2s ease;
}

.photo-load-more.is-active {
  opacity: 1;
}

.photo-load-more::before {
  content: "Cargando mas fotos";
}

@media (max-width: 1100px) { .photo-masonry-batch { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 680px)  { .photo-masonry-batch { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 380px)  { .photo-masonry-batch { grid-template-columns: 1fr; } }

.masonry-item {
  display: block;
  aspect-ratio: 4 / 3;
  cursor: pointer;
  overflow: hidden;
  background: #f0f0f0;
  position: relative;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .32s ease, transform .32s ease;
}

.masonry-item.is-ready {
  opacity: 1;
  transform: translateY(0);
}

.masonry-item img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: opacity .2s;
}

@media (max-width: 680px) {
  .masonry-item {
    aspect-ratio: 1 / 1;
  }
}

.masonry-item:hover img { opacity: .82; }

/* ── LIGHTBOX ─────────────────────────────────────── */

.lightbox {
  position: fixed;
  inset: 0;
  background: #000;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;
}

.lightbox.open {
  opacity: 1;
  pointer-events: all;
}

.lightbox-img-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  padding: 48px 64px;
}

.lightbox-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

.lightbox-close {
  position: absolute;
  top: 16px; right: 18px;
  width: 36px; height: 36px;
  border: none; background: none;
  color: rgba(255,255,255,.55);
  font-size: 1.5rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: color .15s;
  line-height: 1;
}
.lightbox-close:hover { color: #fff; }

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: none; background: none;
  color: rgba(255,255,255,.45);
  font-size: 2.2rem;
  cursor: pointer;
  padding: 24px 20px;
  transition: color .15s;
  line-height: 1;
  user-select: none;
}
.lightbox-prev:hover,
.lightbox-next:hover { color: #fff; }
.lightbox-prev { left: 0; }
.lightbox-next { right: 0; }

.lightbox-counter {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  font-size: .55rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
  white-space: nowrap;
}

@media (max-width: 600px) {
  .event-hero-title {
    font-size: clamp(2rem, 13vw, 3.3rem);
  }

  .event-nav {
    gap: 12px;
    min-height: 58px;
    padding: 0 14px;
  }

  .lightbox-img-wrap { padding: 40px 44px; }
  .lightbox-prev, .lightbox-next { font-size: 1.6rem; padding: 16px 12px; }
}
