/* =============================================
   ANFITRIONAS — estilos v3 (mobile optimized)
   ============================================= */

/* =============================================
   HERO
   ============================================= */

.anf-hero {
  position: relative;
  height: 38vh;
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 40px;
  overflow: hidden;
  margin-top: 96px; /* ← header desktop */
  background: linear-gradient(135deg, rgba(107,33,232,0.2), rgba(6,6,8,1));
}

.anf-hero video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.anf-hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 100% 100% at 60% 0%, rgba(232,0,122,0.25) 0%, transparent 60%),
    radial-gradient(ellipse 80% 80% at 10% 100%, rgba(107,33,232,0.25) 0%, transparent 55%),
    linear-gradient(to bottom, rgba(6,6,8,0.35), rgba(6,6,8,0.88));
  z-index: 1;
}

.anf-hero-content {
  position: relative;
  z-index: 2;
  max-width: 700px;
}

.anf-hero-content h1 {
  font-family: var(--font-body);
  font-weight: 900;
  font-size: clamp(2.4rem, 7vw, 5.5rem);
  letter-spacing: -2px;
  line-height: 1;
  color: var(--blanco);
  margin: 12px 0 16px;
}

.anf-hero-content p {
  font-size: 15px;
  font-weight: 300;
  color: var(--gris);
  max-width: 460px;
  line-height: 1.7;
  margin: 0 auto;
}

/* =============================================
   GALERÍA — cuadrícula
   ============================================= */

.anf-galeria {
  padding: 48px 72px 80px;
  position: relative;
  z-index: 1;
}

.anf-header {
  max-width: 1400px;
  margin: 0 auto 20px;
}

.anf-count {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gris-oscuro);
}

.anf-count span { color: var(--rosa); }

.anf-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  max-width: 1400px;
  margin: 0 auto;
}

/* =============================================
   CARD
   ============================================= */

.anf-card {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 3/4;
  border: 1px solid var(--glass-border);
  transition: border-color 0.4s, transform 0.4s, box-shadow 0.4s;
  background: rgba(255,255,255,0.03);
  -webkit-tap-highlight-color: transparent;
}

.anf-card:hover {
  border-color: var(--glass-hover);
  transform: translateY(-6px);
  box-shadow: 0 24px 60px rgba(232,0,122,0.15);
}

.anf-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(232,0,122,0.08) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.4s;
  pointer-events: none;
  z-index: 2;
}

.anf-card:hover::after { opacity: 1; }

.anf-card-img {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center top;
  transition: transform 0.7s ease;
  filter: brightness(0.72);
}

.anf-card:hover .anf-card-img {
  transform: scale(1.07);
  filter: brightness(0.5);
}

.anf-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(6,6,8,0.96) 0%, rgba(6,6,8,0.35) 35%, transparent 60%);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px 14px;
  transition: background 0.4s;
  z-index: 3;
}

.anf-card:hover .anf-card-overlay {
  background: linear-gradient(to top, rgba(6,6,8,0.92) 0%, rgba(6,6,8,0.5) 45%, rgba(6,6,8,0.1) 70%);
}

.anf-card-info {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.anf-card-name {
  display: block;
  font-family: var(--font-body);
  font-weight: 900;
  font-size: 13px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--blanco);
  text-align: center;
}

.anf-card-ver {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--blanco);
  background: rgba(232,0,122,0.25);
  border: 1px solid rgba(232,0,122,0.5);
  padding: 8px 16px;
  border-radius: 3px;
  backdrop-filter: blur(8px);
  /* En desktop: aparece al hover */
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.35s, transform 0.35s;
  white-space: nowrap;
}

.anf-card-ver svg {
  width: 13px; height: 13px;
  stroke: var(--blanco);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  flex-shrink: 0;
}

.anf-card:hover .anf-card-ver {
  opacity: 1;
  transform: translateY(0);
}

/* En touch — mostrar siempre sin hover */
@media (hover: none) {
  .anf-card-ver { opacity: 1; transform: translateY(0); }
  .anf-card:active .anf-card-img { filter: brightness(0.5); transform: scale(1.03); }
}

/* CTA al pie */
.anf-cta {
  max-width: 1400px;
  margin: 48px auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  padding: 32px 40px;
  background: rgba(232,0,122,0.04);
  border: 1px solid rgba(232,0,122,0.15);
  border-radius: 12px;
  flex-wrap: wrap;
}

.anf-cta p {
  font-size: 15px;
  font-weight: 300;
  color: var(--gris);
  letter-spacing: 0.5px;
}

.anf-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--rosa);
  color: var(--blanco);
  padding: 14px 32px;
  border-radius: 3px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  box-shadow: 0 0 24px var(--rosa-glow);
  transition: all 0.3s;
  white-space: nowrap;
}

.anf-cta-btn::after { content: '→'; font-size: 13px; }

.anf-cta-btn:hover {
  box-shadow: 0 0 44px var(--rosa-glow);
  transform: translateY(-2px);
}

