/* ════════════════════════════════════════════
   MILONGAS.CSS
   Se carga DESPUÉS de base.css y subpaginas.css
   ════════════════════════════════════════════ */

/* Fuerza ancho máximo siempre, sin importar el contenido */
.subpage-header,
.subpage-container {
  width: min(var(--max-w), 100%);
}

.mg-day {
  border: 2px solid var(--black);
  overflow: hidden;
}

.mg-day-head {
  background: var(--black);
  color: var(--white);
  padding: 0.8rem 1.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
}

.mg-day.today .mg-day-head {
  background: var(--orange);
}

.day-label {
  font-family: var(--font);
  font-weight: 900;
  font-size: clamp(1.4rem, 5vw, 2rem);
  text-transform: uppercase;
  letter-spacing: -0.02em;
  color: var(--white);
  line-height: 1;
}

.day-head-right {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.today-badge {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  background: var(--white);
  color: var(--orange);
  padding: 0.2rem 0.6rem;
}

.mg-day.today .today-badge {
  background: var(--black);
  color: var(--orange);
}

.chevron {
  color: var(--white);
  font-size: var(--text-base);
  transition: transform 0.25s;
  line-height: 1;
}

.mg-day.collapsed .chevron {
  transform: rotate(-90deg);
}

.mg-body {
  background: #f0f8fb;
  padding: 1rem 1.2rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mg-day.collapsed .mg-body {
  display: none;
}

.mg-extra {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--orange);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.section-label {
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--bg);
  margin-bottom: 0.4rem;
  border-bottom: 1px solid var(--bg);
  padding-bottom: 0.2rem;
}

.milonga-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.milonga-item {
  display: flex;
  flex-direction: column;
  padding: 0.45rem 0.7rem;
  background: var(--white);
  border-left: 3px solid var(--bg);
}

.milonga-name {
  font-family: var(--font);
  font-weight: 700;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  color: var(--black);
  line-height: 1.1;
}

.milonga-addr {
  font-size: 0.78rem;
  color: #555;
  font-weight: 400;
  margin-top: 0.15rem;
}

/* ── GRILLA DE SEMANAS ── */

.weeks-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.4rem;
}

.week-col {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.week-num {
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--bg);
  text-align: center;
  padding-bottom: 0.2rem;
  border-bottom: 1px dashed var(--bg);
  margin-bottom: 0.15rem;
}

.week-item {
  background: var(--white);
  border-left: 3px solid var(--orange);
  padding: 0.4rem 0.5rem;
}

.week-item .milonga-name {
  font-size: 0.82rem;
}

.week-item .milonga-addr {
  font-size: 0.7rem;
}

.week-empty {
  background: #f0f8fb;
  border: 1px dashed #cce4ed;
  min-height: 36px;
}

/* ── RESPONSIVE ── */

@media (max-width: 520px) {
  .weeks-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}


/* ══════════════════════════════════════════
   MENSAJES DE ESTADO
   ══════════════════════════════════════════ */

.enc-msg {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--black);
  opacity: 0.6;
  padding: 1rem 0;
  text-align: center;
}

.enc-error { color: #c0392b; opacity: 1; }


/* ══════════════════════════════════════════
   ANUNCIOS DESTACADOS
   ══════════════════════════════════════════ */

/* ── Título separador ── */
.anuncios-titulo {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 0.2rem;
}

.anuncios-titulo-texto {
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--orange);
  white-space: nowrap;
}

.anuncios-titulo-linea {
  flex: 1;
  height: 2px;
  background: var(--orange);
  opacity: 0.4;
}

/* ── Grilla ── */
.anuncios-grilla {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
  margin-bottom: 0.2rem;
}

