/* =========================================================
   Martínez Gervilla & Asociados — Estudio Jurídico
   ========================================================= */

:root {
  --navy-950: #080e19;
  --navy-900: #0e1829;
  --navy-850: #111d31;
  --navy-800: #16243c;
  --navy-700: #1f3150;

  --gold: #b98f5f;
  --gold-light: #d8b584;
  --gold-dark: #8f6b43;
  --gold-grad: linear-gradient(120deg, #9e784e 0%, #cfa872 45%, #f0d7ab 55%, #b98f5f 100%);

  --ivory: #f1f1f0;
  --ivory-70: rgba(241, 241, 240, .7);
  --ivory-50: rgba(241, 241, 240, .5);
  --ivory-12: rgba(241, 241, 240, .12);
  --gold-25: rgba(185, 143, 95, .25);

  --font-serif: "garamond-premier-pro-display", "Cormorant Garamond", "Times New Roman", serif;
  --font-sans: "proxima-nova", "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;

  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-in-out: cubic-bezier(.77, 0, .175, 1);

  --header-h: 96px;
  --marquee-h: 64px;
  --gutter: clamp(20px, 4vw, 64px);
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  margin: 0;
  background: var(--navy-900);
  color: var(--ivory);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
body.is-loading { overflow: hidden; }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }

::selection { background: var(--gold); color: var(--navy-900); }

:focus-visible { outline: 1px solid var(--gold-light); outline-offset: 4px; }

.container {
  width: 100%;
  max-width: 1440px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Grano de película sutil */
.grain {
  position: fixed;
  inset: -50%;
  z-index: 90;
  pointer-events: none;
  opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1.2s steps(6) infinite;
}
@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -3%); }
  60% { transform: translate(-2%, -1%); }
  80% { transform: translate(3%, 3%); }
}

/* =========================================================
   PRELOADER
   ========================================================= */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  color: var(--ivory);
}
.no-js .preloader { display: none; }

.preloader__panel {
  position: absolute;
  left: 0;
  right: 0;
  height: 50.5%;
  background:
    radial-gradient(ellipse 60% 70% at 50% 100%, rgba(185, 143, 95, .08), transparent 70%),
    var(--navy-950);
  will-change: transform;
}
.preloader__panel--top { top: 0; }
.preloader__panel--bottom {
  bottom: 0;
  background:
    radial-gradient(ellipse 60% 70% at 50% 0%, rgba(185, 143, 95, .08), transparent 70%),
    var(--navy-950);
}

.preloader__stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(28px, 4vh, 44px);
}

.preloader__emblem {
  position: relative;
  width: clamp(170px, 22vw, 230px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
}

.preloader__ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
  overflow: visible;
}
.preloader__ring circle { fill: none; }
.preloader__ring-track { stroke: rgba(185, 143, 95, .12); stroke-width: .6; }
.preloader__ring-line {
  stroke: var(--gold);
  stroke-width: 1;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  filter: drop-shadow(0 0 6px rgba(216, 181, 132, .55));
}

.preloader__mono {
  position: relative;
  width: 58%;
  aspect-ratio: 345 / 330;
  clip-path: inset(100% 0 0 0);
}
.preloader__mono img { width: 100%; height: 100%; }

/* Brillo que recorre las letras, recortado con la forma exacta del monograma */
.preloader__shine {
  position: absolute;
  inset: 0;
  -webkit-mask: url("../img/logo-mg-mask.svg") center / 100% 100% no-repeat;
          mask: url("../img/logo-mg-mask.svg") center / 100% 100% no-repeat;
  background: linear-gradient(105deg,
    transparent 38%,
    rgba(255, 238, 205, .0) 42%,
    rgba(255, 238, 205, .95) 50%,
    rgba(255, 238, 205, .0) 58%,
    transparent 62%);
  background-size: 260% 100%;
  background-position: 130% 0;
  mix-blend-mode: screen;
}

