/* =========================================================
   Los Paisas — Landing (HTML/CSS/JS puro)
   Responsive + CTA WhatsApp clickeable
   ========================================================= */

/* -------- Reset básico -------- */
*{ box-sizing:border-box; }
html,body{ height:100%; }
body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color:#fff;
  background:#000;
  overflow-x:hidden; /* evita scroll horizontal en móviles */
}
img{ max-width:100%; display:block; }
a{ color:inherit; text-decoration:none; }
button{ font:inherit; }

/* -------- Tokens -------- */
:root{
  --bg:#000;
  --bg2:#0a0a0a;
  --text:#fff;
  --muted: rgba(255,255,255,.78);
  --muted2: rgba(255,255,255,.62);

  --gold: #f2b705;
  --gold2:#ffcc2e;

  --card: rgba(255,255,255,.06);
  --stroke: rgba(255,255,255,.12);

  --radius: 18px;
  --shadow: 0 22px 70px rgba(0,0,0,.55);

  /* ✅ Gutter consistente en toda la web */
  --gutter: 16px;
  --container-max: 1120px;
}

@media (min-width: 768px){
  :root{ --gutter: 24px; }
}

/* -------- Layout -------- */
.container{
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.center{ text-align:center; }

.section{
  padding: clamp(52px, 6vw, 86px) 0;
}
.section--dark{
  background: radial-gradient(1200px 500px at 20% 0%, rgba(242,183,5,.28), transparent 55%), #000;
}
.section--black{ background:#000; }

/* -------- Buttons (base) -------- */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  padding: 14px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  color:#fff;
  font-weight:900;
  letter-spacing:.2px;
  transition: transform .12s ease, background .12s ease, border-color .12s ease;
}
.btn:hover{
  transform: translateY(-1px);
  border-color: rgba(255,255,255,.22);
  background: rgba(255,255,255,.09);
}
.btn:active{ transform: translateY(0); }
.btn--lg{ padding: 16px 22px; font-size: 1.05rem; }

.btn--wa{
  background: #25D366;
  border: 0;
  box-shadow: 0 16px 40px rgba(37, 211, 102, .28);
}
.btn--wa:hover{ background:#22c55e; }

.wa-ic{
  width:18px;
  height:18px;
  fill: currentColor;
  stroke: currentColor;
  flex: 0 0 auto;
}
.wa-ic--hero{
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
}

/* =========================================================
   HERO
   ========================================================= */
.hero{
  position: relative;
  isolation: isolate; /* crea contexto y evita overlays raros */
  min-height: calc(100vh - 20px);
  padding: clamp(36px, 5vw, 62px) 0 34px;
  overflow:hidden;
  background:#000;
}

/* ✅ el fondo NO debe bloquear clics */
.hero__bg{
  position:absolute;
  inset:-40% -10%;
  background:
    radial-gradient(700px 320px at 12% 28%, rgba(242,183,5,.45), transparent 55%),
    radial-gradient(520px 260px at 88% 18%, rgba(242,183,5,.28), transparent 60%),
    radial-gradient(700px 520px at 40% 60%, rgba(255,204,46,.10), transparent 65%),
    linear-gradient(90deg, rgba(0,0,0,.92), rgba(0,0,0,.65), rgba(0,0,0,.92));
  pointer-events:none !important;
  z-index:0;
}

.hero__grid{
  position:relative;
  z-index:2;
  display:grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(18px, 4vw, 34px);
  align-items:center;
}

.hero__copy{ padding-top: 6px; }

/* Tipografías fluidas */
.kicker{
  margin:0 0 8px;
  font-weight: 950;
  letter-spacing: 2px;
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  line-height: 1;
}
.hero__title{
  margin:0 0 14px;
  font-size: clamp(1.45rem, 2.6vw, 2.05rem);
  letter-spacing: .6px;
  color: rgba(255,255,255,.92);
}
.hero__lead{
  margin: 0;
  color: var(--muted);
  max-width: 50ch;
  font-size: clamp(.98rem, 1.3vw, 1.05rem);
  line-height: 1.55;
}

.hero__media{
  position:relative;
  z-index:2;
  justify-self:end;
  width: min(420px, 100%);
}

/* Media card responsive */
.media-card{
  position:relative;
  border-radius: var(--radius);
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.14);
  overflow:hidden;
  box-shadow: var(--shadow);
  /* ✅ por si algún navegador raro decide capturar algo encima */
  pointer-events: auto;
}
.media-card img{
  width:100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center 30%;
}
.media-card__glow{
  position:absolute;
  inset:-30%;
  background: radial-gradient(500px 260px at 50% 20%, rgba(242,183,5,.35), transparent 60%);
  pointer-events:none !important;
  mix-blend-mode: screen;
  opacity:.7;
}

/* CTA row (fuera o dentro de secciones) */
.hero__cta-row{
  position: relative;
  z-index: 10; /* ✅ más alto que todo */
  margin-top: clamp(16px, 3vw, 22px);
  display:flex;
  justify-content:center;
}

/* Botón WA */
.hero__wa{
  width: min(720px, 100%);
  margin: 0 auto;
  padding: 20px 28px;
  border-radius: 999px;

  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap: 16px;

  text-transform: uppercase;
  letter-spacing: .6px;
  font-weight: 950;
  font-size: 1.05rem;

  flex-wrap: nowrap;

  position: relative;
  z-index: 11; /* ✅ arriba de todo */
  pointer-events: auto !important;
}

.hero__wa-text{
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  line-height: 1.1;
}

/* =========================================================
   TYPO sections
   ========================================================= */
.h2{
  margin: 0 0 12px;
  font-size: clamp(1.8rem, 4.5vw, 3.1rem);
  line-height: 1.08;
  font-weight: 950;
}
.p{
  margin: 0 auto;
  color: var(--muted);
  max-width: 64ch;
  font-size: clamp(1rem, 1.3vw, 1.1rem);
  line-height: 1.6;
}
.p--tight{
  max-width: 62ch;
  margin-left: 0;
}

/* =========================================================
   ABOUT
   ========================================================= */
.about{
  display:grid;
  grid-template-columns: .95fr 1.05fr;
  gap: clamp(18px, 4vw, 44px);
  align-items:center;
}

.photo{
  border-radius: var(--radius);
  overflow:hidden;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.03);
  box-shadow: var(--shadow);
}