/* =============================================
   LIGHTBOX
   ============================================= */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(4,4,6,0.95);
  backdrop-filter: blur(20px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

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

.lightbox-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 820px;
  max-height: 95vh;
  background: rgba(10,10,14,0.98);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 40px 120px rgba(0,0,0,0.8);
  transform: scale(0.96);
  transition: transform 0.35s ease;
}

.lightbox.open .lightbox-panel { transform: scale(1); }

.lightbox-panel.foto-vertical .lb-foto-wrap { max-width: 100%; }
.lightbox-panel.foto-horizontal .lb-foto-wrap { max-width: 100%; }

/* Botón cerrar */
.lightbox-close {
  position: absolute;
  top: 12px; right: 12px;
  width: 38px; height: 38px;
  background: rgba(255,255,255,0.08);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20;
  transition: background 0.3s, border-color 0.3s;
}

.lightbox-close:hover, .lightbox-close:active {
  background: rgba(232,0,122,0.2);
  border-color: var(--rosa);
}

.lightbox-close svg { width: 14px; height: 14px; stroke: var(--blanco); }

/* Flechas entre chicas */
.lb-chica-nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  width: 44px; height: 44px;
  background: rgba(10,10,14,0.85);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2010;
  transition: background 0.3s, border-color 0.3s;
}

.lb-chica-nav:hover { background: rgba(232,0,122,0.2); border-color: var(--rosa); }
.lb-chica-nav svg { width: 18px; height: 18px; stroke: var(--blanco); }
.lb-chica-prev { left: 10px; }
.lb-chica-next { right: 10px; }

/* Zona foto */
.lb-foto-wrap {
  position: relative;
  width: 100%;
  height: 62vh;
  min-height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #06060a;
  overflow: hidden;
  flex-shrink: 0;
}

#lb-img-main {
    width: 100%;
    height: 100%;
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    object-position: center top;
  }

/* Spinner */
.lb-foto-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #06060a;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.lb-foto-loading.visible { opacity: 1; }

.lb-spinner {
  width: 32px; height: 32px;
  border: 2px solid rgba(232,0,122,0.2);
  border-top-color: var(--rosa);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* Flechas de foto */
.lb-foto-controls {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  pointer-events: none;
}

.lb-nav {
  width: 40px; height: 40px;
  background: rgba(6,6,8,0.7);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s, border-color 0.3s;
  pointer-events: all;
  flex-shrink: 0;
}

.lb-nav:hover, .lb-nav:active {
  background: rgba(232,0,122,0.25);
  border-color: var(--rosa);
}

.lb-nav svg { width: 15px; height: 15px; stroke: var(--blanco); fill: none; }

/* Contador */
.lb-foto-counter {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--gris-oscuro);
  background: rgba(6,6,8,0.6);
  padding: 4px 12px;
  border-radius: 20px;
  white-space: nowrap;
}

/* Panel derecho */
.lightbox-right {
  width: 100%;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  border-left: none;
  border-top: 1px solid var(--glass-border);
  overflow-y: auto;
  padding: 14px 20px 18px;
  -webkit-overflow-scrolling: touch;
  max-height: 38vh;
}

.lb-top { margin-bottom: 8px; }

.lb-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--rosa);
  margin-bottom: 6px;
  display: block;
}

.lb-nombre {
  font-family: var(--font-body);
  font-weight: 900;
  font-size: 1.7rem;
  letter-spacing: -0.5px;
  color: var(--blanco);
  margin-bottom: 10px;
  line-height: 1;
}

.lb-desc {
  font-size: 13px;
  font-weight: 300;
  color: var(--gris);
  line-height: 1.7;
}

/* Thumbnails */
.lb-thumbs-wrap { margin-bottom: 12px; flex: 1; }

.lb-thumbs-label {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gris-oscuro);
  margin-bottom: 8px;
}

.lb-thumbs {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 6px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(232,0,122,0.3) transparent;
}

.lb-thumbs img {
  width: 76px;
  height: 76px;
  object-fit: cover;
  border-radius: 6px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color 0.25s, opacity 0.25s;
  opacity: 0.5;
  flex-shrink: 0;
}

.lb-thumb-video {
  width: 76px;
  height: 76px;
  border-radius: 6px;
  cursor: pointer;
  border: 2px solid rgba(232,0,122,0.6);
  background: rgba(232,0,122,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  opacity: 1;
  transition: border-color 0.25s, background 0.25s;
  color: var(--rosa);
}

.lb-thumbs img:hover, .lb-thumbs img:active { opacity: 0.8; transform: scale(1.05); }

.lb-thumbs img.active {
  border-color: var(--rosa);
  opacity: 1;
  box-shadow: 0 0 10px var(--rosa-glow);
}

/* Dots */
.lb-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 10px 0;
}

.lb-dots button {
  width: 18px; height: 3px;
  border-radius: 2px;
  border: none;
  background: rgba(255,255,255,0.2);
  cursor: pointer;
  transition: all 0.3s;
  padding: 0;
}