.preloader__word {
  width: clamp(240px, 30vw, 400px);
  clip-path: inset(0 50% 0 50%);
}
.preloader__word img { width: 100%; height: auto; }

.preloader__meta {
  position: absolute;
  left: var(--gutter);
  right: var(--gutter);
  bottom: clamp(28px, 5vh, 48px);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  font-size: 11px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--ivory-50);
}
.preloader__count {
  font-family: var(--font-serif);
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1;
  letter-spacing: .02em;
  color: var(--gold-light);
  font-variant-numeric: tabular-nums;
  overflow: hidden;
}

.preloader__progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: rgba(185, 143, 95, .12);
}
.preloader__progress span {
  display: block;
  height: 100%;
  width: 100%;
  background: var(--gold-grad);
  transform: scaleX(0);
  transform-origin: left;
}

/* Línea de corte al salir */
.preloader::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-light), transparent);
  transform: scaleX(var(--cut, 0));
  opacity: var(--cut-o, 1);
  box-shadow: 0 0 18px rgba(216, 181, 132, .7);
}

/* =========================================================
   BOTONES
   ========================================================= */
.btn {
  --btn-h: 56px;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  height: var(--btn-h);
  padding: 0 28px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  border-radius: 999px;
  overflow: hidden;
  isolation: isolate;
  white-space: nowrap;
  transition: color .6s var(--ease-out), border-color .6s var(--ease-out);
}
.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  transform: translateY(101%);
  transition: transform .7s var(--ease-out);
}
.btn:hover::before { transform: translateY(0); }

.btn__icon {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  transition: transform .6s var(--ease-out);
}
.btn:hover .btn__icon { transform: translateX(4px); }

.btn--gold {
  color: var(--navy-900);
  background: var(--gold-grad);
  background-size: 200% 100%;
  box-shadow: 0 18px 40px -18px rgba(185, 143, 95, .6);
}
.btn--gold::before { background: var(--ivory); }

.btn--outline {
  color: var(--ivory);
  border: 1px solid rgba(185, 143, 95, .55);
}
.btn--outline::before { background: var(--gold-grad); }
.btn--outline:hover { color: var(--navy-900); border-color: transparent; }

.btn--sm { --btn-h: 46px; padding: 0 22px; font-size: 11px; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ivory-70);
  transition: color .4s;
}
.link-arrow__circle {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border: 1px solid var(--ivory-12);
  border-radius: 50%;
  transition: border-color .5s, background-color .5s;
}
.link-arrow__circle svg {
  width: 16px;
  fill: none;
  stroke: var(--gold-light);
  stroke-width: 1.5;
  transition: transform .6s var(--ease-out);
}
.link-arrow:hover { color: var(--ivory); }
.link-arrow:hover .link-arrow__circle { border-color: var(--gold); background: rgba(185, 143, 95, .08); }
.link-arrow:hover .link-arrow__circle svg { transform: translateY(3px); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  margin: 0;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--gold-light);
}
.eyebrow__line {
  width: 48px;
  height: 1px;
  background: var(--gold);
}

/* =========================================================
   HEADER
   ========================================================= */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  transition: transform .8s var(--ease-out);
}
.header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(10, 17, 30, .72);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
          backdrop-filter: blur(18px) saturate(140%);
  opacity: 0;
  transition: opacity .6s var(--ease-out);
}
.header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(185, 143, 95, .45), transparent);
  transform: scaleX(0);
  transition: transform 1s var(--ease-out);
}
.header.is-scrolled::before { opacity: 1; }
.header.is-scrolled::after { transform: scaleX(1); }
.header.is-hidden { transform: translateY(-100%); }

.header__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  height: var(--header-h);
  transition: height .6s var(--ease-out);
}
.header.is-scrolled .header__inner { height: 76px; }

.header__brand img {
  height: 58px;
  width: auto;
  transition: height .6s var(--ease-out);
}
.header.is-scrolled .header__brand img { height: 48px; }