/* ====== ✅ FIX: foto más alta y sin recorte SOLO en #quienes ====== */
#quienes .photo{
  height: clamp(320px, 36vw, 560px); /* más alto (ajusta si quieres) */
  overflow: hidden;
  background: #000; /* relleno si la imagen no llena */
}

/* ===== ABOUT (#quienes): que la foto se vea COMPLETA ===== */
#quienes .photo{
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.03);
  box-shadow: var(--shadow);
}

#quienes .photo img{
  width: 100%;
  height: auto;          /* ✅ respeta proporción real */
  aspect-ratio: auto;    /* ✅ anula el 16/10 */
  object-fit: contain;   /* ✅ no recorta */
  object-position: center;
  display: block;
}

/* ===== Default (para otras fotos, si existieran) ===== */
.photo img{
  width: 100%;
  height: auto;          /* mejor que no forzar 100% */
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: center 25%;
}

.about__copy .accent{ color: var(--gold); }

/* Aire real entre párrafos y botón */
#quienes .about__copy .p{ margin-bottom: 16px; }

/* Botón WA dentro del about */
.hero__wa--about{
  width: min(720px, 100%);
  margin: 0 auto;
}

/* ✅ Safe-area abajo para móviles (iPhone) */
#quienes.section{
  padding-bottom: calc(clamp(52px, 6vw, 86px) + max(18px, env(safe-area-inset-bottom)));
}
@media (max-width: 740px){
  #quienes.section{
    padding-bottom: calc(70px + max(22px, env(safe-area-inset-bottom)));
  }
  /* En móvil, un poquito más alta aún para que se luzca */
  #quienes .photo{
    height: clamp(320px, 72vw, 520px);
  }
}

