/* ==============================================
   instagram_feed.css — Feed de Instagram del home
   Rama: feat/instagram-feed
   Diseñado con los design tokens (tokens.css):
   funciona en tema oscuro y claro automáticamente.
   ============================================== */

.igfeed-section {
  padding: 96px 24px 40px;
}

.igfeed-container {
  max-width: 1100px;
  margin: 0 auto;
}

/* ---------- Cabecera ---------- */
.igfeed-head {
  text-align: center;
  margin-bottom: 48px;
}

.igfeed-title {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: var(--font-sans);
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  font-weight: 700;
  color: var(--text-page);
  margin: 0 0 10px;
}

.igfeed-logo {
  color: var(--brand-instagram);
  flex-shrink: 0;
}

.igfeed-accent {
  color: var(--accent-text);
}

.igfeed-subtitle {
  font-family: var(--font-sans);
  font-size: 1rem;
  color: var(--text-body);
  margin: 0;
}

.igfeed-handle {
  color: var(--accent-text);
  text-decoration: none;
  font-weight: 600;
}

.igfeed-handle:hover {
  text-decoration: underline;
}

/* ---------- Grid 1 fila x 3 columnas ---------- */
.igfeed-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.igfeed-item {
  position: relative;
  display: block;
  border-radius: var(--radius-card);
  overflow: hidden;
  border: 1px solid var(--border-card);
  background: var(--bg-image-placeholder);
  text-decoration: none;
}

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

.igfeed-item:hover img {
  transform: scale(1.04);
}

/* Overlay sutil al pasar el cursor (solo decorativo; el enlace completo
   ya es accesible con su title/aria-label) */
.igfeed-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, rgba(0, 19, 29, 0) 40%, rgba(0, 19, 29, 0.82) 100%);
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 0.25s ease;
  padding-bottom: 14px;
  align-items: flex-end;
}

.igfeed-item:hover .igfeed-overlay,
.igfeed-item:focus-visible .igfeed-overlay {
  opacity: 1;
}

/* ---------- Pie: botón al perfil ---------- */
.igfeed-footer {
  text-align: center;
  margin-top: 36px;
}

.igfeed-btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--accent-outline);
  color: var(--accent-text);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.igfeed-btn:hover {
  background: var(--accent-ghost);
  border-color: var(--accent-text);
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .igfeed-section {
    padding: 64px 24px 32px;
  }

  .igfeed-grid {
    grid-template-columns: 1fr;
    gap: 16px;
    max-width: 460px;
    margin: 0 auto;
  }

  .igfeed-item {
    aspect-ratio: 1 / 1;
  }
}