.nav__list {
  display: flex;
  align-items: center;
  gap: clamp(20px, 2.6vw, 44px);
}
.nav__link {
  position: relative;
  display: block;
  padding: 10px 0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ivory-70);
  transition: color .4s;
}
/* Efecto de texto que rueda: el span reserva el ancho, los pseudo-elementos ruedan */
.nav__link span {
  position: relative;
  display: block;
  overflow: hidden;
  line-height: 1.4;
  color: transparent;
}
.nav__link span::before,
.nav__link span::after {
  content: attr(data-text);
  position: absolute;
  left: 0;
  transition: transform .7s var(--ease-out), color .4s;
}
.nav__link span::before { top: 0; color: var(--ivory-70); }
.nav__link span::after { top: 100%; color: var(--gold-light); }
.nav__link:hover span::before,
.nav__link:hover span::after { transform: translateY(-100%); }
.nav__link.is-active span::before { color: var(--ivory); }

.nav__link::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 2px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--gold);
  transform: translate(-50%, 6px) scale(0);
  transition: transform .5s var(--ease-out);
}
.nav__link.is-active::after { transform: translate(-50%, 6px) scale(1); }

.header__actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

.burger {
  display: none;
  position: relative;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(185, 143, 95, .45);
  border-radius: 50%;
  z-index: 2;
}
.burger span {
  position: absolute;
  left: 15px;
  right: 15px;
  height: 1px;
  background: var(--ivory);
  transition: transform .6s var(--ease-out), top .6s var(--ease-out), width .6s var(--ease-out);
}
.burger span:nth-child(1) { top: 19px; }
.burger span:nth-child(2) { top: 27px; right: 21px; }
.burger:hover span:nth-child(2) { right: 15px; }
.menu-open .burger span:nth-child(1) { top: 23px; transform: rotate(45deg); }
.menu-open .burger span:nth-child(2) { top: 23px; right: 15px; transform: rotate(-45deg); }

/* Menú móvil */
.mmenu {
  position: fixed;
  inset: 0;
  z-index: 99;
  visibility: hidden;
  pointer-events: none;
}
.mmenu__bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 100% 0%, rgba(185, 143, 95, .14), transparent 60%),
    var(--navy-950);
  clip-path: circle(0% at calc(100% - var(--gutter) - 24px) 48px);
  transition: clip-path 1s var(--ease-in-out);
}
.menu-open .mmenu { visibility: visible; pointer-events: auto; }
.menu-open .mmenu__bg { clip-path: circle(150% at calc(100% - var(--gutter) - 24px) 48px); }

.mmenu__inner {
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: calc(var(--header-h) + 5vh);
  padding-bottom: 40px;
}
.mmenu__list li { overflow: hidden; border-bottom: 1px solid var(--ivory-12); }
.mmenu__list a {
  display: flex;
  align-items: baseline;
  gap: 18px;
  padding: 14px 0;
  font-family: var(--font-serif);
  font-size: clamp(34px, 9vw, 56px);
  line-height: 1.1;
  font-weight: 400;
  transform: translateY(110%);
  transition: transform .9s var(--ease-out), color .4s;
}
.mmenu__list em {
  font-family: var(--font-sans);
  font-style: normal;
  font-size: 11px;
  letter-spacing: .2em;
  color: var(--gold);
}
.mmenu__list a:hover { color: var(--gold-light); }
.menu-open .mmenu__list a { transform: translateY(0); }
.menu-open .mmenu__list li:nth-child(1) a { transition-delay: .35s; }
.menu-open .mmenu__list li:nth-child(2) a { transition-delay: .42s; }
.menu-open .mmenu__list li:nth-child(3) a { transition-delay: .49s; }
.menu-open .mmenu__list li:nth-child(4) a { transition-delay: .56s; }
.menu-open .mmenu__list li:nth-child(5) a { transition-delay: .63s; }

.mmenu__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .6s, transform .8s var(--ease-out);
}
.mmenu__foot p {
  margin: 0;
  font-size: 11px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--ivory-50);
}
.menu-open .mmenu__foot { opacity: 1; transform: none; transition-delay: .7s; }

