/* ============================================================
   AVC PLAYA — Estilos globales
   ============================================================ */

/* ---------- Google Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=Playfair+Display:wght@600;700&display=swap');

/* ---------- Custom Properties ---------- */
:root {
  --avc-green: #00724D;
  --avc-green-dark: #005A3D;
  --avc-green-light: #e6f5ef;
  --avc-yellow: #EFCA24;
  --avc-yellow-hover: #e0bc18;
  --bg-light: #f6f6f6;
  --bg-sand: #faf8f4;
  --text-dark: #1a1a1a;
  --text-body: #333333;
  --text-muted: #6b6b6b;
  --border-light: #e2e2e2;
  --radius-sm: 0.5rem;
  --radius-md: 1rem;
  --radius-lg: 1.25rem;
  --radius-pill: 999px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.1);
  --shadow-lg: 0 14px 40px rgba(0,0,0,0.18);
  --shadow-hero: 0 20px 50px rgba(0,0,0,0.25);
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'DM Sans', system-ui, -apple-system, sans-serif;
  --max-w: 1100px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text-body);
  background-color: #ffffff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { color: var(--text-dark); }

/* ---------- Utilidades ---------- */
.section-inner { max-width: var(--max-w); margin: 0 auto; }

/* Fade-in on scroll */
.fade-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================================
   HEADER
   ============================================================ */
header {
  background: linear-gradient(160deg, var(--avc-green) 0%, var(--avc-green-dark) 100%);
  color: #ffffff;
  position: relative;
}

/* --- Top bar --- */
.top-bar {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0.45rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
.top-bar a { opacity: 0.9; transition: opacity var(--transition); }
.top-bar a:hover { opacity: 1; text-decoration: underline; }

/* --- Nav --- */
.nav {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0.75rem 1.5rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.logo-img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,0.3);
  transition: transform var(--transition);
}
.logo-wrap:hover .logo-img { transform: scale(1.05); }

.logo-text-main {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: 1.1rem;
}

.logo-text-sub {
  font-size: 0.72rem;
  opacity: 0.8;
  letter-spacing: 0.02em;
}

/* --- Nav links (desktop) --- */
.nav-links {
  display: flex;
  gap: 0.25rem;
  font-size: 0.88rem;
}
.nav-links a {
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-pill);
  transition: background var(--transition);
  font-weight: 500;
}
.nav-links a:hover,
.nav-links a.active {
  background-color: rgba(255,255,255,0.15);
}

/* --- Buttons --- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.65rem 1.5rem;
  border-radius: var(--radius-pill);
  border: none;
  background-color: var(--avc-yellow);
  color: #1a1a1a;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background var(--transition), transform var(--transition);
}
.btn-primary:hover {
  background-color: var(--avc-yellow-hover);
  transform: translateY(-1px);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.6rem 1.3rem;
  border-radius: var(--radius-pill);
  border: 2px solid rgba(255,255,255,0.6);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  background-color: transparent;
  color: #ffffff;
  transition: background var(--transition), border-color var(--transition);
}
.btn-outline:hover {
  background-color: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.9);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.5rem;
  border-radius: var(--radius-pill);
  border: 1.5px solid rgba(255,255,255,0.6);
  background-color: transparent;
  color: #ffffff;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.92rem;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--transition), border-color var(--transition);
}
.btn-ghost:hover {
  background-color: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.9);
}

/* ============================================================
   HAMBURGER MENU (mobile)
   ============================================================ */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 1001;
}
.hamburger span {
  display: block;
  width: 100%;
  height: 2.5px;
  background-color: #ffffff;
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.hamburger.is-active span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.hamburger.is-active span:nth-child(2) { opacity: 0; }
.hamburger.is-active span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  background: linear-gradient(180deg, var(--avc-green-dark) 0%, var(--avc-green) 100%);
  z-index: 1000;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.mobile-menu.is-open {
  display: flex;
  opacity: 1;
}
.mobile-menu a {
  font-size: 1.25rem;
  font-weight: 600;
  color: #ffffff;
  padding: 0.75rem 2rem;
  border-radius: var(--radius-pill);
  transition: background var(--transition);
}
.mobile-menu a:hover {
  background-color: rgba(255,255,255,0.12);
}
.mobile-menu .btn-primary {
  margin-top: 0.5rem;
  font-size: 1.1rem;
  padding: 0.8rem 2.5rem;
}

/* ============================================================
   HERO (generic + home variant)
   ============================================================ */
.hero {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 1.5rem 1.5rem 2.5rem;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 2.5rem;
  align-items: center;
}

.hero--home {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 2rem 1.5rem 3rem;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}
.hero-tag {
  font-size: 0.72rem;
  font-weight: 500;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-pill);
  background-color: rgba(255,255,255,0.15);
  backdrop-filter: blur(4px);
  letter-spacing: 0.02em;
}

