/* ============================================================
   VÍCTOR IGLESIAS — Entrenador Personal · Las Palmas
   Producción. Marca preservada del handoff (dark + rojo,
   Anton / Archivo / Instrument Sans).
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  --vi-ink-900: #0e0d0c;
  --vi-ink-800: #171513;
  --vi-ink-700: #221f1c;
  --vi-ink-600: #35302b;

  --vi-sand-050: #f3f0ea;
  --vi-sand-200: #c3bcb2;
  --vi-sand-300: #8d867c;

  --vi-red-500: #e11d10;
  --vi-red-400: #ff3a2c;
  --vi-red-600: #b3150b;

  --vi-bg: var(--vi-ink-900);
  --vi-surface: var(--vi-ink-800);
  --vi-border: var(--vi-ink-700);
  --vi-text: var(--vi-sand-050);
  --vi-text-muted: var(--vi-sand-200);
  --vi-text-subtle: var(--vi-sand-300);
  --vi-accent: var(--vi-red-500);
  --vi-accent-hover: var(--vi-red-400);
  --vi-on-accent: var(--vi-sand-050);

  --vi-font-display: 'Anton', 'Arial Narrow', sans-serif;
  --vi-font-expanded: 'Archivo', system-ui, sans-serif;
  --vi-font-body: 'Instrument Sans', system-ui, sans-serif;

  --vi-maxw: 1280px;
  --vi-pad-x: clamp(20px, 5vw, 72px);
  --vi-ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- Reset ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--vi-bg);
  color: var(--vi-text);
  font-family: var(--vi-font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { text-decoration: none; color: inherit; }
img, video { display: block; max-width: 100%; }
h1, h2, p { margin: 0; }
:focus-visible { outline: 3px solid var(--vi-accent-hover); outline-offset: 3px; }

.wrap { max-width: var(--vi-maxw); margin-inline: auto; }
.eyebrow {
  font-family: var(--vi-font-expanded);
  font-weight: 800;
  font-size: clamp(11px, 1.4vw, 13px);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--vi-accent);
}
.h2 {
  font-family: var(--vi-font-display);
  font-size: clamp(36px, 5vw, 68px);
  line-height: 0.94;
  text-transform: uppercase;
  color: var(--vi-sand-050);
}

/* ---------- CTA botón ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--vi-accent);
  color: var(--vi-on-accent);
  font-family: var(--vi-font-expanded);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 18px 32px;
  font-size: clamp(14px, 1.6vw, 16px);
  transition: background 0.25s var(--vi-ease), transform 0.12s var(--vi-ease);
  white-space: nowrap;
}
.btn .arrow { font-family: var(--vi-font-display); font-size: 1.25em; line-height: 1; }
.btn:hover { background: var(--vi-accent-hover); }
.btn:active { transform: translateY(1px) scale(0.99); }
.btn--sm { padding: 11px 20px; font-size: 12px; }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px var(--vi-pad-x);
  background: rgba(14, 13, 12, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--vi-border);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand__mark {
  background: var(--vi-accent);
  padding: 6px 11px 4px 8px;
  clip-path: polygon(0 0, 100% 0, 86% 100%, 0 100%);
  display: flex;
}
.brand__mark span {
  font-family: var(--vi-font-display); font-size: 24px; line-height: 0.78;
  color: var(--vi-sand-050); transform: skewX(-8deg) scaleX(0.9);
}
.brand__name { display: flex; flex-direction: column; line-height: 1; }
.brand__name b {
  font-family: var(--vi-font-display); font-size: 19px; font-weight: 400;
  text-transform: uppercase; color: var(--vi-sand-050);
  transform: scaleX(0.92); transform-origin: left;
}
.brand__name small {
  font-family: var(--vi-font-expanded); font-weight: 800; font-size: 8px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--vi-accent);
}
.nav { display: flex; align-items: center; gap: 28px; }
.nav a {
  font-family: var(--vi-font-expanded); font-weight: 700; font-size: 12px;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--vi-sand-200);
  transition: color 0.2s var(--vi-ease);
}
.nav a:hover { color: var(--vi-sand-050); }
.header__cta { display: inline-flex; }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--vi-sand-050); margin: 5px 0; transition: 0.25s var(--vi-ease); }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: min(92vh, 960px);
  display: flex; align-items: flex-end; overflow: hidden;
}
.hero__media {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; background: var(--vi-ink-900);
  filter: saturate(0.6) contrast(1.05) brightness(0.62);
}
.hero__veil {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(14,13,12,0.55) 0%, rgba(14,13,12,0.25) 45%, rgba(14,13,12,0.96) 100%);
}
.hero__content {
  position: relative; z-index: 2;
  padding: clamp(28px, 5vw, 72px);
  padding-bottom: clamp(48px, 6vw, 88px);
  max-width: 1000px;
  /* Sin esto, el titular grande ensancha el bloque flex y la página
     se desplaza en horizontal en móviles estrechos. */
  width: 100%; min-width: 0;
}
/* El <h1> engloba el rótulo y el titular: así Google y los buscadores de IA
   leen "entrenador personal en Las Palmas" y no solo el eslogan.
   Los estilos del titular viven ahora en .hero__claim; el h1 solo agrupa. */