/* =========================================================
   HERO
   ========================================================= */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--navy-900);
}

.hero__bg { position: absolute; inset: 0; pointer-events: none; }

.hero__glow {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 50% 60% at 74% 45%, rgba(185, 143, 95, .09), transparent 72%),
    radial-gradient(ellipse 60% 60% at 0% 100%, rgba(31, 49, 80, .8), transparent 70%),
    linear-gradient(180deg, var(--navy-950) 0%, var(--navy-900) 40%, var(--navy-850) 100%);
}
.hero__glow::after {
  /* spotlight que sigue al mouse */
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(520px circle at var(--mx, 70%) var(--my, 40%), rgba(216, 181, 132, .045), transparent 60%);
}

.hero__lines {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  max-width: 1440px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.hero__lines i {
  border-left: 1px solid rgba(241, 241, 240, .035);
  transform-origin: top;
}
.hero__lines i:last-child { border-right: 1px solid rgba(241, 241, 240, .035); }

.hero__watermark {
  position: absolute;
  left: -6vw;
  bottom: -12vh;
  width: min(62vw, 820px);
  aspect-ratio: 345 / 330;
  -webkit-mask: url("../img/logo-mg-mask.svg") center / contain no-repeat;
          mask: url("../img/logo-mg-mask.svg") center / contain no-repeat;
  background: linear-gradient(160deg, rgba(185, 143, 95, .045), rgba(241, 241, 240, .01));
}

.hero__inner {
  position: relative;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr);
  align-items: center;
  gap: clamp(40px, 6vw, 110px);
  padding-top: calc(var(--header-h) + clamp(16px, 3vh, 40px));
  padding-bottom: clamp(24px, 4vh, 48px);
}

.hero__content { max-width: 780px; }

.hero__title {
  margin: clamp(16px, 2.6vh, 28px) 0 0;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(36px, min(4.6vw, 8svh), 84px);
  line-height: 1.02;
  letter-spacing: .005em;
  text-transform: uppercase;
  color: var(--ivory);
}
.hero__title strong {
  font-weight: 600;
  background: var(--gold-grad);
  background-size: 200% 100%;
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
  animation: goldShift 6s ease-in-out infinite alternate;
}
@keyframes goldShift {
  from { background-position: 0% 0; }
  to { background-position: 100% 0; }
}

/* palabras divididas por JS */
.word { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .12em; margin-bottom: -.12em; }
.word__inner { display: inline-block; will-change: transform; }

.hero__lead {
  max-width: 520px;
  margin: clamp(18px, 3vh, 30px) 0 0;
  font-size: clamp(15px, 1.15vw, 17px);
  font-weight: 300;
  line-height: 1.75;
  color: var(--ivory-70);
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px 34px;
  margin-top: clamp(24px, 4.2vh, 42px);
}

.hero__pillars {
  display: flex;
  flex-wrap: wrap;
  margin-top: clamp(24px, 5vh, 60px);
  border-top: 1px solid var(--ivory-12);
}
.hero__pillars li {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 28px 0 0;
  margin-right: 28px;
  font-size: 12px;
  line-height: 1.45;
  letter-spacing: .04em;
  color: var(--ivory-70);
}
.hero__pillars li + li { padding-left: 28px; border-left: 1px solid var(--ivory-12); margin-top: 22px; padding-top: 0; }
.hero__pillars svg {
  flex: none;
  width: 26px;
  height: 26px;
  fill: none;
  stroke: var(--gold);
  stroke-width: 1.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Imagen */
.hero__visual {
  position: relative;
  justify-self: end;
  width: 100%;
  /* En desktop la foto entra completa en la primera pantalla: alto = ancho × 1.325 */
  max-width: min(500px, calc((100vh - var(--header-h) - 96px) / 1.325));
  max-width: min(500px, calc((100svh - var(--header-h) - 96px) / 1.325));
}
.hero__figure {
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 5.3;
  border-radius: 999px 999px 6px 6px;
  overflow: hidden;
  background: var(--navy-800);
  box-shadow: 0 60px 120px -40px rgba(0, 0, 0, .7);
}
.hero__figure picture,
.hero__figure img {
  width: 100%;
  height: 100%;
}
.hero__figure img {
  object-fit: cover;
  object-position: 50% 45%;
  filter: saturate(.6) contrast(1.05) brightness(.9);
  transform-origin: 50% 30%;
  will-change: transform;
}
.hero__figure::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(14, 24, 41, 0) 55%, rgba(14, 24, 41, .85) 100%),
    linear-gradient(90deg, rgba(14, 24, 41, .25), transparent 30%);
  pointer-events: none;
}