.hero-title,
.hero-copy h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.2vw, 2.6rem);
  font-weight: 700;
  margin: 0 0 0.75rem;
  line-height: 1.2;
}

.hero-text,
.hero-copy p {
  margin: 0 0 1.25rem;
  color: rgba(255,255,255,0.88);
  max-width: 36rem;
  font-size: 1rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-bottom: 0.75rem;
}

.hero-note {
  font-size: 0.8rem;
  opacity: 0.85;
}

/* Hero card */
.hero-card {
  background-color: #ffffff;
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  color: var(--text-body);
  box-shadow: var(--shadow-hero);
  transition: transform var(--transition);
}
.hero-card:hover { transform: translateY(-2px); }

.hero-card-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
  color: var(--text-dark);
}
.hero-card-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.85rem;
}
.hero-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
  margin-bottom: 0.85rem;
  font-size: 0.85rem;
  line-height: 1.5;
}
.hero-pill {
  padding: 0.4rem 0.85rem;
  border-radius: var(--radius-pill);
  background-color: var(--avc-green-light);
  color: var(--avc-green-dark);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 500;
}

/* ============================================================
   SECTIONS
   ============================================================ */
main { background-color: #ffffff; }

section { padding: 4rem 1.5rem; }

.section-title {
  font-family: var(--font-display);
  font-size: 1.65rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
  color: var(--text-dark);
}

.section-subtitle {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 1.75rem;
  max-width: 42rem;
}

/* ============================================================
   CARDS (generic)
   ============================================================ */
.card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  background-color: #ffffff;
  padding: 1.5rem;
  font-size: 0.95rem;
  transition: box-shadow var(--transition);
}
.card:hover { box-shadow: var(--shadow-sm); }

/* Chips */
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.4rem;
}
.chip {
  font-size: 0.73rem;
  font-weight: 500;
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-pill);
  background-color: var(--avc-green-light);
  color: var(--avc-green-dark);
}

/* ============================================================
   COMPLEX GRID (complejos + index)
   ============================================================ */
.complex-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
}

.complex-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  overflow: hidden;
  background-color: #ffffff;
  display: flex;
  flex-direction: column;
  min-height: 100%;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}
.complex-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #ccc;
}

.complex-card img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.complex-card:hover img { transform: scale(1.03); }

.complex-main-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
}

.complex-body {
  padding: 1.1rem 1.2rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
}

.complex-location {
  font-size: 0.72rem;
  color: var(--avc-green);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
}

.complex-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--text-dark);
}

.complex-footer {
  padding: 0.85rem 1.2rem 1rem;
  border-top: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.complex-links {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}
.complex-links a {
  font-size: 0.8rem;
  text-decoration: underline;
  color: var(--avc-green);
  font-weight: 500;
  transition: color var(--transition);
}
.complex-links a:hover { color: var(--avc-green-dark); }

.complex-link {
  display: inline-flex;
  margin-top: 0.6rem;
  font-size: 0.85rem;
  text-decoration: underline;
  color: var(--avc-green);
  font-weight: 500;
}

/* ============================================================
   COLS-2 layout (index: quiénes somos, cómo reservar)
   ============================================================ */
.cols-2 {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 2.5rem;
  align-items: flex-start;
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 2rem;
  align-items: flex-start;
}

.contact-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  padding: 1.5rem;
  background: #ffffff;
  font-size: 0.9rem;
}

.contact-row {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin: 0.85rem 0 1rem;
}

.contact-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  font-weight: 600;
}
.contact-value {
  font-weight: 500;
}
.contact-value a {
  color: var(--avc-green);
  transition: color var(--transition);
}
.contact-value a:hover { color: var(--avc-green-dark); text-decoration: underline; }

.info-list {
  font-size: 0.88rem;
  padding-left: 1.1rem;
  margin: 0.35rem 0 0.75rem;
  line-height: 1.7;
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.95rem;
}
.contact-list li { margin-bottom: 0.75rem; }
.contact-list strong { display: inline-block; min-width: 85px; font-weight: 600; }
.contact-list a {
  color: var(--avc-green);
  transition: color var(--transition);
}
.contact-list a:hover { color: var(--avc-green-dark); text-decoration: underline; }

.social-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.85rem;
  margin-top: 1rem;
}
.social-pill {
  padding: 0.4rem 0.85rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-light);
  transition: border-color var(--transition), background var(--transition);
}
.social-pill:hover {
  border-color: #bbb;
  background: var(--bg-light);
}

/* ============================================================
   LOCATION (ubicación)
   ============================================================ */