.hero h1 { margin: 0; font-size: inherit; font-weight: inherit; }
.hero h1 .eyebrow { display: block; }
.hero__claim {
  display: block;
  font-family: var(--vi-font-display);
  font-size: clamp(52px, 9vw, 132px);
  line-height: 0.94; text-transform: uppercase; color: var(--vi-sand-050);
  margin: 18px 0 0; text-wrap: balance;
}
.hero__claim em { color: var(--vi-accent); font-style: normal; }
.hero p {
  font-size: clamp(16px, 2vw, 21px); line-height: 1.5;
  color: var(--vi-text-muted); max-width: 560px; margin: 30px 0 30px;
}
.hero .btn { padding: 18px 32px; font-size: clamp(14px, 1.6vw, 17px); }

/* ---------- Sección genérica ---------- */
.section { padding: clamp(64px, 9vw, 140px) var(--vi-pad-x); }
.section--surface {
  background: var(--vi-surface);
  border-top: 1px solid var(--vi-border);
  border-bottom: 1px solid var(--vi-border);
}

/* ---------- Sobre ---------- */
.sobre { display: flex; flex-wrap: wrap; gap: clamp(32px, 5vw, 72px); align-items: stretch; }
.sobre__photo { flex: 1 1 340px; min-width: 300px; }
.sobre__photo img {
  width: 100%; height: 100%; min-height: 420px; object-fit: cover;
  background: var(--vi-surface); filter: saturate(0.72) contrast(1.03);
}
.sobre__text { flex: 1 1 420px; min-width: 300px; display: flex; flex-direction: column; gap: 20px; }
.sobre__text h2 {
  font-family: var(--vi-font-display); font-size: clamp(36px, 5vw, 68px);
  line-height: 1.02; text-transform: uppercase; color: var(--vi-sand-050);
}
.sobre__text p { font-size: clamp(16px, 1.6vw, 19px); line-height: 1.6; color: var(--vi-text-muted); }
.stats { display: flex; gap: 40px; margin-top: 8px; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; gap: 9px; }
.stat b { font-family: var(--vi-font-display); font-weight: 400; font-size: 52px; line-height: 0.9; color: var(--vi-accent); }
.stat small { font-family: var(--vi-font-expanded); font-weight: 800; font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--vi-text-subtle); }