/* =========================================================
   TO TOP
   ========================================================= */
.to-top{
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 54px;
  height: 54px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(20,20,20,.92);
  box-shadow: 0 12px 35px rgba(0,0,0,.45);
  display: grid;
  place-items: center;
  color: rgba(255,255,255,.85);
  cursor: pointer;
  z-index: 9999;

  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity .18s ease, transform .18s ease, background .18s ease, border-color .18s ease;
}
.to-top svg{ width: 22px; height: 22px; }

.to-top.is-visible{
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.to-top:hover{
  background: rgba(30,30,30,.95);
  border-color: rgba(255,255,255,.14);
}
.to-top:active{ transform: translateY(2px); }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 980px){
  .hero__grid{ grid-template-columns: 1fr; }
  .hero__media{
    justify-self:start;
    width: min(520px, 100%);
  }
  .hero__copy{ text-align:center; }
  .hero__lead{
    margin-left:auto;
    margin-right:auto;
    max-width: 60ch;
  }
}

@media (max-width: 740px){
  .hero{ padding-top: 42px; }

  .hero__wa{
    width: 100%;
    padding: 18px 18px;
    font-size: 1rem;
  }

  .about{ grid-template-columns: 1fr; }

  /* ✅ en móvil el tight se centra igual que el resto */
  .p--tight{
    margin-left:auto;
    margin-right:auto;
  }
  .about__copy{ text-align:center; }

  .hero__wa-text{ max-width: 74vw; }
}

@media (max-width: 420px){
  .hero__wa{
    padding: 16px 14px;
    font-size: .98rem;
    gap: 12px;
  }
  .wa-ic--hero{
    width: 26px;
    height: 26px;
    flex: 0 0 26px;
  }
}

@media (prefers-reduced-motion: reduce){
  *{ scroll-behavior:auto !important; transition:none !important; }
}

/* =========================================================
   WhatsApp flotante (arranca arriba a la derecha)
   ========================================================= */
.wa-float{
  position: fixed;
  right: 18px;
  top: 18px; /* ✅ esquina superior derecha */
  width: 58px;
  height: 58px;
  border-radius: 999px;
  background: #25D366;
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 18px 45px rgba(37, 211, 102, .35);
  z-index: 9999;
  border: 0;
  text-decoration: none;
  transition: transform .12s ease, filter .12s ease;
}

.wa-float:hover{ transform: translateY(-1px); filter: brightness(1.02); }
.wa-float:active{ transform: translateY(0); }

.wa-float__ic{ width: 28px; height: 28px; }

/* ✅ Respeta safe-area (iPhone notch) */
@supports (padding: max(0px)){
  .wa-float{
    top: calc(18px + env(safe-area-inset-top));
  }
}

@media (max-width: 740px){
  .wa-float{
    right: 14px;
    top: 14px;
    width: 56px;
    height: 56px;
  }
  @supports (padding: max(0px)){
    .wa-float{
      top: calc(14px + env(safe-area-inset-top));
    }
  }
}
/* =========================================================
   WhatsApp flotante con texto (arriba derecha) — PRO
   ========================================================= */
.wa-float{
  position: fixed;
  right: 18px;
  top: 18px;

  display: inline-flex;
  align-items: center;
  gap: 10px;

  /* ✅ tamaño “pro” (no aplastado) */
  min-height: 52px;
  padding: 12px 16px;

  border-radius: 999px;
  background: #25D366;
  color: #fff;
  text-decoration: none;

  /* ✅ acabado */
  border: 1px solid rgba(255,255,255,.18);
  box-shadow: 0 16px 38px rgba(37, 211, 102, .28), 0 10px 22px rgba(0,0,0,.35);
  z-index: 9999;

  font-weight: 900;
  letter-spacing: .2px;
  line-height: 1.15;

  /* ✅ transiciones suaves */
  transition: transform .14s ease, filter .14s ease, box-shadow .14s ease;
  will-change: transform;
}