.hero__frame-outline {
  position: absolute;
  inset: 0;
  aspect-ratio: 4 / 5.3;
  border: 1px solid rgba(185, 143, 95, .45);
  border-radius: 999px 999px 6px 6px;
  transform: translate(22px, -22px);
}

.badge {
  position: absolute;
  top: 12%;
  right: -56px;
  width: 132px;
  height: 132px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(10, 17, 30, .6);
  -webkit-backdrop-filter: blur(12px);
          backdrop-filter: blur(12px);
  border: 1px solid rgba(185, 143, 95, .3);
  z-index: 2;
  transition: transform .6s var(--ease-out), border-color .4s;
}
.badge:hover { border-color: var(--gold); }
.badge__text {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: spin 22s linear infinite;
}
.badge__text text {
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  fill: var(--ivory-70);
}
.badge__core {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: 1px solid rgba(185, 143, 95, .25);
  transition: transform .8s var(--ease-out);
}
.badge__core img { width: 32px; height: auto; }
.badge:hover .badge__core { transform: scale(1.1) rotate(-8deg); }
@keyframes spin { to { transform: rotate(360deg); } }

.hero__card {
  position: absolute;
  left: -128px;
  top: 48%;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 18px 24px 18px 22px;
  background: rgba(14, 24, 41, .68);
  -webkit-backdrop-filter: blur(16px) saturate(130%);
          backdrop-filter: blur(16px) saturate(130%);
  border: 1px solid var(--ivory-12);
  border-left: 2px solid var(--gold);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .8);
}
.hero__card-kicker {
  font-size: 10px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--gold-light);
}
.hero__card strong {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 500;
  line-height: 1.15;
}
.hero__card-role {
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--ivory-50);
}

