/* ==================================================
   PALETA Y BASE
================================================== */
:root {
  --bg: #f4f3f1;
  --surface: #ffffff;
  --primary: #a8b9e4;
  --primary-dark: #8da4cf;
  --accent: #d9a7a0;
  --accent-light: #f3ccc6;
  --text: #2f2f2f;
  --text-light: #666;
  --radius: 16px;
  --shadow-soft: 0 4px 18px rgba(0, 0, 0, 0.08);
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
/* Botón flotante de WhatsApp */
.whatsapp-float {
  position: fixed;
  bottom: 18px;
  right: 18px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25d366;               /* color WhatsApp */
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
  z-index: 9999;
  transition: transform .2s ease, box-shadow .2s ease;
}

/* ícono PNG */
.whatsapp-icon {
  width: 65%;
  height: auto;
  display: block;
  user-select: none;
  pointer-events: none;
}

/* Hover (PC) */
.whatsapp-float:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.32);
}

/* Responsive: botones más chicos en pantallas muy pequeñas */
@media (max-width: 480px) {
  .whatsapp-float {
    width: 52px;
    height: 52px;
    bottom: 14px;
    right: 14px;
  }
}

body {
  font-family: "Poppins", "Roboto", sans-serif;
  background: linear-gradient(180deg, #faf9f8, #eceae9);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ==================================================
   HEADER / NAV
================================================== */
header {
  background: linear-gradient(90deg, var(--primary-dark), var(--primary));
  color: #fff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  box-shadow: var(--shadow-soft);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.desk-ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

.desk-ul a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  transition: opacity 0.3s;
}

.desk-ul a:hover {
  opacity: 0.8;
}

/* ==================================================
   HAMBURGUESA + SIDEBAR
================================================== */
.hamburger-menu {
  position: relative;
  width: 32px;
  height: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1100;
}

.hamburger-menu input {
  appearance: none;
  -webkit-appearance: none;
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 10;
}

.hamburger-menu::before,
.hamburger-menu::after,
.hamburger-menu span {
  content: "";
  position: absolute;
  width: 100%;
  height: 3px;
  background: white;
  border-radius: 3px;
  transition: all 0.3s ease;
}

.hamburger-menu::before { top: 0; }
.hamburger-menu::after  { bottom: 0; }
.hamburger-menu span    { top: 50%; transform: translateY(-50%); }

/* animación a "X" */
.hamburger-menu:has(input:checked)::before {
  transform: rotate(45deg);
  top: 50%;
}
.hamburger-menu:has(input:checked)::after {
  transform: rotate(-45deg);
  bottom: 50%;
}
.hamburger-menu:has(input:checked) span {
  opacity: 0;
}

/* SIDEBAR DENTRO DEL HEADER */
.sidebar {
  position: fixed;
  top: 0;
  left: -240px;
  width: 220px;
  height: 100vh;
  background: var(--primary);
  color: white;
  padding: 2rem 1rem;
  transition: left 0.4s ease;
  z-index: 900;
  border-top-right-radius: 20px;
  border-bottom-right-radius: 20px;
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.15);
}

header:has(#menu-toggle:checked) .sidebar {
  left: 0;
}

.sidebar-nav div {
  margin: 1rem 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sidebar-nav a {
  color: white;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 500;
  transition: opacity 0.3s;
}

.sidebar-nav a:hover {
  opacity: 0.8;
}

/* ==================================================
   CALL TO ACTION VOLVER
================================================== */
.calltoaction {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 50px;
  padding: 0.7rem 1.4rem;
  margin: 1.5rem auto;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(217, 167, 160, 0.35);
  transition: var(--transition);
}

.calltoaction:hover {
  background: var(--accent-light);
  color: var(--text);
  transform: translateY(-2px);
}

/* ==================================================
   GALERÍA PRINCIPAL
================================================== */
.gallery-container {
  max-width: 900px;
  margin: 2rem auto;
  padding: 0 1rem;
  text-align: center;
}

.main-image {
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  background: #eaeaea;
  aspect-ratio: 16 / 9;
}

.main-image img {

  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.main-image img:hover {
  transform: scale(1.05);
}

/* ==================================================
   MINIATURAS (SE USAN <img> DIRECTO EN .thumbnails)
================================================== */
.thumbnails {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin: 1.5rem auto;
  max-width: 420px;
  padding: 0.8rem 1rem;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(6px);
  border-radius: 16px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  position: relative;
}

/* ⚠️ IMPORTANTE: se adapta al HTML real -> .thumbnails img */
.thumbnails img {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: 10px;
  cursor: pointer;
  opacity: 0.9;
  transition: transform 0.25s ease, opacity 0.25s ease;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.thumbnails img:hover {
  opacity: 1;
  transform: scale(1.05);
}

/* sólo mostrar primeras 6 miniaturas */
.thumbnails img:nth-of-type(n+7) {
  display: none;
}

/* indicador de que hay más fotos */
.thumbnails::after {
  content: "Ver más fotos →";
  position: absolute;
  bottom: 0;
  right: 0;
  width: 100%;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 500;
  color: #555;
  background: linear-gradient(to top, rgba(255,255,255,0.95), rgba(255,255,255,0));
  padding: 0.6rem 0;
  border-bottom-left-radius: 16px;
  border-bottom-right-radius: 16px;
  pointer-events: none;
}

/* ==================================================
   LIGHTBOX / MODAL
================================================== */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  justify-content: center;
  align-items: center;
  z-index: 2000;
  backdrop-filter: blur(3px);
  animation: fadeIn 0.3s ease;
}

.lightbox img {
  max-width: 90%;
  max-height: 80%;
  border-radius: var(--radius);
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.3);
  object-fit: contain;
}

.lightbox .close {
  position: absolute;
  top: 25px;
  right: 35px;
  background: rgba(255, 255, 255, 0.3);
  color: white;
  font-size: 2rem;
  padding: 0.3rem 0.8rem;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
}

.lightbox .close:hover {
  background: rgba(255, 255, 255, 0.6);
  color: #222;
  transform: scale(1.1);
}

.lightbox .nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.25);
  color: white;
  border: none;
  font-size: 2rem;
  cursor: pointer;
  padding: 0.5rem 1rem;
  border-radius: 50%;
  transition: background 0.3s, transform 0.3s;
}