/* ---------- Banda ---------- */
.band { position: relative; min-height: min(64vh, 620px); overflow: hidden; display: flex; }
.band img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 30%; filter: saturate(0.7) contrast(1.02) brightness(0.78); }
.band__veil { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(14,13,12,0.82) 0%, rgba(14,13,12,0.32) 55%, rgba(14,13,12,0.12) 100%); }
.band__content { position: relative; z-index: 2; display: flex; flex-direction: column; justify-content: center; padding: clamp(24px, 5vw, 72px); max-width: 760px; }
.band__content h2 { font-family: var(--vi-font-display); font-size: clamp(40px, 6vw, 84px); line-height: 0.98; text-transform: uppercase; color: var(--vi-sand-050); margin-top: 18px; }

/* ---------- Servicios ---------- */
.section-head { margin-bottom: 44px; }
.section-head .h2 { margin-top: 12px; }
.grid-serv { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.serv {
  background: var(--vi-ink-900); border: 1px solid var(--vi-border);
  padding: 32px 28px; display: flex; flex-direction: column; gap: 14px; min-height: 230px;
  transition: border-color 0.25s var(--vi-ease), transform 0.25s var(--vi-ease);
}
.serv:hover { border-color: var(--vi-accent); transform: translateY(-4px); }
.serv__num { font-family: var(--vi-font-display); font-size: 40px; line-height: 0.8; color: var(--vi-accent); }
.serv__title { font-family: var(--vi-font-display); font-size: 28px; line-height: 0.94; text-transform: uppercase; color: var(--vi-sand-050); }
.serv__desc { font-size: 15px; line-height: 1.5; color: var(--vi-text-subtle); }

/* ---------- Objetivos ---------- */
.objetivos { position: relative; overflow: hidden; }
.objetivos__media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: saturate(0.55) brightness(0.6); }
.objetivos__veil { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(14,13,12,0.72), rgba(14,13,12,0.64)); }
.objetivos__inner { position: relative; z-index: 2; }
.obj-list { display: flex; flex-direction: column; }
.obj {
  display: flex; align-items: center; gap: 20px; padding: 22px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  transition: padding-left 0.3s var(--vi-ease);
}
.obj:hover { padding-left: 12px; }
.obj:hover .obj__name { color: var(--vi-accent); }
.obj__n { font-family: var(--vi-font-expanded); font-weight: 800; font-size: 13px; color: var(--vi-accent); min-width: 36px; }
.obj__name { font-family: var(--vi-font-display); font-size: clamp(28px, 4vw, 52px); line-height: 0.86; text-transform: uppercase; color: var(--vi-sand-050); transition: color 0.25s var(--vi-ease); }