.marquee {
  position: relative;
  flex: none;
  display: flex;
  align-items: center;
  height: var(--marquee-h);
  z-index: 2;
  border-top: 1px solid var(--ivory-12);
  overflow: hidden;
  background: rgba(8, 14, 25, .85);
  -webkit-mask: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
          mask: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.marquee__track {
  display: flex;
  align-items: center;
  gap: 42px;
  width: max-content;
  animation: marquee 38s linear infinite;
}
.marquee__track span {
  font-family: var(--font-serif);
  font-size: clamp(20px, 2vw, 28px);
  font-style: italic;
  font-weight: 300;
  color: var(--ivory-70);
  white-space: nowrap;
}
.marquee__track i {
  font-style: normal;
  font-size: 12px;
  color: var(--gold);
}
@keyframes marquee { to { transform: translateX(-50%); } }

.placeholder { min-height: 60vh; background: var(--navy-950); }

/* Estados iniciales cuando JS está activo (evita flash antes del preloader) */
.js [data-hero="fade"] { opacity: 0; }
.js .hero__figure { clip-path: inset(100% 0 0 0 round 999px 999px 0 0); }
.js .hero__frame-outline,
.js .badge,
.js .hero__card { opacity: 0; }
.js .header { opacity: 0; }

/* =========================================================
   RESPONSIVE
   ========================================================= */
/* Desktop: el hero completo (con la franja) entra en una pantalla.
   La foto llega hasta el borde inferior y la franja de palabras pasa por encima de su base. */
@media (min-width: 961px) and (min-height: 560px) {
  .hero { height: 100vh; height: 100svh; }
  .hero__inner {
    min-height: 0;
    align-items: stretch;
    padding-top: calc(var(--header-h) + 14px);
    padding-bottom: 0;
  }
  .hero__content { align-self: center; padding-bottom: 14px; }
  .hero__visual {
    align-self: end;
    margin-bottom: calc(var(--marquee-h) * -1);
    max-width: min(600px, calc((100vh - var(--header-h) - 14px) / 1.3));
    max-width: min(600px, calc((100svh - var(--header-h) - 14px) / 1.3));
  }
  .hero__figure,
  .hero__frame-outline { aspect-ratio: 1 / 1.3; border-radius: 999px 999px 0 0; }
  /* encuadre: cabeza completa arriba y manos apoyadas en la mesa por encima de la franja */
  .hero__figure img { object-position: 50% 62%; }
  .hero__frame-outline { transform: translate(18px, -14px); }
  .hero__pillars { margin-top: clamp(20px, 4vh, 48px); }
  .marquee {
    background: rgba(8, 14, 25, .62);
    -webkit-backdrop-filter: blur(14px);
            backdrop-filter: blur(14px);
  }
}

/* Pantallas bajas (notebooks, Windows con escala 125%) */
@media (min-width: 961px) and (max-height: 780px) {
  :root { --header-h: 80px; --marquee-h: 56px; }
  .header__brand img { height: 50px; }
  .header.is-scrolled .header__inner { height: 68px; }
  .header.is-scrolled .header__brand img { height: 42px; }
  .hero__lead { line-height: 1.65; }
  .hero__cta .btn { --btn-h: 52px; }
  .link-arrow__circle { width: 52px; height: 52px; }
  .hero__pillars li { padding-top: 16px; }
  .hero__pillars li + li { margin-top: 16px; }
}

@media (max-width: 1180px) {
  .nav { display: none; }
  .burger { display: block; }
}

@media (max-width: 960px) {
  :root { --header-h: 84px; }

  .hero__inner {
    grid-template-columns: 1fr;
    gap: 64px;
    padding-top: calc(var(--header-h) + 36px);
  }
  .hero__content { max-width: none; }
  .hero__card { left: -48px; }
  .hero__visual {
    justify-self: center;
    max-width: 440px;
    margin-inline: auto;
  }
  .hero__watermark { width: 110vw; left: -20vw; bottom: auto; top: 10vh; }
  .hero__lines { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .header__brand img { height: 46px; }
  .header.is-scrolled .header__brand img { height: 40px; }
  .header__actions .btn { display: none; }
  .header.is-scrolled .header__inner { height: 68px; }

  .hero__title { font-size: clamp(30px, 9.2vw, 44px); }
  .hero__eyebrow { gap: 12px; font-size: 10px; letter-spacing: .22em; }
  .hero__eyebrow .eyebrow__line { width: 24px; }
  .hero__cta { gap: 22px; }
  .hero__cta .btn { width: 100%; justify-content: space-between; }

  .hero__pillars { display: grid; grid-template-columns: 1fr; }
  .hero__pillars li,
  .hero__pillars li + li { padding: 16px 0; margin: 0; border-left: 0; border-bottom: 1px solid var(--ivory-12); }

  .hero__visual { max-width: calc(100% - 28px); margin-left: 0; }
  .hero__frame-outline { transform: translate(14px, -14px); }
  .badge { width: 104px; height: 104px; right: -14px; top: 8%; }
  .badge__core { width: 46px; height: 46px; }
  .badge__core img { width: 26px; }
  .hero__card { position: relative; left: auto; top: auto; margin: -26px 0 0 14px; width: fit-content; padding: 16px 20px; }
  .hero__card strong { font-size: 19px; }

  .preloader__label { max-width: 150px; line-height: 1.8; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}