@media (max-width: 700px) { .anuncios-grilla { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 460px) { .anuncios-grilla { grid-template-columns: 1fr; } }

/* ── Tarjeta base ── */
.anuncio-card {
  border: 3px solid var(--black);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ── Paleta de fondos ── */
.anuncio-fondo-negro  { background: var(--black); }
.anuncio-fondo-gris   { background: var(--grey); }
.anuncio-fondo-blanco { background: var(--white); }

/* Colores de texto según fondo — negro */
.anuncio-fondo-negro .anuncio-nombre        { color: var(--bg); }
.anuncio-fondo-negro .anuncio-nombre-grande { color: var(--bg); }
.anuncio-fondo-negro .anuncio-dato          { color: rgba(255,255,255,0.75); }
.anuncio-fondo-negro .anuncio-dato i        { color: var(--orange); }
.anuncio-fondo-negro .anuncio-lugar-dest    { color: rgba(255,255,255,0.9); font-weight: 700; }
.anuncio-fondo-negro .anuncio-obs           { color: rgba(255,255,255,0.45); }
.anuncio-fondo-negro .anuncio-header-negro  { background: #1a1a1a; }

/* Colores de texto según fondo — gris */
.anuncio-fondo-gris .anuncio-nombre         { color: var(--black); }
.anuncio-fondo-gris .anuncio-nombre-grande  { color: var(--black); }
.anuncio-fondo-gris .anuncio-dato           { color: #444; }
.anuncio-fondo-gris .anuncio-dato i         { color: var(--bg); }
.anuncio-fondo-gris .anuncio-lugar-dest     { color: var(--bg); font-weight: 700; }
.anuncio-fondo-gris .anuncio-obs            { color: #888; }
.anuncio-fondo-gris .anuncio-header-negro   { background: #d0d0d0; }

/* Colores de texto según fondo — blanco */
.anuncio-fondo-blanco .anuncio-nombre        { color: var(--black); }
.anuncio-fondo-blanco .anuncio-nombre-grande { color: var(--black); }
.anuncio-fondo-blanco .anuncio-dato          { color: #444; }
.anuncio-fondo-blanco .anuncio-dato i        { color: var(--bg); }
.anuncio-fondo-blanco .anuncio-lugar-dest    { color: var(--bg); font-weight: 700; }
.anuncio-fondo-blanco .anuncio-obs           { color: #999; }
.anuncio-fondo-blanco .anuncio-header-negro  { background: #e8e8e8; }

/* ── Imagen / video ── */
.anuncio-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.anuncio-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.anuncio-card:hover .anuncio-img        { transform: scale(1.04); }
.anuncio-video-wrap .anuncio-img        { cursor: pointer; }
.anuncio-video-wrap:hover .anuncio-img  { transform: none; }

/* ── Badges ── */
.anuncio-badge {
  position: absolute;
  background: var(--orange);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.58rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  padding: 0.2rem 0.5rem;
  z-index: 2;
}

.anuncio-badge-top { top: 0.5rem; left: 0.5rem; }

/* ── Header sin foto ── */
.anuncio-header-negro {
  padding: 1.2rem 1rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-height: 100px;
  justify-content: flex-end;
  position: relative;
}

.anuncio-nombre-grande {
  font-family: var(--font);
  font-size: clamp(1.1rem, 3vw, 1.6rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 1;
}

/* ── Botón play ── */
.anuncio-play-btn {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 52px; height: 52px;
  background: rgba(0,0,0,0.65);
  border: 2px solid var(--white);
  color: var(--white);
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3;
  transition: background 0.2s;
}

.anuncio-play-btn:hover { background: var(--orange); border-color: var(--orange); }
.anuncio-play-btn i { margin-left: 3px; }

/* ── Datos ── */
.anuncio-datos {
  padding: 0.6rem 0.9rem 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  flex: 1;
}

.anuncio-nombre-fila {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.05rem;
}

.anuncio-nombre {
  font-family: var(--font);
  font-size: 0.92rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  line-height: 1.1;
}

.anuncio-lugar-dest {
  font-size: 0.82rem !important;
  font-weight: 700 !important;
}

.anuncio-dato {
  font-size: 0.73rem;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.anuncio-dato i { font-size: 0.65rem; flex-shrink: 0; }

.anuncio-obs {
  font-size: 0.7rem;
  font-style: italic;
  line-height: 1.4;
  margin-top: 0.05rem;
}

/* ── Botones ── */
.anuncio-botones {
  display: flex;
  gap: 0.4rem;
  margin-top: auto;
  padding-top: 0.5rem;
  flex-wrap: wrap;
}

.anuncio-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.35rem 0.65rem;
  font-family: var(--font);
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-decoration: none;
  transition: opacity 0.2s;
  flex: 1;
  justify-content: center;
}

.anuncio-btn:hover  { opacity: 0.85; }
.anuncio-btn-wa     { background: #25d366 !important; color: #fff !important; }
.anuncio-btn-link   { background: var(--orange) !important; color: #fff !important; }

/* ── Separador ── */
.anuncios-separador {
  height: 2px;
  background: var(--black);
  opacity: 0.15;
  margin: 0.4rem 0;
}

/* ── Imagen clickeable ── */
.anuncio-img-clickable { cursor: zoom-in; }


/* ══════════════════════════════════════════
   LIGHTBOX — overlay para imagen completa.
   ══════════════════════════════════════════ */

.enc-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  padding: 1.5rem;
}

.enc-lightbox.enc-lightbox-visible {
  opacity: 1;
  pointer-events: auto;
}

.enc-lightbox-img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  display: block;
  box-shadow: 0 0 0 3px var(--orange);
}

.enc-lightbox-cerrar {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 40px;
  height: 40px;
  background: var(--orange);
  color: var(--white);
  border: none;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  z-index: 2001;
}

.enc-lightbox-cerrar:hover { background: var(--black); }
