/* Makani · sitio institucional
   Paleta tomada del logo (naranja muestreado #ED9442 tras saturar el logo). El naranja no pasa
   contraste como texto sobre blanco: se usa solo en fondos y botones con
   texto oscuro. Los enlaces usan el azul agua. */

:root {
  --naranja: #ED9442;
  --naranja-oscuro: #CF7A2E;
  --naranja-suave: #FBE8D6;
  --fondo: #FAF7F2;
  --blanco: #FFFFFF;
  --texto: #2B2B2B;
  --texto-2: #6B6B6B;
  --agua: #1F6F8B;
  --agua-oscuro: #14343F;
  --borde: #E9E2D8;
  --radio: 14px;
  --sombra: 0 6px 24px rgba(43, 43, 43, 0.08);
  --cabecera-alto: 68px;
  --fuente: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--cabecera-alto) + 12px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--fuente);
  font-size: 17px;
  line-height: 1.6;
  color: var(--texto);
  background: var(--fondo);
  overflow-x: hidden;
}

img, svg, iframe { max-width: 100%; display: block; }

h1, h2, h3 { line-height: 1.15; margin: 0 0 0.6em; font-weight: 800; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 6vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 4.5vw, 2.3rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
a { color: var(--agua); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--agua-oscuro); }
:focus-visible { outline: 3px solid var(--agua); outline-offset: 3px; border-radius: 4px; }

.contenedor { width: 100%; max-width: 1100px; margin: 0 auto; padding-left: 16px; padding-right: 16px; }
.contenedor--angosto { max-width: 760px; }

.saltar {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  background: var(--agua-oscuro); color: #fff; padding: 8px 14px; border-radius: 8px;
}
.saltar:focus { top: 12px; }