/* ---------- Transformaciones ---------- */
.grid-trans { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.trans { display: flex; flex-direction: column; }
.trans__pair { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.trans__pair figure { margin: 0; position: relative; aspect-ratio: 1 / 2; background: var(--vi-surface); overflow: hidden; }
.trans__pair img { width: 100%; height: 100%; object-fit: cover; }
.trans__pair .antes img { filter: saturate(0.6) sepia(0.08); }
.trans__pair .despues img { filter: saturate(0.75) sepia(0.04); }
.trans__pair figcaption {
  position: absolute; top: 10px; left: 10px;
  font-family: var(--vi-font-expanded); font-weight: 800; font-size: 10px;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--vi-sand-050);
  background: rgba(14, 13, 12, 0.7); padding: 4px 8px;
}
.trans__meta { display: flex; align-items: baseline; gap: 14px; margin-top: 16px; }
.trans__kg { font-family: var(--vi-font-display); font-size: 56px; line-height: 0.8; color: var(--vi-accent); transform: skewX(-6deg); }
.trans__name { font-family: var(--vi-font-display); font-size: 24px; text-transform: uppercase; color: var(--vi-sand-050); }
.trans__note { font-size: 15px; line-height: 1.5; color: var(--vi-text-subtle); margin-top: 6px; min-height: 45px; }

/* ---------- Testimonios ---------- */
.grid-test { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.test { background: var(--vi-ink-900); border: 1px solid var(--vi-border); padding: 32px; display: flex; flex-direction: column; gap: 18px; }
.test__quote-mark { font-family: var(--vi-font-display); font-size: 56px; line-height: 0.5; color: var(--vi-accent); }
.test blockquote { margin: 0; font-size: 17px; line-height: 1.55; color: var(--vi-text-muted); }
.test__by { display: flex; flex-direction: column; gap: 3px; margin-top: auto; }
.test__rule { width: 36px; height: 4px; background: var(--vi-accent); }
.test__name { font-family: var(--vi-font-display); font-size: 22px; text-transform: uppercase; color: var(--vi-sand-050); margin-top: 8px; }
.test__role { font-size: 14px; color: var(--vi-text-subtle); }

/* ---------- CTA final ---------- */
.cta-final { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 28px; }
.cta-final h2 { font-family: var(--vi-font-display); font-size: clamp(44px, 8vw, 110px); line-height: 1.06; text-transform: uppercase; color: var(--vi-sand-050); max-width: 900px; text-wrap: balance; }
.cta-final .btn { padding: 20px 40px; font-size: clamp(15px, 1.8vw, 18px); }

/* ---------- Footer ---------- */
.footer { padding: 40px var(--vi-pad-x); border-top: 1px solid var(--vi-border); display: flex; flex-wrap: wrap; gap: 20px; align-items: center; justify-content: space-between; }
.footer__name { font-family: var(--vi-font-display); font-size: 22px; text-transform: uppercase; color: var(--vi-sand-050); }
.footer__links { display: flex; gap: 24px; align-items: center; }
.footer__links a { font-family: var(--vi-font-expanded); font-weight: 800; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--vi-text-subtle); transition: color 0.2s var(--vi-ease); }
.footer__links a:hover { color: var(--vi-accent); }

/* ---------- Botón flotante ---------- */
.fab {
  position: fixed; bottom: 22px; right: 22px; z-index: 80;
  width: 60px; height: 60px; border-radius: 50%; background: var(--vi-accent);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  animation: vi-pulse 2.6s ease-in-out infinite;
  transition: background 0.25s var(--vi-ease);
}
.fab:hover { background: var(--vi-accent-hover); }
.fab svg { width: 28px; height: 28px; fill: var(--vi-sand-050); }
@keyframes vi-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.06); } }

/* ---------- Reveal en scroll ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s var(--vi-ease), transform 0.7s var(--vi-ease); }
.reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .header__cta { display: none; }
  .nav-toggle { display: block; }
  .nav {
    position: fixed; inset: 0 0 auto 0; top: 61px; flex-direction: column; gap: 0;
    background: rgba(14, 13, 12, 0.97); backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--vi-border); padding: 8px 0;
    transform: translateY(-120%); transition: transform 0.3s var(--vi-ease);
  }
  .nav.open { transform: none; }
  .nav a { width: 100%; padding: 16px var(--vi-pad-x); font-size: 14px; border-top: 1px solid var(--vi-border); }
  .nav .nav__cta { color: var(--vi-accent); }
}

/* ---------- Responsive: móvil estrecho ---------- */
@media (max-width: 520px) {
  /* El botón del hero no cabía a ancho completo y sacaba scroll lateral */
  .hero .btn, .cta-final .btn { padding: 16px 22px; font-size: 14px; max-width: 100%; }
  /* El botón flotante de Instagram tapaba el botón del hero */
  .hero__content { padding-bottom: 104px; }
  /* Titulares un punto más contenidos para que no se coman la pantalla */
  .hero__claim { font-size: clamp(40px, 12vw, 56px); }
  .band__content h2 { font-size: clamp(32px, 10vw, 48px); }
  /* Antes/después: las dos fotos siguen una al lado de otra, pero más juntas */
  .trans__pair { gap: 3px; }
  .stat b { font-size: 44px; }
}

/* ---------- Accesibilidad: movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .fab { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  * { transition-duration: 0.01ms !important; }
}
