/* ==========================================================================
   Amani Bordón · Portafolio
   ========================================================================== */

:root {
  --ink: #0E0E10;
  --paper: #F4F3EF;
  --graphite: #26262B;

  --gutter: clamp(1.1rem, 4vw, 3.5rem);
  --radius: 14px;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);

  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;

  /* tema por defecto */
  --bg: var(--ink);
  --fg: var(--paper);
  --muted: #A2A2AA;
  --line: rgba(244, 243, 239, 0.14);
  --accent: var(--paper);
  --accent-fg: var(--ink);
}

/* Identidad sobria (tinta y papel). Cada marca aporta un tono claro y su color propio en el nombre. */
[data-theme="ink"]        { --bg: #0E0E10; --fg: #F4F3EF; --muted: #A2A2AA; --line: rgba(244,243,239,.14); --accent: #F4F3EF; --accent-fg: #0E0E10; }
[data-theme="paper"]      { --bg: #F4F3EF; --fg: #111113; --muted: #5C5C63; --line: rgba(17,17,19,.14);    --accent: #111113; --accent-fg: #F4F3EF; }
[data-theme="cafexpress"] { --bg: #F5E8E4; --fg: #2E0D0A; --muted: #6E3A33; --line: rgba(46,13,10,.15);    --accent: #B4271B; --accent-fg: #FFFFFF; }
[data-theme="xpecialty"]  { --bg: #E8E8E5; --fg: #141416; --muted: #55555A; --line: rgba(20,20,22,.15);    --accent: #141416; --accent-fg: #E8E8E5; }
[data-theme="dammann"]    { --bg: #F3E9DE; --fg: #3B0F18; --muted: #6F4A3E; --line: rgba(59,15,24,.15);    --accent: #6B1A2B; --accent-fg: #F3E9DE; }
[data-theme="aquax"]      { --bg: #E5EEF6; --fg: #0B2741; --muted: #3E5A75; --line: rgba(11,39,65,.15);    --accent: #0A5BA3; --accent-fg: #FFFFFF; }
[data-theme="rolki"]      { --bg: #E0EFEB; --fg: #0C322D; --muted: #3B605A; --line: rgba(12,50,45,.15);    --accent: #127E71; --accent-fg: #FFFFFF; }
[data-theme="giuliano"]   { --bg: #EDF1DF; --fg: #1C240F; --muted: #4C5734; --line: rgba(28,36,15,.15);    --accent: #56700E; --accent-fg: #FFFFFF; }
[data-theme="laura"]      { --bg: #EAEDE5; --fg: #232A1F; --muted: #535C4D; --line: rgba(35,42,31,.15);    --accent: #56684B; --accent-fg: #FFFFFF; }
[data-theme="quincho"]    { --bg: #F4EBE2; --fg: #2E1C12; --muted: #6B4E3D; --line: rgba(46,28,18,.15);    --accent: #A04E1E; --accent-fg: #FFFFFF; }
[data-theme="megastock"]  { --bg: #ECEAF6; --fg: #1A1530; --muted: #4E4866; --line: rgba(26,21,48,.15);    --accent: #5A3FD0; --accent-fg: #FFFFFF; }

/* Con JS activo, el body lleva el tema y las secciones heredan: el color cambia en una sola transicion */
.anim main [data-theme] {
  --bg: inherit; --fg: inherit; --muted: inherit; --line: inherit; --accent: inherit; --accent-fg: inherit;
  background: transparent;
}

/* ==========================================================================
   Base
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scrollbar-color: #8A8A92 transparent;
  scrollbar-width: thin;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.55;
  background: var(--bg);
  color: var(--fg);
  font-kerning: normal;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background-color 700ms var(--ease-in-out), color 700ms var(--ease-in-out);
}

main [data-theme] { background: var(--bg); color: var(--fg); }

img, video, canvas { display: block; max-width: 100%; }
[hidden] { display: none !important; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
h1, h2, h3, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }

::selection { background: var(--fg); color: var(--bg); }

:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
  border-radius: 4px;
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: fixed; left: 1rem; top: 1rem; z-index: 200;
  padding: .7rem 1rem; border-radius: 999px;
  background: var(--paper); color: var(--ink);
  transform: translateY(-160%);
  transition: transform 200ms var(--ease-out);
}
.skip:focus { transform: none; }

/* ==========================================================================
   Botones
   ========================================================================== */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 1.4rem;
  border-radius: 999px;
  font-weight: 600; font-size: .98rem; letter-spacing: -0.005em;
  text-decoration: none;
  transition: transform 160ms var(--ease-out), background-color 200ms ease, color 200ms ease, border-color 200ms ease;
  -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: scale(0.97); }
.btn--solid { background: var(--fg); color: var(--bg); }
.btn--line  { border: 1px solid currentColor; }
.btn--big   { min-height: 58px; padding: 0 1.8rem; font-size: 1.05rem; }

@media (hover: hover) and (pointer: fine) {
  .btn--solid:hover { background: var(--muted); }
  .btn--line:hover  { background: var(--fg); color: var(--bg); border-color: var(--fg); }
}

/* ==========================================================================
   Navegación
   ========================================================================== */

.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; gap: 2rem;
  padding: 1.1rem var(--gutter);
  color: var(--fg);
  pointer-events: none;
  transition: color 700ms var(--ease-in-out), transform 400ms var(--ease-out);
}
.nav > * { pointer-events: auto; }
.nav::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--bg);
  box-shadow: 0 1px 0 var(--line);
  opacity: 0;
  transition: opacity 300ms ease, background-color 700ms var(--ease-in-out);
}
.nav.is-solid::before { opacity: 1; }
.nav.is-hidden { transform: translateY(-110%); }

.nav__brand {
  font-weight: 750; font-stretch: 102%; letter-spacing: -0.02em;
  text-decoration: none; font-size: 1.05rem;
}
.nav__links { display: flex; gap: 1.6rem; margin-left: auto; font-size: .95rem; }
.nav__links a { text-decoration: none; position: relative; }
.nav__links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -3px; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform 260ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }
}
.nav__cta {
  text-decoration: none; font-weight: 600; font-size: .95rem;
  padding: .55rem 1.1rem; border-radius: 999px; border: 1px solid currentColor;
  transition: transform 160ms var(--ease-out), background-color 200ms ease, color 200ms ease;
}
.nav__cta:active { transform: scale(0.97); }
@media (hover: hover) and (pointer: fine) {
  .nav__cta:hover { background: var(--fg); color: var(--bg); }
}

.nav__pause {
  display: inline-grid; place-items: center;
  width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid currentColor;
  transition: transform 160ms var(--ease-out), background-color 200ms ease, color 200ms ease;
}
.nav__pause svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.nav__pause .ic-play { display: none; }
.nav__pause[aria-pressed="true"] .ic-play { display: inline; fill: currentColor; }
.nav__pause[aria-pressed="true"] .ic-pause { display: none; }
.nav__pause:active { transform: scale(0.94); }
@media (hover: hover) and (pointer: fine) {
  .nav__pause:hover { background: var(--fg); color: var(--bg); }
}

@media (max-width: 860px) {
  .nav__links { display: none; }
  .nav__pause { margin-left: auto; }
}

/* ==========================================================================
   Hero: el nombre hecho de reels
   Sin animación (o si el script falla) es una portada estática y legible;
   con .hero-anim se convierte en la secuencia del muro de reels.
   ========================================================================== */

.hero { position: relative; background: var(--ink); color: var(--paper); }

.hero__stage {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  gap: clamp(1.8rem, 5vh, 3.5rem);
  padding: 7rem var(--gutter) clamp(1.8rem, 6vh, 3.5rem);
  overflow: hidden;
  background: var(--ink);
}

.hero__title {
  font-size: clamp(3.6rem, 16vw, 13.5rem); font-weight: 800; font-stretch: 104%;
  line-height: .84; letter-spacing: -0.045em;
}
.hero__title span { display: block; }

.hero__intro {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 1.4rem 2rem;
}
.hero__lead { display: none; font-weight: 700; font-size: clamp(1.15rem, 1.5vw, 1.45rem); letter-spacing: -0.015em; margin-bottom: .35rem; }
.hero__role {
  font-size: clamp(1rem, 1.25vw, 1.15rem); line-height: 1.45; max-width: 38ch;
  color: #C4C4CB;
}
.hero__actions { display: flex; gap: .7rem; flex-wrap: wrap; justify-content: flex-end; }
.hero__actions .btn--solid { background: var(--paper); color: var(--ink); }
.hero__actions .btn--line { color: var(--paper); }
@media (hover: hover) and (pointer: fine) {
  .hero__actions .btn--solid:hover { background: #fff; }
  .hero__actions .btn--line:hover { background: var(--paper); color: var(--ink); }
}
.hero__hint { display: none; }

.statement { display: grid; gap: .2rem; padding-top: clamp(1.5rem, 4vh, 2.5rem); border-top: 1px solid rgba(244, 243, 239, .14); }
.statement__line { overflow: hidden; line-height: 1.05; padding: .04em 0; }
.statement__inner { display: inline-block; font-size: clamp(1.05rem, 2vw, 1.9rem); font-weight: 500; letter-spacing: -0.015em; color: #D9D9DE; }
.statement__line--big .statement__inner {
  font-size: clamp(2.2rem, 7vw, 6rem); font-weight: 800; font-stretch: 106%;
  letter-spacing: -0.035em; line-height: .95; color: var(--paper);
}
.num { font-variant-numeric: tabular-nums; }

.wall, .hero__mask, .hero__scrim { display: none; }

/* ---------- con animación ---------- */
.hero-anim .hero { height: 290vh; height: 290svh; }
.hero-anim .hero__stage {
  position: sticky; top: 0;
  display: block;
  height: 100vh; height: 100svh; min-height: 0;
  padding: 0;
}
.hero-anim .hero__title {
  position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.hero-anim .hero__lead { display: block; }
.hero-anim .hero__intro {
  position: absolute; left: var(--gutter); right: var(--gutter); bottom: clamp(1.4rem, 5vh, 3.2rem);
}
.hero-anim .hero__hint {
  grid-column: 1 / -1;
  display: flex; align-items: center; gap: .75rem;
  font-size: .82rem; letter-spacing: .02em; color: #A2A2AA;
}
.hero__hint-line { width: 44px; height: 1px; background: currentColor; transform-origin: left; animation: hint 2.4s var(--ease-in-out) infinite; }
@keyframes hint { 0% { transform: scaleX(0); } 50% { transform: scaleX(1); transform-origin: left; } 51% { transform-origin: right; } 100% { transform: scaleX(0); transform-origin: right; } }

.hero-anim .statement {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  padding: 0 var(--gutter); border: 0;
  text-align: center; pointer-events: none;
}
.hero-anim .statement__inner { transform: translateY(110%); }
.hero-anim .statement__line--big .statement__inner { font-size: clamp(3rem, 10vw, 10.5rem); }

/* muro de reels */
.hero-anim .wall {
  position: absolute; inset: -4vh -2vw;
  display: grid;
  grid-template-columns: repeat(var(--cols, 5), minmax(0, 1fr));
  gap: clamp(6px, 0.8vw, 12px);
  background: var(--graphite);
}
.wall__col { position: relative; overflow: hidden; }
.wall__tile {
  position: absolute; left: 0; right: 0; top: 0;
  will-change: transform;
  contain: layout paint;
  aspect-ratio: 9 / 16;
  border-radius: clamp(6px, 0.8vw, 12px); overflow: hidden;
  background: #1d1d22;
}
.wall__tile video, .wall__tile img { width: 100%; height: 100%; object-fit: cover; }

/* capa con las letras recortadas */
.hero-anim .hero__mask {
  display: block;
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  transform-origin: 50% 50%;
  will-change: transform;
}
.hero-anim .hero__scrim {
  display: block;
  position: absolute; inset: 0;
  background: rgba(10, 10, 12, 0.74);
  opacity: 0;
}

/* entrada inicial */
.hero-anim .hero__intro > * { opacity: 0; transform: translateY(14px); }
.hero-anim.is-ready .hero__intro > * {
  opacity: 1; transform: none;
  transition: opacity 700ms var(--ease-out), transform 700ms var(--ease-out);
}
.hero-anim.is-ready .hero__intro > :nth-child(2) { transition-delay: 380ms; }
.hero-anim.is-ready .hero__intro > :nth-child(3) { transition-delay: 460ms; }
.hero-anim.is-ready .hero__intro > :nth-child(4) { transition-delay: 620ms; }

@media (max-width: 760px) {
  .hero-anim .hero { height: 230vh; height: 230svh; }
  .hero__intro { grid-template-columns: 1fr; }
  .hero__actions { justify-content: flex-start; }
  .hero__actions .btn { flex: 1 1 0; }
}

/* ==========================================================================
   Índice de marcas
   ========================================================================== */

.index { position: relative; padding: clamp(6rem, 16vh, 11rem) var(--gutter) clamp(5rem, 12vh, 9rem); }
.index__head { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 1.5rem 4rem; align-items: end; margin-bottom: clamp(3rem, 8vh, 6rem); }
.index__title {
  font-size: clamp(2.5rem, 6vw, 6rem); font-weight: 750; font-stretch: 102%;
  line-height: .92; letter-spacing: -0.035em; text-wrap: balance;
}
.index__lede { color: var(--muted); font-size: clamp(1rem, 1.3vw, 1.2rem); max-width: 46ch; }

.index__group + .index__group { margin-top: clamp(3rem, 7vh, 5rem); }
.index__group-name {
  display: flex; justify-content: space-between; gap: 1rem;
  font-size: .9rem; font-weight: 600; color: var(--muted);
  padding-bottom: .9rem; border-bottom: 1px solid var(--line);
}
.index__item {
  display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: baseline; gap: 2rem;
  padding: clamp(.6rem, 1.4vh, 1.1rem) 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  transition: opacity 260ms ease;
}
.index__brand {
  font-size: clamp(2rem, 5.8vw, 5.6rem); font-weight: 700; font-stretch: 104%;
  line-height: 1; letter-spacing: -0.035em;
  transition: transform 420ms var(--ease-out);
}
.index__kind { color: var(--muted); font-size: .95rem; }
.index__go {
  display: inline-grid; place-items: center; align-self: center;
  width: 46px; height: 46px; border-radius: 50%;
  border: 1px solid var(--line);
  transition: transform 300ms var(--ease-out), background-color 200ms ease, color 200ms ease, border-color 200ms ease;
}
.index__go svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.index__item:active .index__go { transform: scale(0.94); }

@media (hover: hover) and (pointer: fine) {
  .index__list:hover .index__item { opacity: .32; }
  .index__list:hover .index__item:hover { opacity: 1; }
  .index__item:hover .index__brand { transform: translateX(1.2rem); }
  .index__item:hover .index__go { background: var(--fg); color: var(--bg); border-color: var(--fg); transform: translateX(4px); }
}

.index__preview {
  position: fixed; left: 0; top: 0; z-index: 40;
  width: clamp(150px, 13vw, 220px); aspect-ratio: 9 / 16;
  border-radius: var(--radius); overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(-50%, -50%, 0) scale(.9);
  transition: opacity 220ms var(--ease-out);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .55);
}
.index__preview video { width: 100%; height: 100%; object-fit: cover; }
.index__preview.is-on { opacity: 1; }

@media (max-width: 760px) {
  .index__head { grid-template-columns: 1fr; }
  .index__item { grid-template-columns: minmax(0, 1fr) auto; gap: .2rem 1rem; }
  .index__kind { grid-row: 2; }
  .index__go { grid-column: 2; grid-row: 1 / span 2; width: 42px; height: 42px; }
  .index__preview { display: none; }
}

/* ==========================================================================
   Capítulos de marca
   ========================================================================== */

.chapter { padding: clamp(5rem, 14vh, 10rem) var(--gutter) clamp(4rem, 10vh, 8rem); }

.chapter__head { margin-bottom: clamp(2rem, 6vh, 4.5rem); }
.chapter__kind { font-size: .95rem; font-weight: 600; color: var(--muted); margin-bottom: .6rem; }
.chapter__name {
  font-size: clamp(2.8rem, 11vw, 13rem);
  font-weight: 750; font-stretch: 106%;
  line-height: .88; letter-spacing: -0.04em;
  color: var(--accent);
  margin-left: -0.04em;
  overflow-wrap: anywhere;
}
/* con script, el nombre se ajusta para ocupar todo el ancho en una línea */
.anim .chapter__name { white-space: nowrap; width: max-content; overflow-wrap: normal; }

.chapter__body {
  display: grid;
  grid-template-columns: minmax(15rem, 3.2fr) minmax(0, 8.8fr);
  gap: clamp(2rem, 4vw, 5rem);
  align-items: start;
}
.chapter__side { position: sticky; top: 7rem; display: grid; gap: 1.6rem; }
.chapter__text { font-size: clamp(1.05rem, 1.35vw, 1.3rem); line-height: 1.5; max-width: 36ch; }
.chapter__fact {
  font-size: clamp(1rem, 1.15vw, 1.1rem); line-height: 1.5; max-width: 34ch;
  padding-top: 1.2rem; border-top: 1px solid var(--line);
}
.chapter__fact strong { font-weight: 750; color: var(--accent); }

/* ----- tarjetas de reel ----- */
.reels {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.2rem, 2.2vw, 2rem) clamp(.8rem, 1.4vw, 1.3rem);
}
.reel:nth-child(even) { margin-top: 26%; }
/* tres reels: tres columnas, el del medio desplazado */
.reels:has(> :nth-child(3):last-child) { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 82%; }
.reels:has(> :nth-child(3):last-child) .reel:nth-child(3) { margin-top: 0; }
/* dos reels: más grandes y con aire */
.reels:has(> :nth-child(2):last-child) { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 56%; }

.reel { display: grid; gap: .8rem; text-align: left; -webkit-tap-highlight-color: transparent; }
.reel__media {
  position: relative; display: block;
  aspect-ratio: 9 / 16;
  border-radius: var(--radius); overflow: hidden;
  background: color-mix(in srgb, var(--fg) 12%, var(--bg));
  transform: translateZ(0);
  transition: transform 160ms var(--ease-out);
}
.reel__media video, .reel__media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 700ms var(--ease-out);
}
.reel__media::after {
  content: ""; position: absolute; left: .7rem; bottom: .7rem;
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(10, 10, 14, .62) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 7v10l8-5z' fill='%23fff'/%3E%3C/svg%3E") center / 18px no-repeat;
}
.reel:active .reel__media { transform: scale(0.98); }
.reel__meta { display: grid; gap: .1rem; }
.reel__title { font-weight: 650; font-size: 1rem; letter-spacing: -0.01em; line-height: 1.3; }
.reel__desc { font-size: .86rem; color: var(--muted); }

@media (hover: hover) and (pointer: fine) {
  .reel:hover .reel__media video { transform: scale(1.04); }
  .reel__media::after { opacity: 0; }
}

/* revelado de las tarjetas: lista, con escalonado corto */
.anim .reel { opacity: 0; transform: translateY(28px); }
.anim .reel.is-in {
  opacity: 1; transform: none;
  transition: opacity 600ms var(--ease-out), transform 800ms var(--ease-out);
  transition-delay: calc(var(--i, 0) * 70ms);
}

@media (max-width: 900px) {
  .chapter__body { grid-template-columns: 1fr; }
  .chapter__side { position: static; }
  .reels, .reels:has(> :nth-child(2):last-child), .reels:has(> :nth-child(3):last-child) {
    display: flex; overflow-x: auto; scroll-snap-type: x mandatory;
    max-width: none;
    margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) .5rem;
    scroll-padding: 0 var(--gutter);
    scrollbar-width: none;
  }
  .reels::-webkit-scrollbar { display: none; }
  .reel { flex: 0 0 min(68vw, 300px); scroll-snap-align: start; }
  .reel:nth-child(n) { margin-top: 0; }
}

/* ==========================================================================
   Fotografía
   ========================================================================== */

.photos { padding: clamp(6rem, 14vh, 10rem) var(--gutter); }
.photos__head { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 1.5rem 4rem; align-items: end; margin-bottom: clamp(2.5rem, 6vh, 4.5rem); }
.photos__title {
  font-size: clamp(2.5rem, 6vw, 6rem); font-weight: 750; font-stretch: 102%;
  line-height: .92; letter-spacing: -0.035em;
}
.photos__lede { color: var(--muted); font-size: clamp(1rem, 1.3vw, 1.2rem); max-width: 44ch; }
.photos__grid { columns: 3 16rem; column-gap: clamp(.8rem, 1.6vw, 1.4rem); }
.photo {
  display: block; width: 100%;
  margin-bottom: clamp(.8rem, 1.6vw, 1.4rem);
  border-radius: var(--radius); overflow: hidden;
  break-inside: avoid;
  background: color-mix(in srgb, var(--fg) 8%, var(--bg));
}
.photo img { width: 100%; height: auto; transition: transform 900ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .photo:hover img { transform: scale(1.035); } }

.anim .photo { clip-path: inset(100% 0 0 0 round var(--radius)); }
.anim .photo.is-in {
  clip-path: inset(0 0 0 0 round var(--radius));
  transition: clip-path 1100ms var(--ease-in-out);
  transition-delay: calc(var(--i, 0) * 60ms);
}

@media (max-width: 760px) {
  .photos__head { grid-template-columns: 1fr; }
  .photos__grid { columns: 2 9rem; }
}

/* ==========================================================================
   Trayectoria
   ========================================================================== */

.career { padding: clamp(4rem, 10vh, 7rem) var(--gutter) clamp(6rem, 14vh, 10rem); }
.career__title {
  font-size: clamp(2.5rem, 6vw, 6rem); font-weight: 750; font-stretch: 102%;
  line-height: .92; letter-spacing: -0.035em;
  margin-bottom: clamp(2.5rem, 6vh, 4.5rem);
}
.job {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 6fr) minmax(0, 3fr);
  gap: 1.5rem clamp(1.5rem, 4vw, 4rem);
  padding: clamp(2rem, 4.5vh, 3rem) 0;
  border-top: 1px solid var(--line);
}
.job:last-child { border-bottom: 1px solid var(--line); }
.job__years {
  font-size: clamp(1.5rem, 2.6vw, 2.5rem); font-weight: 700; font-stretch: 100%;
  letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums;
}
.job__role { font-size: clamp(1.25rem, 1.8vw, 1.65rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
.job__org { color: var(--muted); margin: .4rem 0 1.1rem; }
.job__points { display: grid; gap: .55rem; max-width: 62ch; }
.job__points li { position: relative; padding-left: 1.2rem; }
.job__points li::before { content: ""; position: absolute; left: 0; top: .72em; width: .5rem; height: 1px; background: currentColor; }

.growth { display: grid; gap: .75rem; align-self: start; }
.growth figcaption { font-size: .86rem; font-weight: 600; color: var(--muted); }
.growth__row { display: grid; grid-template-columns: 4.2rem minmax(0, 1fr) 2.6rem; align-items: center; gap: .7rem; font-size: .86rem; }
.growth__label { color: var(--muted); }
.growth__track { position: relative; height: 10px; border-radius: 999px; background: color-mix(in srgb, var(--fg) 8%, transparent); overflow: hidden; }
.growth__bar {
  position: absolute; inset: 0; border-radius: inherit;
  background: color-mix(in srgb, var(--fg) 35%, transparent);
  transform-origin: left; transform: scaleX(var(--w, 1));
}
.growth__row--after .growth__bar { background: var(--accent); }
.growth__val { font-weight: 800; font-variant-numeric: tabular-nums; text-align: right; font-size: 1rem; }
.anim .growth .growth__bar { transform: scaleX(0); }
.anim .growth.is-in .growth__bar { transform: scaleX(var(--w, 1)); transition: transform 1100ms var(--ease-out); }
.anim .growth.is-in .growth__row--after .growth__bar { transition-delay: 180ms; }

@media (max-width: 960px) {
  .job { grid-template-columns: minmax(0, 1fr); }
  .growth { max-width: 26rem; }
}

/* ==========================================================================
   Sobre mí
   ========================================================================== */

.about { padding: clamp(6rem, 14vh, 10rem) var(--gutter) clamp(3rem, 8vh, 5rem); }
.about__title {
  font-size: clamp(2.5rem, 6vw, 6rem); font-weight: 750; font-stretch: 102%;
  line-height: .92; letter-spacing: -0.035em; margin-bottom: clamp(1.5rem, 4vh, 2.5rem);
}
.about__lede {
  font-size: clamp(1.35rem, 2.6vw, 2.5rem); font-weight: 500; line-height: 1.22;
  letter-spacing: -0.02em; max-width: 30ch; text-wrap: pretty;
}
.about__cols {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2.5rem clamp(1.5rem, 4vw, 4rem);
  margin-top: clamp(3rem, 8vh, 5.5rem);
  padding-top: 2rem; border-top: 1px solid var(--line);
}
.about__col h3 { font-size: .9rem; font-weight: 700; color: var(--muted); margin-bottom: 1rem; }
.about__col h3:not(:first-child) { margin-top: 2.2rem; }
.about__col li { padding: .45rem 0; border-bottom: 1px solid var(--line); }
.about__col li span { display: block; font-size: .86rem; color: var(--muted); }
.about__off { margin-top: clamp(2.5rem, 6vh, 4rem); color: var(--muted); }

@media (max-width: 860px) { .about__cols { grid-template-columns: 1fr; } }

/* ==========================================================================
   Contacto
   ========================================================================== */

.contact { padding: clamp(4rem, 10vh, 7rem) var(--gutter) 2rem; }
.contact__title {
  font-size: clamp(2.8rem, 9.5vw, 10.5rem); font-weight: 750; font-stretch: 104%;
  line-height: .9; letter-spacing: -0.045em;
}
.contact__actions {
  display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1rem;
  margin-top: clamp(2.5rem, 7vh, 4.5rem);
}
.contact__mail {
  display: inline-flex; align-items: center; gap: 1rem;
  width: 100%; margin-bottom: 1rem;
  font-size: clamp(1.4rem, 4.4vw, 4rem); font-weight: 700; letter-spacing: -0.03em; line-height: 1.1;
  text-align: left; flex-wrap: wrap;
}
.contact__mail-text {
  background: linear-gradient(currentColor, currentColor) left 100% / 100% 2px no-repeat;
  padding-bottom: .1em;
  transition: background-size 380ms var(--ease-out);
  overflow-wrap: anywhere;
}
.contact__mail-hint {
  font-size: .9rem; font-weight: 600; letter-spacing: 0;
  padding: .35rem .8rem; border-radius: 999px; border: 1px solid currentColor;
  opacity: .8;
  transition: opacity 200ms ease, transform 200ms var(--ease-out);
}
.contact__mail:active .contact__mail-hint { transform: scale(0.95); }
@media (hover: hover) and (pointer: fine) {
  .contact__mail:hover .contact__mail-text { background-size: 0% 2px; background-position: right 100%; }
  .contact__mail:hover .contact__mail-hint { opacity: 1; }
}

.footer {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 2rem;
  margin-top: clamp(5rem, 14vh, 9rem); padding-top: 1.2rem;
  border-top: 1px solid var(--line);
  font-size: .86rem; color: var(--muted);
}

/* ==========================================================================
   Reproductor
   ========================================================================== */

.player {
  position: fixed; inset: 0; z-index: 100;
  display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center; gap: clamp(1.5rem, 3vw, 3rem);
  padding: clamp(1rem, 4vh, 2.5rem) var(--gutter);
  color: #F6F5F2;
}
.player[hidden] { display: none; }
.player__backdrop {
  position: absolute; inset: 0; background: rgba(8, 8, 11, .94);
  opacity: 0; transition: opacity 360ms var(--ease-out);
}
.player.is-open .player__backdrop { opacity: 1; }

.player__frame {
  grid-column: 2;
  position: relative;
  height: min(88vh, 88svh, 1000px);
  aspect-ratio: var(--ar, 9 / 16);
  max-width: calc(100vw - 2 * var(--gutter));
  border-radius: 18px; overflow: hidden;
  background: #000;
  transform-origin: 0 0;
  box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .8);
}
.player__frame video, .player__frame img { width: 100%; height: 100%; object-fit: cover; }
.player__toggle { position: absolute; inset: 0; width: 100%; cursor: pointer; }
.player__toggle::after {
  content: ""; position: absolute; left: 50%; top: 50%;
  width: 76px; height: 76px; margin: -38px 0 0 -38px; border-radius: 50%;
  background: rgba(10, 10, 14, .7) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 7v10l8-5z' fill='%23fff'/%3E%3C/svg%3E") center / 34px no-repeat;
  opacity: 0; transform: scale(.85);
  transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out);
}
.player.is-paused .player__toggle::after { opacity: 1; transform: none; }

.player__bar {
  position: absolute; left: 0; right: 0; bottom: 0; height: 22px;
  cursor: pointer; touch-action: none;
}
.player__bar::before {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px;
  background: rgba(255, 255, 255, .25);
  transition: height 160ms var(--ease-out);
}
.player__progress {
  position: absolute; left: 0; right: 0; bottom: 0; height: 4px;
  background: #fff; transform-origin: left; transform: scaleX(0);
  transition: height 160ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .player__bar:hover::before, .player__bar:hover .player__progress { height: 8px; }
}

.player__info { grid-column: 3; align-self: end; max-width: 22rem; padding-bottom: 1rem; }
.player__brand { font-size: .9rem; font-weight: 600; color: #B4B4BE; margin-bottom: .5rem; }
.player__title { font-size: clamp(1.4rem, 2.2vw, 2.1rem); font-weight: 800; font-stretch: 110%; line-height: 1.05; letter-spacing: -0.03em; }
.player__desc { margin-top: .8rem; color: #CFCFD6; }
.player__controls { display: flex; align-items: center; gap: .5rem; margin-top: 1.6rem; }
.player__count { min-width: 3.6rem; text-align: center; font-variant-numeric: tabular-nums; font-size: .92rem; }

.player__info, .player__close { opacity: 0; transform: translateY(10px); transition: opacity 300ms var(--ease-out), transform 300ms var(--ease-out); }
.player.is-open .player__info, .player.is-open .player__close { opacity: 1; transform: none; transition-delay: 180ms; }

.player__close { position: absolute; top: clamp(1rem, 3vh, 1.6rem); right: var(--gutter); }

.icon-btn {
  display: inline-grid; place-items: center;
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .28);
  transition: transform 160ms var(--ease-out), background-color 200ms ease, border-color 200ms ease;
}
.icon-btn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn:active { transform: scale(0.94); }
@media (hover: hover) and (pointer: fine) { .icon-btn:hover { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .5); } }
#playerMute .ic-cross { display: none; }
.player.is-muted #playerMute .ic-cross { display: inline; }
.player.is-muted #playerMute .ic-waves { display: none; }

@media (max-width: 860px) {
  .player { grid-template-columns: 1fr; grid-template-rows: 1fr auto; justify-items: center; gap: 1rem; padding-top: 4.5rem; }
  .player__frame { grid-column: 1; height: auto; width: min(100%, calc((100svh - 15rem) * var(--arn, 0.5625))); }
  .player__info { grid-column: 1; align-self: start; max-width: none; width: 100%; padding: 0; display: grid; grid-template-columns: 1fr auto; gap: .2rem 1rem; align-items: end; }
  .player__desc { display: none; }
  .player__brand { margin: 0; }
  .player__title { grid-column: 1; font-size: 1.25rem; }
  .player__controls { grid-column: 2; grid-row: 1 / span 2; margin: 0; }
  .player__count { display: none; }
}

/* ==========================================================================
   Cursor y toast
   ========================================================================== */

.cursor {
  position: fixed; left: 0; top: 0; z-index: 90;
  pointer-events: none;
  display: none;
}
.cursor span {
  display: grid; place-items: center;
  width: 76px; height: 76px; margin: -38px 0 0 -38px; border-radius: 50%;
  background: var(--fg); color: var(--bg);
  font-weight: 700; font-size: .9rem;
  opacity: 0; transform: scale(.5);
  transition: opacity 180ms var(--ease-out), transform 220ms var(--ease-out), background-color 700ms var(--ease-in-out), color 700ms var(--ease-in-out);
}
.cursor.is-on span { opacity: 1; transform: none; }
@media (hover: hover) and (pointer: fine) { .cursor { display: block; } }

.toast {
  position: fixed; left: 50%; bottom: 1.5rem; z-index: 120;
  padding: .8rem 1.2rem; border-radius: 999px;
  background: var(--ink); color: var(--paper); font-weight: 600; font-size: .95rem;
  box-shadow: 0 16px 40px -14px rgba(0, 0, 0, .5);
  transform: translate(-50%, 180%);
  transition: transform 360ms var(--ease-drawer);
}
.toast.is-on { transform: translate(-50%, 0); }

/* ==========================================================================
   Movimiento reducido
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  html:not(.motion-full) { scroll-behavior: auto; }
  html:not(.motion-full) .wall__track, html:not(.motion-full) .hero__hint-line { animation: none; }
  html.anim:not(.motion-full) .reel, html.anim:not(.motion-full) .reel.is-in { transform: none; transition: opacity 400ms ease; }
  html.anim:not(.motion-full) .photo { clip-path: none; opacity: 0; }
  html.anim:not(.motion-full) .photo.is-in { opacity: 1; transition: opacity 500ms ease; }
  html.anim:not(.motion-full) .growth .growth__bar, html.anim:not(.motion-full) .growth.is-in .growth__bar { transform: scaleX(var(--w, 1)); transition: none; }
  html:not(.motion-full) .index__brand, html:not(.motion-full) .reel__media video, html:not(.motion-full) .photo img { transition: none; }
  html.hero-anim.is-ready:not(.motion-full) .hero__intro > * { transform: none; }
}