/* Botones */
.boton {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 10px 22px; border-radius: 999px;
  font-weight: 700; text-decoration: none; line-height: 1.2;
  transition: background-color .15s, color .15s, transform .15s, box-shadow .15s;
}
.boton:active { transform: translateY(1px); }
.boton--primario { background: var(--naranja); color: var(--texto); box-shadow: 0 2px 10px rgba(207, 122, 46, 0.35); }
.boton--primario:hover { background: var(--naranja-oscuro); color: var(--texto); }
.boton--claro { background: rgba(255, 255, 255, 0.92); color: var(--agua-oscuro); }
.boton--claro:hover { background: #fff; color: var(--agua-oscuro); }
.icono-wa { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }

/* Cabecera */
.cabecera {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  height: var(--cabecera-alto);
  background: rgba(250, 247, 242, 0.92);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--borde);
}
.cabecera__fila { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.cabecera__logo img { height: 44px; width: auto; }

.hamburguesa {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
  width: 44px; height: 44px; padding: 8px; border: 0; border-radius: 10px;
  background: transparent; cursor: pointer;
}
.hamburguesa span { display: block; height: 2px; background: var(--texto); border-radius: 2px; transition: transform .2s, opacity .2s; }
.menu-abierto .hamburguesa span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-abierto .hamburguesa span:nth-child(2) { opacity: 0; }
.menu-abierto .hamburguesa span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.menu {
  position: fixed; top: var(--cabecera-alto); left: 0; right: 0;
  display: flex; flex-direction: column; gap: 4px;
  padding: 12px 16px 20px;
  background: var(--fondo); border-bottom: 1px solid var(--borde); box-shadow: var(--sombra);
  transform: translateY(-8px); opacity: 0; visibility: hidden; pointer-events: none;
  transition: transform .18s, opacity .18s, visibility .18s;
}
.menu-abierto .menu { transform: none; opacity: 1; visibility: visible; pointer-events: auto; }
.menu a { padding: 12px 8px; font-weight: 600; color: var(--texto); text-decoration: none; border-radius: 8px; white-space: nowrap; }
.menu a:hover { background: var(--naranja-suave); color: var(--texto); }
.menu__ingresar { margin-top: 8px; align-self: flex-start; }
.menu a.menu__ingresar { padding: 10px 22px; }

@media (min-width: 980px) {
  .hamburguesa { display: none; }
  .menu {
    position: static; flex-direction: row; align-items: center; gap: 4px;
    padding: 0; background: transparent; border: 0; box-shadow: none;
    transform: none; opacity: 1; visibility: visible; pointer-events: auto;
  }
  .menu a { padding: 8px 14px; }
  .menu__ingresar { margin: 0 0 0 10px; }
  .cabecera__logo img { height: 50px; }
}

/* Hero */
.hero {
  position: relative; min-height: calc(100svh - var(--cabecera-alto)); margin-top: var(--cabecera-alto);
  display: grid; grid-template-rows: 50fr 50fr; overflow: hidden; color: #fff;
  background: linear-gradient(180deg, #1F6F8B, #14343F); /* respaldo si falta la foto */
}
.hero__foto { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 34% 50%; }
/* En pantallas angostas el recorte se corre a la izquierda para que entre el cartel de Makani; en ancho se ve la foto entera */
@media (min-width: 860px) { .hero__foto { object-position: 50% 50%; } }
.hero__velo {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(20, 52, 63, 0) 0%, rgba(20, 52, 63, 0) 50%, rgba(20, 52, 63, 0.22) 72%, rgba(20, 52, 63, 0.6) 100%);
}
.hero__titulo { position: relative; grid-row: 1; align-self: start; text-align: center; padding: clamp(36px, 7vh, 72px) 16px 0; }
.hero__pie { position: relative; grid-row: 2; align-self: end; text-align: center; padding: 0 16px 96px; }
.hero h1 { max-width: 18ch; margin: 0 auto; color: var(--naranja); font-size: clamp(1.8rem, 5.5vw, 3.4rem); text-shadow: 0 0 2px rgba(0,0,0,.95), 0 0 6px rgba(0,0,0,.7), 0 2px 4px rgba(0,0,0,.6), 0 8px 28px rgba(0,0,0,.45); }
.hero__sub { max-width: 58ch; margin: 0 auto; font-size: clamp(1rem, 2.4vw, 1.25rem); text-shadow: 0 0 2px rgba(0,0,0,.85), 0 1px 4px rgba(0,0,0,.6), 0 2px 16px rgba(0,0,0,.45); }

/* Secciones */
.seccion { padding: 64px 0; }
.seccion--suave { background: var(--blanco); border-top: 1px solid var(--borde); border-bottom: 1px solid var(--borde); }
.intro { color: var(--texto-2); max-width: 62ch; margin-bottom: 2em; }
.parrafo-grande { font-size: clamp(1.05rem, 2.2vw, 1.25rem); }
@media (min-width: 860px) { .seccion { padding: 96px 0; } }

/* Actividades */
.grilla-actividades {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px;
}
.grilla-actividades li {
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  padding: 22px 12px; border-radius: var(--radio);
  background: var(--fondo); border: 1px solid var(--borde);
  font-weight: 700;
}
.grilla-actividades svg {
  width: 56px; height: 56px; fill: none; stroke: var(--agua); stroke-width: 2.2;
  stroke-linecap: round; stroke-linejoin: round;
  padding: 10px; border-radius: 50%; background: var(--naranja-suave);
}
@media (min-width: 640px) { .grilla-actividades { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 960px) { .grilla-actividades { grid-template-columns: repeat(6, 1fr); } }

/* Ser socio */
.socio { display: grid; gap: 32px; }
@media (min-width: 860px) { .socio { grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: start; } }
.lista-check { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.lista-check li { position: relative; padding-left: 38px; }
.lista-check li::before {
  content: ""; position: absolute; left: 0; top: 2px; width: 24px; height: 24px; border-radius: 50%;
  background: var(--naranja) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232B2B2B' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 14px no-repeat;
}
.tarjeta { background: var(--blanco); border: 1px solid var(--borde); border-radius: var(--radio); padding: 28px 24px; box-shadow: var(--sombra); }
.tarjeta .boton { width: 100%; margin: 6px 0 18px; }
.nota { color: var(--texto-2); }
.texto-chico { font-size: 0.9rem; color: var(--texto-2); margin: 0; }

/* Comisión */
.comision { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 20px 16px; }
.comision div { padding: 18px 16px; border-radius: var(--radio); background: var(--fondo); border: 1px solid var(--borde); }
.comision dt { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--agua); margin-bottom: 6px; }
.comision dd { margin: 0; font-weight: 600; line-height: 1.5; }
.comision .cargo { font-weight: 400; color: var(--texto-2); }
@media (min-width: 860px) { .comision { grid-template-columns: repeat(3, 1fr); } }

/* Contacto */
.contacto { display: grid; gap: 32px; }
@media (min-width: 860px) { .contacto { grid-template-columns: 1fr 1.2fr; gap: 56px; align-items: start; } }
address { font-style: normal; }
address p { margin-bottom: 1.1em; }
address strong { color: var(--texto-2); font-size: 0.85rem; text-transform: uppercase; letter-spacing: .06em; }
.contacto__mapa iframe { width: 100%; height: 420px; border: 0; border-radius: var(--radio); box-shadow: var(--sombra); }
.contacto__llegar { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; font-weight: 700; }

/* Pie */
.pie { background: var(--agua-oscuro); color: #D8E3E6; padding: 28px 0; font-size: 0.9rem; }
.pie__fila { display: flex; flex-direction: column; gap: 10px; }
.pie p { margin: 0; }
.pie a { color: #fff; font-weight: 700; }
@media (min-width: 860px) { .pie__fila { flex-direction: row; justify-content: space-between; align-items: center; } }

/* ===== Estilo náutico: arena, agua, olas y viento ===== */
:root {
  --arena-1: #FAF7F2;
  --arena-2: #F3EBDD;
  --agua-1: #EAF4F8;
  --agua-2: #D9EBF2;
}

/* Fondos por sección: arena (cálido) y agua (frío) */
.seccion--arena { background: linear-gradient(180deg, var(--arena-1) 0%, var(--arena-2) 100%); }
.seccion--agua { background: linear-gradient(180deg, var(--agua-1) 0%, var(--agua-2) 100%); }
.seccion--agua .grilla-actividades li { background: rgba(255, 255, 255, 0.75); border-color: rgba(31, 111, 139, 0.12); }
.seccion--agua .comision div { background: rgba(255, 255, 255, 0.75); border-color: rgba(31, 111, 139, 0.12); }
.seccion--agua .intro { color: #4F6670; }

/* Separadores con ola: fondo = color de arriba, ola = color de abajo */
.ola-sep { line-height: 0; overflow: hidden; }
.ola-sep svg { display: block; width: 100%; height: 44px; }
.ola-sep--flip svg { transform: scaleX(-1); }
.ola-sep--arena-agua { background: var(--arena-2); }
.ola-sep--arena-agua path { fill: var(--agua-1); }
.ola-sep--agua-arena { background: var(--agua-2); }
.ola-sep--agua-arena path { fill: var(--arena-1); }
.ola-sep--arena-pie { background: var(--arena-2); }
.ola-sep--arena-pie path { fill: var(--agua-oscuro); }
@media (min-width: 860px) { .ola-sep svg { height: 72px; } }

/* Olas animadas al pie del hero */
.hero { padding-bottom: 0; }
.olas { position: absolute; left: 0; right: 0; bottom: -1px; height: 70px; overflow: hidden; pointer-events: none; }
.olas__capa {
  position: absolute; bottom: 0; left: 0;
  width: 200%; max-width: none; height: 100%;
  animation: ola-deriva linear infinite;
}
.olas__capa--1 { fill: var(--arena-1); animation-duration: 14s; }
.olas__capa--2 { fill: rgba(250, 247, 242, 0.45); animation-duration: 22s; animation-direction: reverse; height: 85%; }
.olas__capa--3 { fill: rgba(31, 111, 139, 0.35); animation-duration: 30s; height: 100%; transform: translateX(-25%); }
@keyframes ola-deriva {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (min-width: 860px) { .olas { height: 100px; } .hero__pie { padding-bottom: 130px; } .hero h1 { max-width: 24ch; font-size: clamp(2.2rem, 3.6vw, 2.8rem); margin-bottom: .45em; } .hero__sub { max-width: 64ch; } }
@media (prefers-reduced-motion: reduce) { .olas__capa { animation: none; } }

/* Marca de agua con el símbolo del logo */
#quienes-somos { position: relative; overflow: hidden; }
#quienes-somos::before {
  content: ""; position: absolute; right: -6%; top: 50%; transform: translateY(-50%);
  width: min(70vw, 620px); aspect-ratio: 900 / 487;
  background: url("../img/simbolo.png") center / contain no-repeat;
  opacity: 0.06; pointer-events: none;
}
#quienes-somos .contenedor { position: relative; }

/* Viñetas con ola en la lista de socio */
.lista-check li::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232B2B2B' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 13c2-2.5 4-2.5 6 0s4 2.5 6 0 4-2.5 6 0'/%3E%3C/svg%3E");
  background-size: 16px;
}

/* Rosa de los vientos en contacto */
.rosa {
  width: 56px; height: 56px; margin-bottom: 12px;
  fill: none; stroke: var(--agua); stroke-width: 1.6; stroke-linejoin: round;
}
.rosa path { fill: rgba(31, 111, 139, 0.15); }
.rosa .rosa__n { fill: var(--naranja); stroke: var(--naranja-oscuro); }

/* El pie ya no necesita borde: lo une la ola */
.pie { padding-top: 22px; }

/* Viento en el hero: ráfagas (2–3 trazos con rulo) que cruzan de izquierda a derecha */
.viento {
  position: absolute; inset: 0; width: 100%; height: 100%; max-width: none;
  pointer-events: none; overflow: hidden;
}
.rafaga path {
  fill: none; stroke: url(#viento-trazo); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: var(--len); stroke-dashoffset: var(--len); opacity: 0;
  animation: trazo var(--dur) linear infinite; animation-delay: var(--delay);
}
.trazo--a { --len: 302px; }
.trazo--b { --len: 418px; }
.trazo--c { --len: 222px; }
.rafaga { animation: deriva var(--dur) linear infinite; animation-delay: var(--delay); }
.rafaga path:nth-child(1) { animation-delay: calc(var(--delay) + 0.25s); }
.rafaga path:nth-child(3) { animation-delay: calc(var(--delay) + 0.5s); }
/* solo en la mitad superior del hero (viewBox de 700 de alto) */
/* mismo ciclo para todas y desfase de un quinto: siempre hay una (a veces dos), nunca un bache */
.rafaga { --dur: 26s; }
.rafaga--1 { --x: 420px;  --y: 60px;  --delay: 0s; }
.rafaga--2 { --x: 700px;  --y: 235px; --delay: -5.2s; }
.rafaga--3 { --x: 560px;  --y: 150px; --delay: -10.4s; }
.rafaga--4 { --x: 820px;  --y: 290px; --delay: -15.6s; }
.rafaga--5 { --x: 640px;  --y: 105px; --delay: -20.8s; }
.rafaga--2 path, .rafaga--4 path { stroke-width: 1.1; }
.rafaga--5 path { stroke-width: 1; }
/* el trazo se dibuja desde la cola hasta el rulo, queda un instante y se desvanece entero; después una pausa */
@keyframes trazo {
  0%   { stroke-dashoffset: var(--len); opacity: 0; }
  3%   { opacity: 0.5; }
  20%  { stroke-dashoffset: 0; opacity: 0.5; }
  22%  { stroke-dashoffset: 0; opacity: 0.5; }
  28%  { stroke-dashoffset: 0; opacity: 0; }
  100% { stroke-dashoffset: 0; opacity: 0; }
}
/* mientras tanto el grupo deriva a velocidad constante */
@keyframes deriva {
  0%   { transform: translate(var(--x), var(--y)); }
  28%  { transform: translate(calc(var(--x) + 160px), var(--y)); }
  100% { transform: translate(calc(var(--x) + 160px), var(--y)); }
}
@media (prefers-reduced-motion: reduce) {
  .rafaga, .rafaga path { animation: none; }
  .rafaga { transform: translate(var(--x), var(--y)); }
  .rafaga path { stroke-dasharray: none; opacity: 0.3; }
}
}
}

/* Pronóstico de viento (widget de Windguru) */
.viento-prono { margin-top: 56px; scroll-margin-top: calc(var(--cabecera-alto) + 12px); }
.viento-prono h3 { font-size: 1.5rem; }
.viento-prono .intro { margin-bottom: 1.2em; }
.viento-prono__widget {
  overflow-x: auto; -webkit-overflow-scrolling: touch;
  background: rgba(255, 255, 255, 0.75); border: 1px solid rgba(31, 111, 139, 0.12);
  border-radius: var(--radio); padding: 12px; margin-bottom: 12px; min-height: 120px;
}
.viento-prono__widget table { max-width: none; }
.viento-prono__aviso { margin: 0; padding: 40px 12px; text-align: center; color: var(--texto-2); }
.viento-prono__aviso[hidden] { display: none; }

/* Ráfaga al pasar por una actividad (solo dispositivos con mouse) */
.grilla-actividades li { position: relative; overflow: hidden; transition: transform .2s, box-shadow .2s; }
.grilla-actividades svg { transition: transform .35s cubic-bezier(.34, 1.56, .64, 1); }
@media (hover: hover) {
  .grilla-actividades li::after {
    content: ""; position: absolute; top: 34%; left: -45%; width: 40%; height: 2px; border-radius: 2px;
    background: linear-gradient(90deg, transparent, rgba(31, 111, 139, 0.55), transparent);
    opacity: 0; pointer-events: none;
  }
  .grilla-actividades li:hover { transform: translateY(-3px); box-shadow: var(--sombra); }
  .grilla-actividades li:hover svg { transform: rotate(-8deg) translateX(3px); }
  .grilla-actividades li:hover::after { animation: rafaga-tarjeta .7s ease-out; }
  @keyframes rafaga-tarjeta {
    0% { left: -45%; opacity: 0; }
    20% { opacity: 1; }
    100% { left: 110%; opacity: 0; }
  }
}
@media (prefers-reduced-motion: reduce) {
  .grilla-actividades li, .grilla-actividades svg { transition: none; }
  .grilla-actividades li:hover::after { animation: none; }
}

/* Hero en teléfonos */
@media (max-width: 480px) {
  .hero h1 { font-size: clamp(1.7rem, 7.5vw, 2rem); }
  .hero__sub { font-size: 0.97rem; }
  .hero__pie { padding-bottom: 84px; }
}
}
