/* ============================================================
   SOLUCIONES JURÍDICAS UY — Footer Section CSS
   Paleta: #233E49 (bg) | #9C7F5B (dorado) | #FFFFFF
   Tipografía: Cormorant Garamond + Jost
   ============================================================ */

/* ── Footer Principal ─────────────────────────────────────────── */
.footer {
  position: relative;
  background-color: var(--color-bg-deeper);
  border-top: 1px solid rgba(156, 127, 91, 0.2);
  padding: 64px 0 32px;
  margin-top: auto;
}

/* Fondo con textura sutil (coherente con hero) */
.footer::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    -55deg,
    transparent,
    transparent 80px,
    rgba(156, 127, 91, 0.02) 80px,
    rgba(156, 127, 91, 0.02) 81px
  );
  pointer-events: none;
}

/* ── Container ───────────────────────────────────────────────── */
.footer .container {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  width: 100%;
  margin: 0 auto;
  padding: 0 40px;
}

/* ── Grid Principal ──────────────────────────────────────────── */
.footer__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 48px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(156, 127, 91, 0.15);
}

/* ── Columnas ───────────────────────────────────────────────── */
.footer__column {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Logo */
.footer__logo {
  margin-bottom: 8px;
}

.footer__logo-img {
  max-width: 180px;
  height: auto;
  opacity: 0.95;
}

/* Descripción */
.footer__description {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  line-height: 1.7;
  color: var(--color-text-body);
  margin: 0;
}

.footer__description strong {
  color: var(--color-gold-pale);
  font-weight: 500;
}

/* Redes sociales */
.footer__social {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 8px;
}

.footer__social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: rgba(156, 127, 91, 0.1);
  border-radius: 50%;
  color: var(--color-gold-pale);
  transition: all var(--transition);
  border: 1px solid rgba(156, 127, 91, 0.2);
}

.footer__social-link:hover {
  background: var(--color-gold);
  color: var(--color-bg-deeper);
  border-color: var(--color-gold);
  transform: translateY(-3px);
}

.footer__social-link svg {
  width: 18px;
  height: 18px;
}

/* Títulos de columna */
.footer__title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--color-white);
  margin: 0 0 8px 0;
  position: relative;
  display: inline-block;
}

/* Línea decorativa bajo el título */
.footer__title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--color-gold), transparent);
}

/* Listas de enlaces */
.footer__links,
.footer__contact {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer__link-item {
  margin: 0;
}

.footer__link {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--color-text-body);
  text-decoration: none;
  transition: all var(--transition);
  display: inline-block;
  position: relative;
}

.footer__link::before {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--color-gold);
  transition: width 0.3s var(--ease-out);
}

.footer__link:hover {
  color: var(--color-gold-pale);
  transform: translateX(4px);
}

.footer__link:hover::before {
  width: 100%;
}

/* Contacto items */
.footer__contact-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--color-text-body);
  line-height: 1.5;
}

.footer__contact-item svg {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  color: var(--color-gold);
}

.footer__contact-link {
  color: var(--color-text-body);
  text-decoration: none;
  transition: color var(--transition);
}

.footer__contact-link:hover {
  color: var(--color-gold-pale);
}

.footer__contact-item span {
  color: var(--color-text-body);
}

/* ── Banda inferior ──────────────────────────────────────────── */
.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  padding-top: 32px;
  font-family: var(--font-sans);
  font-size: 0.75rem;
}

.footer__copyright p {
  margin: 0;
  color: var(--color-text-muted);
}