.lb-dots button.active {
  background: var(--rosa);
  width: 32px;
  box-shadow: 0 0 8px var(--rosa-glow);
}

/* Botones acción */
.lb-actions { display: flex; flex-direction: row; gap: 10px; margin-top: 12px; }

.lb-wha-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #25D366;
  color: var(--blanco);
  padding: 13px 12px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: all 0.3s;
}

.lb-wha-btn:hover, .lb-wha-btn:active {
  background: #1fb856;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37,211,102,0.35);
}

.lb-res-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(232,0,122,0.08);
  border: 1px solid rgba(232,0,122,0.3);
  color: var(--rosa);
  padding: 12px 12px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: all 0.3s;
}

.lb-res-btn:hover, .lb-res-btn:active {
  background: rgba(232,0,122,0.18);
  border-color: var(--rosa);
  transform: translateY(-2px);
}

/* Video */
.lb-video-wrap {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--glass-border);
}

#lb-video {
  width: 100%;
  border-radius: 8px;
  max-height: 180px;
  object-fit: contain;
  background: #06060a;
}

/* =============================================
   RESPONSIVE
   ============================================= */

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

@media (max-width: 900px) {
  .anf-grid { grid-template-columns: repeat(2, 1fr); }
  .lightbox-panel { max-width: 100%; }
  .lb-chica-prev { left: 4px; }
  .lb-chica-next { right: 4px; }
  .lb-chica-nav { width: 36px; height: 36px; }
}

@media (max-width: 768px) {
  /* Hero */
  .anf-hero {
    margin-top: 72px;
    height: auto;
    min-height: 200px;
    padding: 40px 20px 32px;
  }

  .anf-hero-content h1 { font-size: clamp(1.8rem, 8vw, 2.4rem); letter-spacing: -1px; }
  .anf-hero-content p { font-size: 13px; }

  /* Galería */
  .anf-galeria { padding: 32px 16px 52px; }
  .anf-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .anf-card-name { font-size: 11px; letter-spacing: 2px; }
  .anf-card-ver { font-size: 8px; padding: 6px 12px; letter-spacing: 1.5px; }

  /* CTA */
  .anf-cta { padding: 20px 16px; gap: 14px; margin-top: 32px; }
  .anf-cta p { text-align: center; font-size: 13px; }
  .anf-cta-btn { width: 100%; justify-content: center; font-size: 10px; padding: 13px; }

  /* Lightbox — pantalla completa en móvil */
  .lightbox { padding: 0; }
  .lightbox-panel {
    border-radius: 0;
    max-height: 100svh;
    max-width: 100%;
    overflow-y: auto;
  }

  .lb-foto-wrap {
    height: 65svh;
    flex-shrink: 0;
    min-height: 0;
  }

  .lb-chica-nav { display: none; } /* swipe reemplaza en móvil */

  .lightbox { padding: 0; align-items: stretch; }
  .lightbox-panel {
    border-radius: 0;
    max-height: 100svh;
    max-width: 100%;
    height: 100svh;
  }
  .lb-foto-wrap {
    height: auto;
    flex: 1;
    min-height: 0;
  }
  #lb-img-main {
    max-height: 100%;
    max-width: 100%;
    width: auto;
    height: auto;
  }
  .lightbox-right {
    max-height: none;
    flex-shrink: 0;
    padding: 10px 16px 14px;
  }
  .lb-thumbs img { width: 58px; height: 58px; }
  .lb-thumb-video { width: 58px; height: 58px; }
  .lb-actions { gap: 8px; }
  .lb-wha-btn { font-size: 9px; padding: 11px 8px; }
  .lb-res-btn { font-size: 9px; padding: 11px 8px; }
  .lb-dots { padding: 6px 0; }
  .lb-thumbs-label { display: none; }
  .lb-chica-nav { display: none; }

  /* Panel info más compacto */
  .lightbox-right { padding: 16px 16px 20px; }
  .lb-nombre { font-size: 1.4rem; }
  .lb-desc { font-size: 12px; display: none; } /* ocultar descripción para ganar espacio */
  .lb-thumbs img { width: 48px; height: 48px; }
  .lb-top { margin-bottom: 12px; }
  .lb-thumbs-wrap { margin-bottom: 8px; }
}

@media (max-width: 480px) {
  .anf-hero { margin-top: 64px; padding: 32px 14px 24px; min-height: 180px; }
  .anf-hero-content h1 { font-size: 1.7rem; }
  .anf-grid { gap: 6px; }
  .anf-card-name { font-size: 10px; letter-spacing: 1.5px; }
  .lb-thumbs img { width: 44px; height: 44px; }
  .lb-nombre { font-size: 1.3rem; }
  .lb-wha-btn { font-size: 9px; padding: 11px 12px; }
  .lb-res-btn { font-size: 9px; padding: 10px 12px; }
}