.wa-float:hover{
  transform: translateY(-2px);
  filter: brightness(1.03);
  box-shadow: 0 18px 44px rgba(37, 211, 102, .32), 0 12px 26px rgba(0,0,0,.38);
}
.wa-float:active{ transform: translateY(0); }

/* ✅ Focus accesible (teclado) */
.wa-float:focus-visible{
  outline: 3px solid rgba(255,255,255,.45);
  outline-offset: 3px;
}

.wa-float__ic{
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
}

.wa-float__text{
  white-space: nowrap;
  font-size: .98rem;
}

/* ✅ safe-area (iPhone notch) */
@supports (padding: max(0px)){
  .wa-float{
    top: calc(18px + env(safe-area-inset-top));
  }
}

/* 📱 En móvil: compacto pero legible */
@media (max-width: 740px){
  .wa-float{
    right: 12px;
    top: 12px;
    min-height: 48px;
    padding: 10px 12px;
  }
  .wa-float__ic{
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
  }
  .wa-float__text{
    font-size: .92rem;
  }
  @supports (padding: max(0px)){
    .wa-float{
      top: calc(12px + env(safe-area-inset-top));
    }
  }
}

/* 📱 Muy pequeño: solo ícono (no estorba) */
@media (max-width: 380px){
  .wa-float__text{ display:none; }
  .wa-float{
    padding: 12px;
    min-height: 52px;
  }
}
/* =========================================================
   WhatsApp flotante (solo texto) — PRO
   Verde + texto negro | desktop abajo derecha | móvil pill no full
   ========================================================= */
.wa-float{
  position: fixed;
  right: 18px;
  bottom: 86px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: auto;
  min-width: 220px;
  max-width: calc(100vw - 24px);

  min-height: 52px;
  padding: 12px 18px;

  border-radius: 999px;
  background: #25D366;
  color: #000;                /* ✅ texto negro real */
  text-decoration: none;

  border: 1px solid rgba(0,0,0,.18);
  box-shadow: 0 16px 38px rgba(37, 211, 102, .26), 0 10px 22px rgba(0,0,0,.35);
  z-index: 9999;

  font-weight: 900;
  letter-spacing: .2px;
  line-height: 1.15;

  transition: transform .14s ease, filter .14s ease, box-shadow .14s ease;
  will-change: transform;
}

.wa-float:hover{
  transform: translateY(-2px);
  filter: brightness(1.03);
  box-shadow: 0 18px 44px rgba(37, 211, 102, .30), 0 12px 26px rgba(0,0,0,.38);
}
.wa-float:active{ transform: translateY(0); }

.wa-float:focus-visible{
  outline: 3px solid rgba(255,255,255,.45);
  outline-offset: 3px;
}

/* ✅ TEXTO: forzado visible (evita “desaparece en móvil”) */
.wa-float__text{
  display: inline-block !important; /* ✅ pisa reglas viejas */
  white-space: nowrap;
  font-size: .98rem;

  overflow: visible;
  text-overflow: clip;
}

/* ✅ iPhone safe-area (desktop/tablet) */
@supports (padding: max(0px)){
  .wa-float{
    bottom: calc(86px + env(safe-area-inset-bottom));
  }
}

/* =========================================================
   MÓVIL: pill NO full-width (arriba derecha) + texto visible
   ========================================================= */
@media (max-width: 740px){
  .wa-float{
    right: 12px;
    top: 12px;
    bottom: auto;

    min-height: 46px;
    padding: 10px 14px;

    min-width: 200px;
    max-width: 86vw;          /* ✅ no ocupa toda la pantalla */
  }

  .wa-float__text{
    font-size: .95rem;
  }

  @supports (padding: max(0px)){
    .wa-float{
      top: calc(12px + env(safe-area-inset-top));
    }
  }
}

/* 📱 Muy pequeño: reduce mínimo para que quepa */
@media (max-width: 360px){
  .wa-float{ min-width: 170px; }
  .wa-float__text{ font-size: .92rem; }
}

@media (max-width: 740px){
  .hero{
    padding-top: calc(104px + env(safe-area-inset-top));
  }
}