.location-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
}

.location-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  background: #ffffff;
  padding: 1.1rem 1.2rem 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  transition: box-shadow var(--transition);
}
.location-card:hover { box-shadow: var(--shadow-sm); }

.location-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
}

.map-thumb {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid #e0e0e0;
  background: var(--avc-green-light);
}
.map-thumb iframe {
  width: 100%;
  height: 220px;
  border: 0;
  display: block;
}

.location-link {
  margin-top: 0.25rem;
  font-size: 0.85rem;
  text-decoration: underline;
  align-self: flex-start;
  color: var(--avc-green);
  font-weight: 500;
  transition: color var(--transition);
}
.location-link:hover { color: var(--avc-green-dark); }

/* ============================================================
   UNIT CARDS (departamentos: cefiro, parquer, oldcountry)
   ============================================================ */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-pill);
  border: 1px solid #ccc;
  background-color: #ffffff;
  color: var(--text-body);
  text-decoration: none;
  font-weight: 500;
  transition: background var(--transition), border-color var(--transition);
}
.back-link:hover {
  background-color: var(--bg-light);
  border-color: #aaa;
}

.unit-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.75rem;
}

.unit-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  overflow: hidden;
  background-color: #ffffff;
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--transition);
}
.unit-card:hover { box-shadow: var(--shadow-sm); }

.unit-card img.hero-unit {
  width: 100%;
  height: 0;
  object-fit: cover;
}

.unit-body {
  padding: 1.1rem 1.2rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
  font-size: 0.9rem;
}

.unit-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  margin-bottom: 0.15rem;
  color: var(--text-dark);
}

.unit-link {
  margin-top: 0.4rem;
  font-size: 0.82rem;
  text-decoration: underline;
  align-self: flex-start;
  color: var(--avc-green);
  font-weight: 500;
  transition: color var(--transition);
}
.unit-link:hover { color: var(--avc-green-dark); }

/* Galería miniatura */
.unit-gallery {
  padding: 0.6rem 1.2rem 1.2rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 0.5rem;
}
.unit-gallery img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
}
.unit-gallery img:hover {
  transform: scale(1.04);
  box-shadow: var(--shadow-sm);
}

/* ============================================================
   LIGHTBOX
   ============================================================ */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  backdrop-filter: blur(6px);
}
.lightbox-overlay.is-visible { display: flex; }

.lightbox-content {
  position: relative;
  max-width: 92vw;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.lightbox-image {
  max-width: 100%;
  max-height: 82vh;
  border-radius: var(--radius-md);
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
  object-fit: contain;
  background: #000;
}

.lightbox-caption {
  color: #eee;
  font-size: 0.85rem;
  text-align: center;
  max-width: 80vw;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
  position: absolute;
  border: none;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.4rem;
  backdrop-filter: blur(4px);
  transition: background var(--transition);
}
.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.25);
}

.lightbox-close { top: -52px; right: 0; }
.lightbox-prev { left: -55px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: -55px; top: 50%; transform: translateY(-50%); }

/* ============================================================
   WHATSAPP FLOAT
   ============================================================ */
.wa-float {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 900;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background-color: #25D366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  transition: transform var(--transition), box-shadow var(--transition);
}
.wa-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 24px rgba(0,0,0,0.25);
}
.wa-float svg { width: 28px; height: 28px; fill: #ffffff; }

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  border-top: 1px solid var(--border-light);
  background-color: var(--bg-sand);
  padding: 1.75rem 1.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

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

/* Tablet */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav .btn-outline { display: none; }
  .hamburger { display: flex; }

  .top-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    padding-bottom: 2rem;
  }

  .cols-2,
  .contact-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .complex-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .location-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Mobile */
@media (max-width: 640px) {
  section { padding: 2.5rem 1rem; }

  .hero {
    padding: 1rem 1rem 2rem;
  }
  .hero--home { padding: 1.5rem 1rem 2.5rem; }

  .hero-title,
  .hero-copy h1 { font-size: 1.6rem; }

  .complex-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .location-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .map-thumb iframe { height: 200px; }

  .unit-gallery {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  }
  .unit-gallery img { height: 100px; }

  .lightbox-close { top: 8px; right: 8px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }

  .wa-float {
    bottom: 1rem;
    right: 1rem;
    width: 50px;
    height: 50px;
  }
  .wa-float svg { width: 24px; height: 24px; }
}

/* Small phones */
@media (max-width: 380px) {
  .top-bar { font-size: 0.75rem; padding: 0.35rem 1rem; }
  .nav { padding: 0.5rem 1rem 0.75rem; }
  .logo-img { width: 42px; height: 42px; }
  .logo-text-main { font-size: 0.95rem; }
}