.lightbox .nav:hover {
  background: rgba(255, 255, 255, 0.5);
  color: #222;
  transform: scale(1.1);
}

.lightbox .prev { left: 40px; }
.lightbox .next { right: 40px; }

/* ==================================================
   INFO DEPARTAMENTO
================================================== */
.info-depto {
  background: var(--surface);
  max-width: 880px;
  margin: 2.5rem auto;
  padding: 2.2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  border: 1px solid #eee;
  animation: fadeUp 0.6s ease;
}

.info-depto h2 {
  color: var(--primary-dark);
  font-size: 1.8rem;
  margin-bottom: 1.4rem;
  text-align: center;
}

.card-depto {
  background: linear-gradient(145deg, #ffffff, #f6f6f6);
  border-radius: var(--radius);
  padding: 1.3rem;
  box-shadow: var(--shadow-soft);
}

.info-list {
  list-style: none;
  margin-top: 1rem;
}

.info-list li {
  margin: 0.5rem 0;
  color: var(--text);
  font-size: 1rem;
}

.info-list strong {
  color: var(--primary-dark);
}

/* ==================================================
   DESCRIPCIÓN COLAPSABLE
================================================== */
.collapsible {
  overflow: hidden;
  max-height: 160px;
  transition: max-height 0.5s ease;
  position: relative;

  /* 🔥 Respeta todos los saltos de línea */
  white-space: pre-line;

  /* 🔥 Mejora legibilidad del párrafo */
  line-height: 1.6;
  letter-spacing: 0.2px;

  /* 🔥 Algo de padding interno */
  padding-bottom: 10px;
}

.collapsible::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 60px;

  /* 🔥 Mantengo tu fade, pero más suave */
  background: linear-gradient(
    to top,
    var(--surface) 0%,
    rgba(255,255,255,0.95) 40%,
    rgba(255,255,255,0) 100%
  );

  pointer-events: none;
  transition: opacity 0.3s ease;
}

.collapsible.expanded {
  max-height: 8200px;
}

.collapsible.expanded::after {
  opacity: 0;
}

.toggle-btn {
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 25px;
  padding: 0.55rem 1.3rem;
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
  transition: var(--transition);
  display: block;
  margin: 0.8rem auto 0 auto;
}

.toggle-btn:hover {
  background: var(--accent-light);
  color: var(--text);
  transform: translateY(-2px);
}
.codigo-copiable {
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 25px;
  padding: 0.55rem 1.3rem;
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
  transition: var(--transition);
  display: block;
  margin: 0.8rem auto 0 auto;
  margin-bottom: 1rem;
}

.codigo-copiable:hover {
  opacity: 0.7;
}

.codigo-icono {
  font-size: 18px;
}

.codigo-mensaje {
  display: none;
  margin-top: 5px;
  color: green;
  font-weight: 500;
  font-size: 14px;
  animation: fade 1.5s ease;
}

@keyframes fade {
  0% { opacity: 0; }
  20% { opacity: 1; }
  80% { opacity: 1; }
  100% { opacity: 0; }
}

/* ==================================================
   UBICACIÓN / MAPA
================================================== */
.ubicacion {
  text-align: center;
  margin: 2rem 0 1rem;
  color: var(--primary-dark);
}

.iframe-container {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.iframe-container iframe {
  width: 90%;
  height: 350px;
  border: none;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

/* ==================================================
   SHARE / TOAST
================================================== */
.share-container {
  text-align: center;
  margin-bottom: 2rem;
}

.share-btn {
  background: var(--primary-dark);
  color: white;
  border: none;
  border-radius: 30px;
  padding: 0.6rem 1.2rem;
  font-size: 1rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  box-shadow: 0 4px 10px rgba(141, 164, 207, 0.3);
  transition: var(--transition);
}

.share-btn:hover {
  background: var(--primary);
  transform: translateY(-2px);
}

.share-msg {
  font-size: 0.9rem;
  color: var(--text-light);
  margin-top: 0.4rem;
}

.toast {
  position: fixed;
  bottom: 25px;
  right: 25px;
  background: var(--accent);
  color: #fff;
  padding: 0.9rem 1.3rem;
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
  display: none;
}

/* ==================================================
   FOOTER
================================================== */
footer {
  background: linear-gradient(90deg, var(--primary-dark), var(--primary));
  color: white;
  text-align: center;
  padding: 2rem 1rem;
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
  margin-top: 3rem;
  box-shadow: 0 -4px 14px rgba(0, 0, 0, 0.15);
}

.footerline {
  height: 2px;
  width: 60%;
  margin: 0 auto 1rem;
  background: rgba(255, 255, 255, 0.4);
}

/* ==================================================
   ANIMACIONES / RESPONSIVE
================================================== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@media (max-width: 768px) {
  .gallery-container { padding: 0 0.5rem; }
  .thumbnails img   { width: 60px; height: 60px; }
  .info-depto       { margin: 1rem; padding: 0.5rem; }
  .iframe-container iframe { height: 250px; }
  .lightbox .close  { top: 20px; right: 20px; font-size: 1.8rem; }
  .lightbox .nav    { font-size: 1.8rem; padding: 0.4rem 0.7rem; }
}
