@font-face {
  font-family: Archivo;
  src: url("./assets/Archivo-Variable.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}
@font-face {
  font-family: Brenco;
  src: url("./assets/Brenco-ExtraLight.otf") format("opentype");
  font-weight: 200;
  font-display: swap;
}

:root {
  --paper: #fafaf8;
  --ink: #111110;
  --muted: #575753;
  --line: #d5d5d0;
  --edge: clamp(16px, 1.5vw, 28px);
  --header: 100px;
  --transition-ease: cubic-bezier(.23, 1, .32, 1);
  --page-cover-ease: cubic-bezier(.65, 0, .35, 1);
  --page-reveal-ease: cubic-bezier(.33, 0, .2, 1);
  /* Global page transition (View Transitions): tune duration and curve here. */
  --page-transition-duration: 1400ms;
  --page-transition-ease: cubic-bezier(.65, 0, .15, 1);
  font-family: Archivo, sans-serif;
  font-stretch: 125%;
  font-weight: 300;
  color: var(--ink);
  background: var(--paper);
}

html:has(body:not([data-project="janemua"])) {
  --paper: #0d0d0c;
  --ink: #fafaf8;
  --muted: #b9b9b2;
  --line: #4b4b46;
  color: var(--ink);
  background: var(--paper);
}
html:has(body[data-project="ambre"]) { --paper: #000; background: #000; }
html:has(body[data-project="janemua"]) { --paper: #000; --ink: #fafaf8; --muted: #b9b9b2; --line: #4b4b46; color: var(--ink); background: var(--paper); }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header); scrollbar-gutter: stable; }
html.lenis { scroll-behavior: auto; }
#proyectos { scroll-margin-top: calc(-1 * var(--header)); }
#estudio { scroll-margin-top: calc(-1 * var(--header)); }
body, h1, h2, h3, p, dl, dd { margin: 0; }
.custom-cursor { position: fixed; z-index: 999; left: -100px; top: -100px; width: 20px; height: 20px; background: #fff; border-radius: 50%; pointer-events: none; opacity: 0; mix-blend-mode: difference; transform: translate(-50%, -50%); transition: width 220ms ease, height 220ms ease, opacity 180ms ease; }
.custom-cursor.is-active { opacity: 1; }
.custom-cursor.is-link { width: 36px; height: 36px; }
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  body:has(.custom-cursor.is-active), body:has(.custom-cursor.is-active) a, body:has(.custom-cursor.is-active) button { cursor: none; }
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 10;
  background: #0d0d0c;
  pointer-events: none;
  animation: page-overlay-in 1200ms var(--page-reveal-ease) both;
}
body[data-project="janemua"]::before,
body[data-project="ambre"]::before { background: #000; }
/* Project pages: keep the overlay opaque until the cover and fonts are ready (site.js removes the class). */
html.page-loading body::before { animation: none; opacity: 1; visibility: visible; }
body.is-leaving::before {
  visibility: visible;
  animation: page-overlay-out 800ms var(--page-cover-ease) both;
}
main { animation: page-content-in 1300ms var(--page-reveal-ease) backwards; }
@keyframes page-content-in {
  from { opacity: .96; }
  to { opacity: 1; }
}
@keyframes page-overlay-out {
  from { opacity: 1; transform: translateY(100%); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes page-overlay-in {
  from { opacity: 1; }
  to { opacity: 0; visibility: hidden; }
}

/* Global page transition: the new page slides up over the previous one (cross-document View Transitions).
   Browsers without support keep the curtain above. language.js adds .vt-nav when a transition runs. */
@view-transition { navigation: auto; }
html.vt-nav:root body::before { display: none; }
::view-transition { background: #000; }
::view-transition-old(root) { animation: page-transition-old var(--page-transition-duration) var(--page-transition-ease) both; }
::view-transition-new(root) { animation: page-transition-new var(--page-transition-duration) var(--page-transition-ease) both; }
@keyframes page-transition-old {
  to { transform: translateY(-15%) scale(.96); filter: brightness(.7); }
}
@keyframes page-transition-new {
  from { transform: translateY(100%); }
}
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
}
body:has(.case[open]) { overflow: hidden; }
.viewport-blur {
  position: fixed;
  z-index: 3;
  inset: auto 0 0;
  height: 140px;
  pointer-events: none;
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
  mask-image: linear-gradient(to bottom, transparent, black);
  -webkit-mask-image: linear-gradient(to bottom, transparent, black);
  transition: opacity 250ms ease;
}
.viewport-blur.over-image { backdrop-filter: blur(9px); -webkit-backdrop-filter: blur(9px); }
.viewport-blur:not(.over-image) { backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.viewport-blur.is-hidden { opacity: 0; }
button, select, textarea { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; transition: opacity 180ms ease; }
button, a { touch-action: manipulation; }
button { cursor: pointer; }
img { display: block; max-width: 100%; -webkit-touch-callout: none; }
[hidden] { display: none !important; }
::selection { background: var(--ink); color: var(--paper); }
:focus-visible { outline: 2px solid currentColor; outline-offset: 5px; }

.skip-link {
  position: fixed;
  z-index: 9;
  top: 8px;
  left: var(--edge);
  padding: 12px;
  background: var(--paper);
  transform: translateY(-150%);
}

.skip-link:focus { transform: translateY(0); }

.site-header {
  position: fixed;
  z-index: 8;
  inset: 0 0 auto;
  height: var(--header);
  padding-inline: var(--edge);
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
  mix-blend-mode: difference;
}

.header-mark { display: grid; align-items: center; min-height: 44px; }
.header-mark img { width: 130px; height: auto; filter: invert(1); }
.brand-mark { display: block; width: 150px; aspect-ratio: 188.13 / 36.46; font-size: 0; }
.header-mark--home { opacity: 0; visibility: hidden; transition: opacity 220ms ease, visibility 220ms; }
.header-mark--home.is-visible, .header-mark--home:focus-visible { opacity: 1; visibility: visible; }
.menu { display: flex; align-items: center; gap: clamp(13px, 1.5vw, 24px); }
.menu a, .menu-toggle {
  font-family: Archivo, sans-serif;
  font-size: clamp(13px, .95vw, 15px);
  font-weight: 300;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.menu a { display: grid; align-items: center; min-height: 44px; transition: opacity 180ms ease; }
@media (hover: hover) and (pointer: fine) {
  a:hover:not(.header-mark) { opacity: .55; }
}
.menu-toggle { display: none; }
.menu-label, .menu-rule, .menu-extra { display: none; }

.hero {
  position: relative;
  height: clamp(570px, 72svh, 810px);
  padding: calc(var(--header) + 13px) var(--edge) 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
}

.wordmark { position: relative; width: min(72%, 800px); align-self: flex-start; isolation: isolate; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.wordmark { font-family: Archivo, sans-serif; font-size: clamp(80px, 31vw, 450px); font-weight: 700; letter-spacing: -.05em; line-height: .8; }
.wordmark span { display: block; width: 100%; aspect-ratio: 188.13 / 53.29; font-size: 0; }
.brand-mark, .wordmark span, .footer-mark > span { background: currentColor; -webkit-mask: url("./assets/pulso-logo-final.svg?v=1") center / contain no-repeat; mask: url("./assets/pulso-logo-final.svg?v=1") center / contain no-repeat; }
.wordmark-main { position: relative; }
.visually-hidden, .wordmark .visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; background: none; -webkit-mask: none; mask: none; aspect-ratio: auto; }
.brand-mark { -webkit-mask-image: url("./assets/pulso-logo-final-mark.svg?v=1"); mask-image: url("./assets/pulso-logo-final-mark.svg?v=1"); }

.hero p {
  align-self: flex-end;
  max-width: 380px;
  text-align: left;
  font-size: clamp(17px, 1.35vw, 20px);
  line-height: 1.22;
  letter-spacing: -.025em;
}
.hero p span { white-space: nowrap; }

.projects-heading {
  padding: 0 var(--edge) 24px;
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 400;
  letter-spacing: -0.03em;
}

.project {
  --trim-y: 0px;
  --trim-x: 0px;
  --lift: 0px;
  position: relative;
  height: 100svh;
  min-height: 500px;
}

.project-frame {
  position: absolute;
  inset: 0;
  clip-path: inset(var(--trim-y) var(--trim-x));
  overflow: hidden;
  isolation: isolate;
  background: #020202;
  color: #fff;
}

.project-frame:focus-within { clip-path: inset(0); }
.project--forma .project-frame { background: #000; }
.project--ambre .project-frame { background: #000; }

.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: translateY(var(--lift)) scale(1.04);
  transition: scale 900ms var(--transition-ease);
}
@media (hover: hover) and (pointer: fine) {
  .project-frame:has(.project-title-link:hover) .project-image { scale: 1.025; }
}

.project--tatcha .project-image { object-fit: cover; }
.project-caption {
  position: absolute;
  z-index: 1;
  inset: auto max(var(--edge), calc(var(--trim-x) + 16px)) max(35px, calc(var(--trim-y) + 24px));
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  color: #fff;
}

.project-frame:focus-within .project-caption { inset-inline: var(--edge); }
.project-frame::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 32%;
  z-index: 0;
  background: linear-gradient(to top, rgb(0 0 0 / 42%), transparent);
  pointer-events: none;
}
.project-caption h2 {
  font-size: clamp(36px, 5vw, 78px);
  font-weight: 500;
  letter-spacing: -.065em;
  line-height: .97;
}

.project-caption p { margin-top: 10px; font-family: Archivo, sans-serif; font-weight: 300; font-size: 13px; }
.project-title-link { display: inline-block; }
.project-caption .project-link { align-self: flex-start; }
.project-link, .button, .case-close {
  min-height: 44px;
  padding: 10px 14px;
  border: 1px solid currentColor;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  white-space: nowrap;
  transition: background-color .18s, color .18s, border-color .18s;
}
.project-link { color: #fff; background: #1118; }
.project-link:hover { background: #fff; color: #111; border-color: #fff; }

.studio, .contact {
  margin-inline: var(--edge);
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  border-bottom: 1px solid var(--line);
}

.studio { min-height: 75svh; border-top: 1px solid var(--line); }
.studio-intro, .services, .contact > div, .contact form {
  padding-block: clamp(44px, 6.8vw, 105px);
}

.studio-intro, .contact > div { padding-right: clamp(20px, 4vw, 64px); }
.services, .contact form { padding-left: clamp(24px, 3vw, 48px); border-left: 1px solid var(--line); }

.studio h2, .contact h2 {
  font-size: clamp(45px, 6.3vw, 100px);
  line-height: .94;
  font-weight: 500;
  letter-spacing: -.067em;
}

.studio-intro p, .contact > div p {
  max-width: 420px;
  margin-top: 28px;
  font-size: clamp(16px, 1.55vw, 22px);
  line-height: 1.26;
  letter-spacing: -.025em;
}

.services { display: grid; grid-template-columns: minmax(80px, 1fr) 2fr; align-content: start; gap: 20px; }
.socials { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(80px, 1fr) 2fr; gap: 20px; margin-top: 64px; }
.social-links { display: flex; flex-wrap: wrap; gap: 20px; font-size: 15px; }
.social-icon { display: inline-flex; width: 24px; height: 24px; }
.social-icon svg { display: block; width: 100%; height: 100%; }
.services { grid-template-rows: auto auto 1fr; }
.services h3 { color: var(--ink); font-size: clamp(17px, 1.4vw, 21px); font-weight: 500; letter-spacing: -.045em; }
.service-benefits > div { padding: 12px 0; border-bottom: 1px solid var(--line); }
.service-benefits h4 { margin: 0; font-size: 16px; font-weight: 500; }
.service-benefits p { margin-top: 4px; color: var(--muted); font-size: 15px; line-height: 1.35; }
.service-benefits a { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 52px; font-size: 16px; }

.contact form { display: grid; align-content: start; gap: 10px; }
.contact label { font-size: 15px; }
.contact select, .contact textarea {
  background: transparent;
  border: 1px solid #a2a29d;
  border-radius: 0;
  width: 100%;
  min-height: 44px;
  padding: 10px;
  margin-bottom: 10px;
}
.contact textarea { resize: vertical; }
.button { justify-self: start; color: var(--paper); background: var(--ink); border-color: var(--ink); }
.button:hover { color: var(--ink); background: var(--paper); }
.button:disabled { opacity: .45; cursor: not-allowed; }
.home-close { min-height: max(0px, calc(100svh - var(--header) - var(--footer-height, 180px))); margin: 0 var(--edge); padding: 12px 0 clamp(90px, 8vw, 120px); display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; gap: clamp(30px, 4vw, 55px); }
#contacto.home-close { scroll-margin-top: -12px; }
.home-close h2 { max-width: 9em; font-size: clamp(45px, 6vw, 90px); line-height: .98; letter-spacing: -.06em; }
.home-contact-intro { max-width: 32em; margin-top: 28px; font-size: clamp(18px, 1.6vw, 24px); line-height: 1.35; }
.home-close a { font-size: clamp(18px, 1.5vw, 24px); font-weight: 500; }
.home-contact-details { display: grid; grid-template-columns: 1.2fr .85fr 1fr; gap: 30px; width: 100%; }
.home-contact-details > div { padding-top: 16px; }
.home-contact-details h3 { margin-bottom: 12px; color: var(--muted); font-size: 14px; font-weight: 300; text-transform: uppercase; }
/* Same style as the contact intro paragraph (.home-contact-intro). */
.home-contact-details a, .home-contact-details p { font-size: clamp(18px, 1.6vw, 24px); font-weight: 200; letter-spacing: normal; line-height: 1.35; overflow-wrap: anywhere; }
.contact-socials .social-links { gap: 4px; }
.contact-socials { margin-top: 12px; margin-left: -10px; }
.contact-socials .social-icon { display: inline-flex; width: 44px; height: 44px; margin: 0; align-items: center; justify-content: center; }
.contact-socials .social-icon svg { width: 24px; height: 24px; }
.contact-page { padding: var(--header) var(--edge) 0; }
.contact-heading { min-height: 38svh; display: flex; align-items: flex-start; }
.contact-heading h1 { font-size: clamp(54px, 18vw, 280px); line-height: .9; letter-spacing: -.07em; font-weight: 500; }
.contact-row { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: clamp(30px, 4vw, 65px) 0; }
.contact-row h2 { color: var(--muted); font-size: 14px; font-weight: 300; text-transform: uppercase; letter-spacing: .04em; }
.contact-row a, .contact-address { display: inline-block; margin-top: 14px; font-size: clamp(24px, 3.5vw, 56px); letter-spacing: -.045em; line-height: 1.15; overflow-wrap: anywhere; }
.contact-row + .contact-row { border-top: 0; }
.contact-top { display: flex; margin: 36px 0 36px auto; }
.project-page { padding: calc(var(--header) + 70px) var(--edge) 0; }
.project-page h1 { font-size: clamp(60px, 11vw, 160px); line-height: .9; letter-spacing: -.075em; text-transform: uppercase; font-weight: 500; overflow-wrap: anywhere; margin-bottom: 24px; }
body[data-project="ambre"] .project-page h1 { word-spacing: .18em; }
.project-cover { width: 100%; height: 78svh; min-height: 440px; object-fit: cover; background: #050505; }
.project-cover[src*="ambre"] { object-fit: contain; background: #000; }
.project-cover--square { object-fit: contain; background: #000; }
.project-cover[src*="tatcha-3"], .project-cover[src*="tatcha-11"] { height: auto; min-height: 0; aspect-ratio: 8 / 5; }
.project-image-note { margin-top: 10px; color: var(--muted); font-size: 13px; }
.project-overview { display: grid; grid-template-columns: 1fr 1fr; gap: 7vw; padding: clamp(75px, 10vw, 160px) 0; }
.project-kicker, .project-information h2, .project-information div p:first-child, .project-next > p { font-family: Archivo, sans-serif; font-size: 13px; font-weight: 300; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.project-overview h2 { margin-top: 22px; max-width: 11em; font-size: clamp(36px, 4vw, 62px); line-height: 1; letter-spacing: -.055em; }
.project-overview > p { max-width: 27em; font-size: clamp(19px, 1.8vw, 27px); line-height: 1.4; letter-spacing: -.03em; }
.project-overview > .project-description { max-width: 27em; font-size: clamp(19px, 1.8vw, 27px); line-height: 1.4; letter-spacing: -.03em; }
.project-description p + p { margin-top: 1em; }
.project-gallery img { width: 100%; height: auto; min-height: 40vw; object-fit: cover; background: #111; }
.project-gallery--tatcha { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--edge); }
.project-gallery--tatcha img { min-height: 0; aspect-ratio: 1; object-fit: cover; }
.project-gallery--tatcha .project-gallery-wide { grid-column: 1 / -1; }
.project-gallery--tatcha .project-gallery-scene { aspect-ratio: 2200 / 1165; object-fit: contain; }
.project-gallery--tatcha-editorial img { aspect-ratio: 8 / 5; object-fit: contain; }
.project-gallery--janemua { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--edge); }
.project-gallery--janemua img { min-height: 0; aspect-ratio: 1; object-fit: contain; background: #000; }
.project-gallery--janemua .project-gallery-wide { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
.project-gallery--janemua video { display: block; width: 100%; aspect-ratio: 1; object-fit: contain; background: #000; opacity: 0; }
.project-gallery--janemua video.is-visible { opacity: 1; }
.project-page--dark { background: #000; color: #f8f8f6; }
.project-page--dark .project-kicker,
.project-page--dark .project-information h2,
.project-page--dark .project-information div p:first-child,
.project-page--dark .project-next > p { color: #aaa; }
.project-page--dark .project-information,
.project-page--dark .project-next #next-project { border-color: #444; }
.project-information { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 30px; padding: 60px 0 100px; border-bottom: 1px solid var(--line); }
.project-information div p + p { margin-top: 12px; font-size: 20px; }
.project-next { padding: 65px 0 40px; }
/* Fit to the title so the link (hover fade and custom cursor) only covers the text, like the other links. */
.project-next #next-project { display: flex; width: fit-content; justify-content: space-between; gap: 15px; padding: 25px 0; font-size: clamp(45px, 7vw, 110px); letter-spacing: -.065em; font-weight: 500; }
.project-next > a:last-child { display: inline-block; margin-top: 8px; }
.about-page { padding: var(--header) var(--edge) 0; }
.about-intro { display: grid; grid-template-columns: 2fr 1fr; gap: 7vw; padding: clamp(100px, 15vw, 220px) 0 110px; align-items: start; }
.about-intro h1, .about-intro h2, .about-lead { font-size: clamp(36px, 4.2vw, 64px); line-height: 1.05; letter-spacing: -.055em; font-weight: 500; }
.about-intro h1, .about-intro h2 { text-indent: 15%; }
.home-about { margin: 0 var(--edge); }
.about-intro p { margin-top: 70px; max-width: 52ch; font-size: clamp(19px, 2vw, 28px); line-height: 1.2; }
.about-intro img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; background: #020202; }
.about-work { display: grid; grid-template-columns: 1fr 1fr; gap: 2vw; border-top: 1px solid var(--line); }
.about-side { min-width: 0; align-self: start; padding: 25px 0; display: flex; flex-direction: column; gap: clamp(60px, 10vw, 150px); }
.about-side span, .about-label { font-family: Archivo, sans-serif; font-weight: 300; text-transform: uppercase; font-size: 13px; letter-spacing: .05em; }
.about-side strong { font-size: clamp(42px, 5vw, 78px); font-weight: 500; letter-spacing: -.055em; line-height: 1.02; }
.about-side-copy > p { max-width: 28em; margin-top: clamp(30px, 4vw, 60px); padding-right: 24px; font-size: clamp(19px, 1.7vw, 25px); line-height: 1.3; }
.about-content { min-width: 0; padding: 25px 0 100px; }
.about-label { display: flex; justify-content: space-between; border-bottom: 1px solid var(--line); padding-bottom: 22px; }
.about-lead { margin: 60px 0 100px; }
.about-content > img { width: 100%; height: auto; }
.about-service { position: sticky; top: calc(var(--header) + var(--service-offset, 0px)); z-index: calc(2 + var(--service-index, 0)); min-height: max(410px, 45svh); padding-bottom: 35px; background: var(--paper); }
.about-service h2 { min-height: var(--service-title-height); padding: 12px 0; border-top: 1px solid var(--line); font-size: clamp(28px, 3.3vw, 54px); font-weight: 500; letter-spacing: -.06em; line-height: 1; }
.about-service:first-of-type h2 { border-top: 0; }
.about-services { --service-title-height: 78px; }
.service-cover { position: sticky; top: calc(var(--header) + var(--service-stack-height, 312px)); z-index: 6; height: 65svh; background: var(--paper); }
.about-services .about-content { padding-bottom: 35px; }
.home-study { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, .6fr); align-items: start; gap: clamp(40px, 7vw, 110px); min-height: 100svh; padding: clamp(90px, 10vw, 150px) 0; }
.home-study h2 { text-indent: 0; max-width: 14em; font-size: clamp(42px, 5vw, 78px); line-height: 1.02; }
.study-title-break { display: block; }
.home-study p { margin: 0; max-width: 24em; }
.home-study p + p { margin-top: 1em; }
.home-study-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 40px; padding-top: 8px; }
.about-service:nth-of-type(2) { --service-index: 1; }
.about-service:nth-of-type(3) { --service-index: 2; }
.about-service:nth-of-type(4) { --service-index: 3; }
.about-service p { max-width: 15em; margin: 28px 0 0 auto; font-size: clamp(19px, 1.8vw, 26px); line-height: 1.35; letter-spacing: -.02em; }
/* Texto corrido más fino que la base (300); etiquetas, menú y footer siguen en 300 */
.home-study p, .about-side-copy > p, .about-service p, .home-contact-intro, .project-overview > p, .project-overview > .project-description { font-weight: 200; }
.home-study p, .about-side-copy > p, .about-service p, .home-contact-intro { letter-spacing: -.03em; }
.about-close { border-top: 1px solid var(--line); padding: 70px 0; display: flex; justify-content: space-between; align-items: end; gap: 24px; }
.about-close h2 { max-width: 8em; font-size: clamp(40px, 6vw, 90px); line-height: .95; letter-spacing: -.06em; }
.about-close a { font-size: 22px; white-space: nowrap; }

.footer {
  display: grid;
  /* Closing mark: logo spanning the full content width, copyright below it aligned right. */
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "logo" "copyright";
  align-items: end;
  gap: clamp(14px, 1.4vw, 22px);
  min-height: 0;
  padding: clamp(32px, 3vw, 48px) var(--edge) var(--edge);
  background: #0d0d0c;
  color: #fafaf8;
}
.footer img { grid-area: logo; width: min(100%, 610px); height: auto; filter: invert(1); }
.footer-mark { grid-area: logo; position: relative; isolation: isolate; display: block; width: 100%; overflow: hidden; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.footer-mark > span { display: block; width: 100%; aspect-ratio: 188.13 / 36.46; font-size: 0; -webkit-mask-image: url("./assets/pulso-logo-final-mark.svg?v=1"); mask-image: url("./assets/pulso-logo-final-mark.svg?v=1"); }
.footer-mark-main { position: relative; color: #fafaf8; }
/* Hide the small header logo while the large footer logo is on screen (site.js toggles .footer-in-view). */
.site-header .header-mark { transition: opacity 300ms ease, visibility 300ms; }
html.footer-in-view body .site-header:not(:has(.menu-toggle[aria-expanded="true"])) a.header-mark { opacity: 0; visibility: hidden; }
/* The home intro disables this transition; restore the fade once the footer has been reached. */
html.footer-seen body.has-intro .site-header a.header-mark--home { transition: opacity 300ms ease, visibility 300ms; }
.footer p { grid-area: copyright; justify-self: end; color: #c4c4bf; font-size: 14px; text-align: right; }
.divider-host { position: relative; }
.scroll-divider { position: absolute; inset-inline: 0; pointer-events: none; }
.scroll-divider::before {
  content: "";
  display: block;
  height: 100%;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 2200ms cubic-bezier(.25, .1, .25, 1);
}
.scroll-divider.is-drawn::before { transform: scaleX(1); }
@media (prefers-reduced-motion: reduce) {
  .scroll-divider::before { transform: none; transition: none; }
}
body[data-project="ambre"] .footer,
body[data-project="janemua"] .footer { background: #000; }

.case {
  width: min(100% - 2 * var(--edge), 1080px);
  max-width: none;
  max-height: 92svh;
  padding: clamp(14px, 2.5vw, 36px);
  background: var(--paper);
  color: var(--ink);
  border: 0;
}
.case::backdrop { background: #000b; }
.case-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.case-category { color: var(--muted); font-size: 14px; }
.case-close:hover { background: var(--ink); color: var(--paper); }
.case-copy { margin-block: 28px 24px; }
.case h2 { font-size: clamp(42px, 6vw, 88px); letter-spacing: -.067em; line-height: 1; font-weight: 500; }
.case-description { margin-top: 12px; max-width: 62ch; line-height: 1.38; }
.case-image { width: 100%; height: auto; background: #171717; }

/* El texto de Estudio usa siempre el mismo ancho que las descripciones de servicios (.about-service p: 15em) */
@media (min-width: 701px) {
  .home-study { grid-template-columns: minmax(0, 1fr) calc(15 * clamp(19px, 1.8vw, 26px)); }
  .home-study p { max-width: none; }
}
@media (min-width: 701px) and (max-width: 1024px) {
  .home-study { gap: clamp(32px, 5vw, 54px); }
  .home-study h2 { text-wrap: balance; }
  html[lang="en"] .study-title-break { display: none; }
}

@media (max-width: 700px) {
  :root { --header: 54px; }
  .site-header { background: var(--paper); color: var(--ink); mix-blend-mode: normal; }
  .project-page--dark .site-header { background: #000; color: #f8f8f6; }
  .header-mark img { width: 112px; filter: none; }
  .brand-mark { width: 134px; }
  .hero { height: clamp(400px, 55svh, 560px); padding-top: calc(var(--header) + 11px); }
  .hero p { align-self: flex-start; max-width: 335px; margin-bottom: 20px; font-size: 17px; }
  .project { height: 89svh; min-height: 460px; }
  .project--tatcha .project-image { object-position: 46% 50%; }
  .project-caption {
    text-align: center;
    inset: auto max(var(--edge), calc(var(--trim-x) + 8px)) max(46px, calc(var(--trim-y) + 16px));
    flex-direction: column;
    align-items: center;
  }
  .project-caption .project-link { align-self: center; }
  .studio, .contact { grid-template-columns: 1fr; }
  .studio-intro, .contact > div { padding: 49px 0 30px; }
  .services, .contact form { border-left: 0; padding: 0 0 42px; }
  .services { grid-template-columns: 1fr; gap: 14px; }
  .socials { grid-template-columns: 1fr; gap: 14px; margin-top: 32px; }
  .footer { gap: 12px; }
  .footer img { width: min(100%, 255px); }
  .footer p { justify-self: center; text-align: center; font-size: 12px; font-stretch: 100%; }
  .home-contact-details { grid-template-columns: 1fr; gap: 24px; }
  .home-close { padding: 12px 0 145px; gap: 24px; }
  #contacto.home-close { scroll-margin-top: -12px; }
  .home-contact-intro { margin-top: 18px; }
  .home-contact-details { gap: 14px; }
  .home-contact-details > div { padding-top: 10px; }
  .home-contact-details h3 { margin-bottom: 6px; }
  .about-intro { grid-template-columns: 1fr; gap: 45px; padding: 90px 0 70px; }
  .about-intro h1, .about-intro h2 { text-indent: 0; }
  .about-intro p { margin-top: 28px; }
  .about-intro img { aspect-ratio: 4 / 3; }
  .about-work { grid-template-columns: 1fr; gap: 0; }
  .about-side { position: static; height: auto; padding: 25px 0 45px; gap: 40px; }
  .home-study { grid-template-columns: 1fr; min-height: 100svh; gap: 30px; padding: 80px 0; }
  .study-title-break { display: none; }
  .home-study p { max-width: 15em; margin: 0 0 0 18%; }
  .home-study-copy { gap: 24px; padding-top: 0; }
  .home-study-copy > div { width: 100%; }
  .about-content { padding: 0 0 65px; }
  .about-lead { margin: 35px 0 50px; }
  .about-services { --service-title-height: 58px; }
  .about-service { min-height: 310px; }
  .about-service h2 { font-size: clamp(25px, 7vw, 38px); }
  .about-service p { margin-left: 18%; }
  .about-close { align-items: start; flex-direction: column; }
  .project-page { padding-top: calc(var(--header) + 38px); }
  .project-page h1 { font-size: clamp(48px, 12vw, 80px); }
  .project-cover { min-height: 0; height: auto; aspect-ratio: 16 / 9; }
  .project-cover[src*="tatcha"], .project-cover[src*="ambre"] { aspect-ratio: 1; }
  .project-cover[src*="tatcha-3"], .project-cover[src*="tatcha-11"] { aspect-ratio: 8 / 5; }
  .project-overview { grid-template-columns: 1fr; gap: 30px; padding: 65px 0; }
  .project-information { grid-template-columns: 1fr; gap: 25px; padding: 45px 0 65px; }
  .project-gallery--janemua { grid-template-columns: 1fr; }
  .project-gallery--tatcha { grid-template-columns: 1fr; }
  .project-gallery--tatcha .project-gallery-wide { grid-column: auto; }
  .project-gallery--janemua video { grid-column: auto; }
  .project-gallery--janemua .project-gallery-wide { grid-column: auto; }
}

@media (max-width: 700px), (max-width: 950px) and (max-height: 500px) and (orientation: landscape) {
  html:has(body.menu-open) { scrollbar-gutter: auto; }
  body.menu-open { overflow: hidden; }
  .site-header { background: var(--paper); color: var(--ink); mix-blend-mode: normal; }
  body:has(.project-page) .site-header { position: fixed; top: -100px; height: calc(100px + var(--header) + env(safe-area-inset-top, 0px)); padding-top: calc(100px + env(safe-area-inset-top, 0px)); isolation: isolate; background: #0d0d0c; color: #f8f8f6; }
  body[data-project="janemua"] .site-header, body[data-project="ambre"] .site-header { background: #000; }
  body:has(.project-page) .project-page { padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 38px); }
  .project-page--dark .site-header { background: #000; color: #f8f8f6; }
  .menu-toggle { display: inline-grid; place-items: center; position: relative; z-index: 2; width: 44px; height: 44px; border: 0; background: transparent; padding: 0; }
  .menu-toggle::before, .menu-toggle::after { content: ""; position: absolute; width: 25px; height: 1.5px; background: currentColor; transition: transform 180ms ease; }
  .menu-toggle::before { transform: translateY(-5px); }
  .menu-toggle::after { transform: translateY(5px); }
  .menu-toggle[aria-expanded="true"]::before { transform: rotate(45deg); }
  .menu-toggle[aria-expanded="true"]::after { transform: rotate(-45deg); }
  .site-header:has(.menu-toggle[aria-expanded="true"]) { background: transparent; color: #fff; }
  .site-header:has(.menu-toggle[aria-expanded="true"]) .header-mark { position: relative; z-index: 2; color: #fff; }
  .site-header:has(.menu-toggle[aria-expanded="true"]) .header-mark--home { opacity: 1; visibility: visible; }
  .menu-toggle::before, .menu-toggle::after { transition: transform 600ms cubic-bezier(.65, 0, .35, 1); }
  /* Full-screen black menu: a curtain that unveils from the top, then the content rises in sequence. */
  .menu {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 0;
    position: fixed;
    z-index: 1;
    inset: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: #000;
    color: #f8f8f6;
    padding: calc(var(--header) + env(safe-area-inset-top, 0px) + 28px) max(var(--edge), env(safe-area-inset-right)) max(32px, env(safe-area-inset-bottom)) max(var(--edge), env(safe-area-inset-left));
    visibility: hidden;
    pointer-events: none;
    clip-path: inset(0 0 100% 0);
    transition: clip-path 620ms cubic-bezier(.65, 0, .35, 1) 120ms, visibility 0s linear 740ms;
  }
  .menu-toggle[aria-expanded="true"] + .menu {
    visibility: visible;
    pointer-events: auto;
    clip-path: inset(0 0 0 0);
    transition: clip-path 820ms cubic-bezier(.76, 0, .24, 1), visibility 0s;
  }
  .menu > * {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 260ms ease, transform 260ms ease;
  }
  .menu-toggle[aria-expanded="true"] + .menu > * {
    opacity: 1;
    transform: none;
    transition: opacity 760ms cubic-bezier(.22, 1, .36, 1), transform 1000ms cubic-bezier(.22, 1, .36, 1);
    transition-delay: calc(380ms + var(--menu-i, 0) * 55ms);
  }
  .menu a { display: flex; flex: 0 0 auto; align-items: center; min-height: 48px; font-family: Archivo, sans-serif; font-weight: 300; font-size: clamp(28px, 7.5vw, 38px); letter-spacing: -.02em; text-transform: none; line-height: 1.1; }
  .menu .menu-label { display: block; margin: 0 0 10px; font-size: 14px; font-weight: 300; letter-spacing: -.01em; color: rgb(248 248 246 / 48%); }
  /* "Menú" label above the links removed at the user's request; "Hablemos"/"Redes" stay. */
  .menu > .menu-label { display: none; }
  /* Divider above the contact block removed at the user's request. */
  .menu .menu-rule { display: none; }
  .menu-toggle[aria-expanded="true"] + .menu .menu-rule { transform: none; }
  .menu .menu-extra { display: flex; flex-direction: column; align-items: flex-start; margin-top: auto; padding-top: 32px; }
  .menu .menu-extra a { min-height: 44px; }
  .menu .menu-mail { margin-bottom: 26px; font-family: Archivo, sans-serif; font-size: clamp(22px, 6vw, 30px); font-weight: 300; letter-spacing: -.02em; text-transform: none; }
  .menu .menu-social { width: 44px; min-height: 44px; margin-left: -10px; justify-content: center; }
  .menu .menu-social svg { width: 24px; height: 24px; }
  .menu [data-language] { margin-top: 18px; font-family: Archivo, sans-serif; font-size: 15px; font-weight: 300; letter-spacing: .04em; text-transform: uppercase; color: rgb(248 248 246 / 64%); }
}
@media (prefers-reduced-motion: reduce) and (max-width: 700px) {
  .menu, .menu-toggle[aria-expanded="true"] + .menu, .menu > *, .menu-toggle[aria-expanded="true"] + .menu > * { transition: opacity 200ms ease, visibility 0s; transform: none; clip-path: none; }
  .menu { opacity: 0; }
  .menu-toggle[aria-expanded="true"] + .menu { opacity: 1; }
}

/* Reserve a separate row for the header while the gallery scrolls on touch phones. */
@media (hover: none) and (pointer: coarse) and (max-width: 700px),
       (hover: none) and (pointer: coarse) and (max-width: 950px) and (max-height: 500px) {
  html:has(.project-scrollport) { overflow: hidden; }
  body:has(.project-scrollport) {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    height: 100svh;
    height: 100dvh;
    overflow: hidden;
    background: var(--paper);
  }
  body:has(.project-scrollport) .site-header {
    position: relative;
    top: auto;
    height: calc(var(--header) + env(safe-area-inset-top, 0px));
    padding-top: env(safe-area-inset-top, 0px);
  }
  .project-scrollport {
    min-height: 0;
    overflow: auto;
    overscroll-behavior-y: contain;
  }
  body.menu-open .project-scrollport { overflow: hidden; }
  body:has(.project-scrollport) .project-page { padding-top: 38px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  body::before { display: none; }
  .project-frame { clip-path: none; }
  .project-image { transform: none; }
  .project-frame:has(.project-title-link:hover) .project-image { scale: none; }
}

/* Progressive reveal for project headings. */
.project-heading-word { opacity: .35; transition: opacity 180ms linear; }
.project-heading-word.is-visible { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .project-heading-word { opacity: 1; transition: none; } }

/* Editorial titles: Brenco serif. Small UI text keeps the sans. */
/* Project titles: regular weight and sentence case so the logo stays the only heavy caps element. */
.project-caption h2, .project-page h1, .project-next #next-project { font-family: Brenco, serif; font-weight: 200; letter-spacing: -.02em; text-transform: none; }
/* Service titles keep the original sans. */
.studio h2, .contact h2, .home-close h2, .contact-heading h1, .project-overview h2,
.about-intro h1, .about-intro h2, .about-lead, .about-side strong, .about-service h2, .case h2 {
  font-family: Brenco, serif;
  font-weight: 200;
  letter-spacing: -.02em;
}