.footer__legal {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.footer__legal-link {
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color var(--transition);
}

.footer__legal-link:hover {
  color: var(--color-gold-pale);
}

.footer__legal-separator {
  color: var(--color-text-muted);
  opacity: 0.5;
}

.footer__credits p {
  margin: 0;
  color: var(--color-text-muted);
}

.footer__credit-link {
  color: var(--color-gold-pale);
  text-decoration: none;
  transition: color var(--transition);
}

.footer__credit-link:hover {
  color: var(--color-white);
}


/* ── Botón Volver Arriba (Back to Top) - IZQUIERDA ───────────────────────── */
    .back-to-top {
        position: fixed;
        bottom: 30px;
        left: 30px;      /* Cambiado de right a left */
        width: 48px;
        height: 48px;
        background: var(--color-gold, #9c7f5b);
        border: none;
        border-radius: 50%;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        color: var(--color-bg-deeper, #1a1a1a);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
        transition: all 0.3s ease;
        opacity: 0;
        visibility: hidden;
        transform: translateY(20px);
        z-index: 1000;
    }

    .back-to-top--visible {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .back-to-top:hover {
        background: var(--color-gold-light, #b8956e);
        transform: translateY(-4px);
        box-shadow: 0 6px 20px rgba(156, 127, 91, 0.4);
    }

    .back-to-top:active {
        transform: translateY(-2px);
    }

    .back-to-top svg {
        width: 24px;
        height: 24px;
        stroke-width: 2;
    }

    /* ── Botones Sociales (WhatsApp e Instagram) - DERECHA ───────────────────────── */
    .social-buttons {
        position: fixed;
        bottom: 30px;
        right: 30px;
        display: flex;
        flex-direction: column;
        gap: 15px;
        z-index: 1000;
    }

    .social-btn {
        width: 48px;
        height: 48px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        text-decoration: none;
        color: white;
        font-size: 24px;
        transition: all 0.3s ease;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    }

    .social-btn:hover {
        transform: translateY(-4px);
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
    }

    .social-btn:active {
        transform: translateY(-2px);
    }

    .whatsapp {
        background: #25D366;
    }

    .whatsapp:hover {
        background: #20b859;
    }

    .instagram {
        background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    }

    .instagram:hover {
        filter: brightness(0.95);
    }

    /* Ajuste para pantallas pequeñas */
    @media (max-width: 768px) {
        .back-to-top {
            bottom: 20px;
            left: 20px;
            width: 40px;
            height: 40px;
        }
        
        .social-buttons {
            bottom: 20px;
            right: 20px;
            gap: 12px;
        }
        
        .social-btn {
            width: 40px;
            height: 40px;
            font-size: 20px;
        }
        
        .back-to-top svg {
            width: 20px;
            height: 20px;
        }
    }
/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .footer .container {
    padding: 0 24px;
  }

  .footer__grid {
    gap: 32px;
  }
}

@media (max-width: 768px) {
  .footer {
    padding: 48px 0 24px;
  }

  .footer__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
    padding-bottom: 40px;
  }

  .footer__bottom {
    flex-direction: column;
    text-align: center;
    gap: 16px;
  }

  .footer__legal {
    justify-content: center;
  }

  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 42px;
    height: 42px;
  }
}

@media (max-width: 480px) {
  .footer .container {
    padding: 0 16px;
  }

  .footer__grid {
    grid-template-columns: 1fr;
    gap: 32px;
    padding-bottom: 32px;
  }

  .footer__column {
    text-align: center;
    align-items: center;
  }

  .footer__title::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .footer__link::before {
    display: none;
  }

  .footer__link:hover {
    transform: none;
  }

  .footer__contact-item {
    justify-content: center;
  }

  .footer__social {
    justify-content: center;
  }

  .footer__legal {
    flex-direction: column;
    gap: 8px;
  }

  .footer__legal-separator {
    display: none;
  }

  .back-to-top {
    bottom: 16px;
    right: 16px;
    width: 38px;
    height: 38px;
  }
}

/* ── Animaciones para elementos con AOS ──────────────────────── */
[data-aos="fade-up"] {
  opacity: 0;
  transform: translateY(30px);
  animation: aosFooterUp 0.7s var(--ease-out) forwards;
}

@keyframes aosFooterUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Asegurar que los elementos con delay tengan la animación */
[data-aos-delay="100"] { animation-delay: 0.1s; }
[data-aos-delay="200"] { animation-delay: 0.2s; }
[data-aos-delay="300"] { animation-delay: 0.3s; }
[data-aos-delay="400"] { animation-delay: 0.4s; }
[data-aos-delay="500"] { animation-delay: 0.5s; }