/* ==========================================================================
   Adriana Alcaraz Soler · Nutrición oncológica
   Editorial clinic after the Everlab reference: white ground, black type,
   one photograph edge to edge under a light serif statement, two-tone sans
   headlines, grey and beige rounded panels, warm photographic grounds that
   carry small white cards, black pill buttons, one black section for the
   BIA scene, the hero photograph again (defocused) to close.
   tokens → base → components → sections → motion → responsive
   ========================================================================== */

@font-face {
  font-family: "Geist";
  src: url("../assets/fonts/geist-latin-wght.woff2") format("woff2");
  font-weight: 100 900; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Literata";
  src: url("../assets/fonts/literata-latin-wght.woff2") format("woff2");
  font-weight: 200 900; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Geist Mono";
  src: url("../assets/fonts/geist-mono-latin-wght.woff2") format("woff2");
  font-weight: 100 900; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens ---------- */
:root {
  /* Colour */
  --white:    #FFFFFF;
  --ink:      #0A0A0A;
  --ink-2:    #5C5C5C;   /* secondary text, 6.7:1 on white */
  --ink-3:    #737373;   /* headline second lines, 4.7:1 on white, 4.2:1 on beige */
  --panel:    #F7F7F6;
  --card:     #F3F3F2;   /* soft cards and soft buttons */
  --card-2:   #E9E9E7;   /* hover, tracks */
  --beige:    #F4EFED;
  --beige-2:  #EBE3DF;
  --sand:     #B88A5E;
  /* Clinical palette: one petrol for booking, focus and selected states,
     a deep night for the dark surfaces, a pale clinical band, and a mid
     blue only for data. Arena stays a material ground. */
  --petrol:       #1F5662;   /* white on it 8.2:1; on white 8.2:1 */
  --petrol-hover: #17454F;
  --night:        #0F2A30;   /* white on it 15:1 */
  --band:         #E8F0F2;   /* ink-2 on it 5.8:1 */
  --band-2:       #D3E3E8;
  --mist:         #5E8A99;   /* data only: 3.3:1 on the band */
  --black:    #000000;
  --on-black:   #F4F4F3;
  --on-black-2: #A3A3A1; /* secondary text on black, 8:1 */
  --on-black-3: #7A7A79; /* headline second lines on black, 4.9:1 */
  --line:       rgba(0, 0, 0, .08);
  --line-strong:rgba(0, 0, 0, .16);
  --line-dark:  rgba(255, 255, 255, .14);

  /* BIA series */
  --muscle: #0A0A0A;
  --fat:    #B88A5E;
  --water:  #7C97A8;

  /* Monogram: the ribbon AA, one tone that turns light on dark grounds */
  --mark-1: var(--ink);

  --ring: var(--petrol);

  /* Type */
  --serif: "Literata", ui-serif, Georgia, "Times New Roman", serif;
  --sans:  "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono:  "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --fs-hero:  clamp(2.5rem, 1.55rem + 2.5vw, 3.75rem);
  --fs-h2:    clamp(2rem, 1.4rem + 1.8vw, 3rem);
  --fs-h3:    1.1875rem;
  --fs-lead:  clamp(1.0625rem, 1rem + .3vw, 1.1875rem);
  --fs-body:  1.0625rem;
  --fs-small: .9375rem;

  /* Space and shape */
  --container: 1280px;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --section: clamp(4.5rem, 9vw, 8rem);
  --gap: clamp(.625rem, 1.2vw, 1rem);
  --inset: .5rem;                 /* the frame around full-bleed photographs */
  --r-card: 1.25rem;
  --r-panel: 1.5rem;
  --header-h: 4.5rem;

  /* Motion */
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --t-fast: 150ms;
  --t-base: 260ms;
  --t-slow: 480ms;

  /* Film grain for the photographic grounds (an SVG turbulence tile) */
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .5 0 0 0 0 .5 0 0 0 0 .5 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1.5rem);
  scrollbar-color: #C9C9C7 var(--white);
  accent-color: var(--petrol);
  interpolate-size: allow-keywords;
}
body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--fs-body);
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  caret-color: var(--ink);
}
::selection { background: var(--band-2); color: var(--ink); }
.on-dark ::selection { background: #2B5A66; color: var(--white); }

[hidden] { display: none !important; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4, p, figure, blockquote, dl, dd { margin: 0; }
h1, h2, h3, h4 { text-wrap: balance; font-weight: 500; }
p, li, dd, figcaption { text-wrap: pretty; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
strong { font-weight: 600; }
table { border-collapse: collapse; }

:focus-visible { outline: 2px solid var(--ring); outline-offset: 3px; border-radius: 8px; }
.on-dark { --ring: var(--white); }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; padding: 0; margin: -1px;
}
.skip-link {
  position: fixed; left: 1rem; top: 1rem; z-index: 300;
  background: var(--night); color: var(--white); padding: .8rem 1.25rem; border-radius: 999px;
  font-weight: 500; transform: translateY(-200%); transition: transform var(--t-base) var(--ease-out);
}
.skip-link:focus { transform: none; }

.icon { width: 1.15em; height: 1.15em; flex: none; display: inline-block; vertical-align: middle; }
.tnum { font-variant-numeric: tabular-nums; }

/* The monogram takes its colour from a custom property,
   so the mark turns light on dark grounds. */
.mark-a { fill: var(--mark-1); }
/* The header mark carries a stroke mask along the ribbon's centreline.
   At rest the strokes are wide enough to show the whole mark. */
.mark-tie path { fill: none; stroke: #fff; stroke-width: 14; stroke-dasharray: 1; }

/* ---------- Photographic grounds ----------
   Warm, defocused colour fields with film grain, in place of stock imagery:
   they carry the small white cards and the thumbnails. */
.mat { position: relative; isolation: isolate; overflow: hidden; background-color: var(--m3); background-image:
  radial-gradient(120% 90% at 18% 12%, var(--m1) 0%, transparent 58%),
  radial-gradient(90% 110% at 88% 92%, var(--m2) 0%, transparent 62%),
  radial-gradient(70% 60% at 70% 30%, var(--m4, transparent) 0%, transparent 70%); }
.mat::after { content: ""; position: absolute; inset: 0; z-index: -1; background-image: var(--grain); background-size: 160px; opacity: .22; mix-blend-mode: overlay; pointer-events: none; }
.mat--terra { --m1: #E6A47C; --m2: #7E2E1C; --m3: #B4553A; --m4: rgba(242, 196, 160, .55); }
.mat--sand  { --m1: #F4ECE2; --m2: #B9976F; --m3: #DCC8B0; --m4: rgba(255, 250, 242, .6); }
.mat--sage  { --m1: #B7C0A0; --m2: #3F4A33; --m3: #737F5C; --m4: rgba(214, 220, 196, .45); }
.mat--sky   { --m1: #DCE6EA; --m2: #4F6E80; --m3: #8DA7B5; --m4: rgba(236, 242, 244, .5); }
.mat--cocoa { --m1: #8A6450; --m2: #1C130F; --m3: #4A342A; --m4: rgba(180, 140, 112, .35); }

/* ---------- Type ---------- */
/* Two-tone headline: the first sentence in ink, the second in grey */
.h2 { font-size: var(--fs-h2); font-weight: 500; line-height: 1.04; letter-spacing: -.03em; max-width: 21ch; }
.h2__soft { display: block; color: var(--ink-3); }
.h2--center { margin-inline: auto; text-align: center; }
.on-dark .h2 { color: var(--on-black); }
.on-dark .h2__soft { color: var(--on-black-3); }
.lead { font-size: var(--fs-lead); line-height: 1.5; }
.prose-link { font-weight: 500; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .22em; text-decoration-color: var(--line-strong); transition: text-decoration-color var(--t-fast); }
.prose-link:hover { text-decoration-color: currentColor; }

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--ink); --fg: var(--white);
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  min-height: 3rem; padding: .75rem 1.5rem;
  border-radius: 999px; background: var(--bg); color: var(--fg);
  font-size: 1rem; font-weight: 500; line-height: 1.2; letter-spacing: -.005em; text-align: center; white-space: nowrap;
  transition: background-color var(--t-base) var(--ease-out), color var(--t-base) var(--ease-out), transform var(--t-fast) var(--ease-out);
}
.btn:hover { --bg: #2A2A2A; }
.btn:active { transform: scale(.98); }
.btn .icon { transition: transform var(--t-base) var(--ease-out); }
.btn:hover .icon--arrow { transform: translate(2px, -2px); }
/* Booking: the one petrol action on light grounds */
.btn--book { --bg: var(--petrol); --fg: var(--white); }
.btn--book:hover { --bg: var(--petrol-hover); }
.btn--soft { --bg: var(--card); --fg: var(--ink); }
.btn--soft:hover { --bg: var(--card-2); }
.btn--white { --bg: var(--white); --fg: var(--ink); }
.btn--white:hover { --bg: #E9E9E7; }
/* Over a photograph: a clear pill that lets the picture through */
.btn--glass {
  --bg: rgba(255, 255, 255, .14); --fg: var(--white);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.btn--glass:hover { --bg: rgba(255, 255, 255, .24); }
.btn--sm { min-height: 2.75rem; padding: .5rem 1.1rem; font-size: .9375rem; }
.btn--lg { min-height: 3.25rem; padding: .85rem 1.65rem; font-size: 1.0625rem; }

.chip {
  display: inline-flex; align-items: center; gap: .5rem; min-height: 2.75rem;
  padding: .5rem 1rem; border-radius: 999px; background: var(--card);
  font-size: .9375rem; font-weight: 500;
  transition: background-color var(--t-base) var(--ease-out);
}
.chip:hover { background: var(--card-2); }
.links-row { display: flex; flex-wrap: wrap; gap: .5rem; }

/* ---------- Header ----------
   Light type straight over the hero photograph; once the page moves, a
   floating near-black bar. Both states are light on dark. */
.site-header {
  --mark-1: var(--on-black); --ring: var(--white);
  position: fixed; inset: 0 0 auto; z-index: 100; padding-inline: calc(var(--gutter) + var(--inset)); pointer-events: none;
}
.site-header__bar {
  pointer-events: auto;
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
  max-width: calc(var(--container) - 2 * var(--gutter)); height: var(--header-h);
  margin: var(--inset) auto 0; padding-inline: 0;
  border: 1px solid transparent; border-radius: 1.125rem;
  background-color: rgba(15, 42, 48, 0); color: var(--on-black);
  transition: max-width 700ms var(--ease-out), height 500ms var(--ease-out), margin 500ms var(--ease-out), padding 500ms var(--ease-out),
              background-color 400ms var(--ease-out), border-color 400ms var(--ease-out), box-shadow 400ms var(--ease-out);
}
.site-header.is-scrolled .site-header__bar,
.menu-open .site-header__bar {
  max-width: 62rem; height: 3.5rem; margin-top: .625rem; padding-inline: 1rem .375rem;
  background-color: rgba(15, 42, 48, .94); border-color: rgba(255, 255, 255, .08);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: 0 14px 34px -18px rgba(0, 0, 0, .5);
}

.brand { display: inline-grid; grid-template-columns: auto auto; column-gap: .65rem; align-items: center; align-content: center; min-height: 2.75rem; line-height: 1.1; }
.brand__mark { grid-row: 1 / span 2; width: 1.96rem; height: 1.875rem; }
.brand__name, .brand__tag { grid-column: 2; }
.brand__name { white-space: nowrap; font-size: 1.125rem; font-weight: 600; letter-spacing: -.03em; }
.brand__tag { margin-top: .1rem; white-space: nowrap; font-size: .8125rem; color: var(--ink-2); }
.site-header .brand__tag { color: rgba(255, 255, 255, .72); }
.is-scrolled .brand__tag { color: var(--on-black-2); }

.site-nav { position: relative; }
.site-nav ul { position: relative; display: flex; gap: .125rem; }
.site-nav a {
  display: inline-flex; align-items: center; min-height: 2.5rem; padding-inline: .85rem; border-radius: 999px;
  font-size: .9375rem; color: rgba(255, 255, 255, .8);
  transition: color var(--t-fast), background-color var(--t-base) var(--ease-out);
}
.site-nav a:hover, .site-nav a[aria-current] { color: var(--white); background: rgba(255, 255, 255, .12); }
.is-scrolled .site-nav a { color: var(--on-black-2); }
.is-scrolled .site-nav a:hover, .is-scrolled .site-nav a[aria-current] { color: var(--on-black); background: rgba(255, 255, 255, .1); }
/* With JS, the current-section highlight is one pill that travels between
   links instead of jumping, so the bar shows where you are moving to */
.site-nav__pill {
  position: absolute; top: 0; left: 0; z-index: 0; border-radius: 999px; background: rgba(255, 255, 255, .1);
  opacity: 0; pointer-events: none;
  transition: transform 460ms var(--ease-out), width 460ms var(--ease-out), opacity var(--t-base) var(--ease-out);
}
.site-nav__pill.is-on { opacity: 1; }
.site-nav.has-pill ul { z-index: 1; }
.site-nav.has-pill a[aria-current], .site-nav.has-pill a[aria-current]:hover { background: transparent; }

.site-header__actions { display: flex; align-items: center; gap: .375rem; }
.site-header__actions .btn { --bg: var(--white); --fg: var(--ink); }
.site-header__actions .btn:hover { --bg: #E6E6E4; }
.icon-btn, .menu-toggle {
  display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: 50%;
  transition: background-color var(--t-base) var(--ease-out);
}
.icon-btn .icon { width: 1.25rem; height: 1.25rem; }
.icon-btn:hover, .menu-toggle:hover { background: rgba(255, 255, 255, .12); }

html:not(.js) .menu-toggle { display: none !important; }
.menu-toggle { display: none; }
.menu-toggle__bars { display: grid; gap: 5px; width: 1.15rem; }
.menu-toggle__bars span { display: block; height: 1.5px; border-radius: 2px; background: currentColor; transition: transform var(--t-slow) var(--ease-out); }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars span:first-child { transform: translateY(3.25px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars span:last-child { transform: translateY(-3.25px) rotate(-45deg); }

/* Mobile menu: a white sheet with large links */
.mobile-menu {
  position: fixed; inset: 0; z-index: 90;
  display: flex; flex-direction: column; gap: 2rem;
  padding: calc(var(--header-h) + 2.5rem) var(--gutter) 2.5rem;
  overflow-y: auto; overscroll-behavior: contain;
  background: var(--white); color: var(--ink);
  opacity: 0; visibility: hidden;
  transition: opacity var(--t-base) var(--ease-out), visibility 0s linear var(--t-base);
}
.mobile-menu.is-open { opacity: 1; visibility: visible; transition: opacity var(--t-slow) var(--ease-out), visibility 0s; }
.mobile-menu li + li { border-top: 1px solid var(--line); }
.mobile-menu nav a { display: flex; align-items: center; min-height: 3.75rem; padding-block: .5rem; font-size: clamp(1.75rem, 7vw, 2.25rem); font-weight: 500; letter-spacing: -.035em; }
.mobile-menu nav li { opacity: 0; transform: translateY(.75rem); transition: opacity var(--t-slow) var(--ease-out), transform var(--t-slow) var(--ease-out); }
.mobile-menu.is-open nav li { opacity: 1; transform: none; }
.mobile-menu.is-open nav li:nth-child(2) { transition-delay: 40ms; }
.mobile-menu.is-open nav li:nth-child(3) { transition-delay: 80ms; }
.mobile-menu.is-open nav li:nth-child(4) { transition-delay: 120ms; }
.mobile-menu__actions { display: grid; gap: .5rem; }
.mobile-menu__actions .btn { width: 100%; }
.mobile-menu__foot { color: var(--ink-2); font-size: var(--fs-small); }
html.menu-open { overflow: hidden; }
.menu-open .site-header__actions .btn, .menu-open .site-header__actions .icon-btn { visibility: hidden; }

/* ---------- Photographs in rounded frames ---------- */
.photo-card { position: relative; margin: 0; overflow: hidden; border-radius: var(--r-panel); background: var(--card-2); }
.photo-card > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.photo-card__caption {
  position: absolute; left: 1rem; bottom: 1rem; max-width: calc(100% - 2rem);
  padding: .5rem .9rem; border-radius: 999px; background: rgba(10, 10, 10, .78); color: var(--on-black);
  font-size: .8125rem; line-height: 1.35;
}

/* A white card that sits on a photograph or a photographic ground */
.id-card {
  position: absolute; left: 1rem; bottom: 1rem; z-index: 1;
  display: grid; gap: .1rem; padding: .85rem 1.15rem .9rem;
  border-radius: 1rem; background: var(--white);
  box-shadow: 0 16px 40px -18px rgba(0, 0, 0, .45);
}
.id-card__name { font-size: .9375rem; font-weight: 600; letter-spacing: -.01em; }
.id-card__role { font-size: .8125rem; color: var(--ink-2); }
.id-card__status { margin-top: .5rem; font-family: var(--mono); font-size: .6875rem; letter-spacing: .06em; text-transform: uppercase; }

/* ---------- Hero: one photograph edge to edge ---------- */
.hero { padding: var(--inset); }
.hero__frame {
  position: relative; isolation: isolate; overflow: hidden;
  display: grid; grid-template-rows: minmax(0, 1fr) auto;
  min-height: max(36rem, calc(100svh - 2 * var(--inset)));
  border-radius: var(--r-panel); background: var(--night); color: var(--on-black);
}
.hero__media { position: absolute; inset: 0; z-index: -2; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 0%; }
/* Shade the curtain side for the text and the bottom edge for the facts */
.hero__frame::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(8, 24, 28, 0) 30%, rgba(8, 24, 28, .5) 62%, rgba(8, 24, 28, .72) 100%),
    linear-gradient(0deg, rgba(6, 20, 24, .62) 0%, rgba(6, 20, 24, 0) 32%),
    linear-gradient(180deg, rgba(6, 20, 24, .45) 0%, rgba(6, 20, 24, 0) 22%);
}
.hero__frame::after { content: ""; position: absolute; inset: 0; z-index: -1; background-image: var(--grain); background-size: 160px; opacity: .12; mix-blend-mode: overlay; pointer-events: none; }
.hero__content {
  align-self: center; justify-self: end;
  width: min(34rem, 44%);
  margin-right: max(calc(var(--gutter) - var(--inset)), calc((100vw - var(--container)) / 2 + var(--gutter) - var(--inset)));
  padding-block: calc(var(--header-h) + 2rem) 2rem;
}
.hero__title { font-family: var(--serif); font-size: var(--fs-hero); font-weight: 340; line-height: 1.04; letter-spacing: -.022em; color: var(--white); }
.hero__line { display: block; }
.hero__lead { margin-top: 1.25rem; max-width: 26rem; font-size: var(--fs-lead); line-height: 1.5; color: rgba(255, 255, 255, .84); }
.hero__actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 2rem; }
.hero__facts {
  display: flex; justify-content: center; flex-wrap: wrap; gap: .5rem 0;
  padding: 1.25rem var(--gutter) 1.4rem;
  font-family: var(--mono); font-size: .6875rem; letter-spacing: .08em; text-transform: uppercase; color: rgba(255, 255, 255, .82);
}
.hero__facts li { display: inline-flex; align-items: center; gap: .55rem; padding-inline: 1.25rem; }
.hero__facts li + li { border-left: 1px solid rgba(255, 255, 255, .28); }
.hero__facts .icon { width: 1rem; height: 1rem; }

/* ---------- Sections ---------- */
.section { padding-block: var(--section); }

/* Intro: centred text beside the portrait */
.intro__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2.5rem clamp(2rem, 6vw, 6rem); align-items: center; }
.intro__text { display: flex; flex-direction: column; align-items: center; text-align: center; }
.intro__text .lead { margin-top: 1.5rem; max-width: 30rem; color: var(--ink-2); }
.intro__text .btn { margin-top: 2rem; }
.intro__media { aspect-ratio: 1 / 1.08; }
.intro__media > img { object-position: 50% 16%; }

/* Why: the one figure, drawn as a ruler of a hundred patients. Ink for the
   30 that hold for every tumour, sand for the 31 to 85 that depend on the
   tumour type, the rest left grey. Kept to one row under the headline. */
.why { padding-block: clamp(4rem, 7vw, 6rem); background: var(--band); }
.why__head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 1.5rem clamp(2rem, 6vw, 6rem); align-items: end; }
.why .h2 { max-width: 23ch; }
.why__lead { max-width: 24rem; color: var(--ink-2); }
.why__figure {
  --tick-0: #C2D3D8; --tick-1: var(--night); --tick-2: var(--mist);
  display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); grid-template-areas: "text chart" ". source";
  gap: 1.25rem clamp(2rem, 5vw, 5rem); align-items: end;
  margin-top: clamp(2.5rem, 4.5vw, 3.5rem); padding-top: clamp(2rem, 3.5vw, 2.75rem);
  border-top: 1px solid var(--line-strong);
}
.why__text { grid-area: text; }
.why__value { font-family: var(--serif); font-size: clamp(3.5rem, 2rem + 3.4vw, 5rem); font-weight: 300; line-height: .86; letter-spacing: -.04em; white-space: nowrap; }
.why__pct { margin-left: .06em; font-size: .58em; letter-spacing: -.02em; }
.why__caption { margin-top: 1rem; max-width: 20rem; line-height: 1.45; }
.why__chart { grid-area: chart; }
.why__marks { display: grid; grid-template-columns: 30fr 55fr 15fr; align-items: end; margin-bottom: .75rem; font-size: .8125rem; line-height: 1.3; }
.why__mark { --c: var(--tick-1); position: relative; margin-inline: 1px; padding: 0 .5rem .5rem 0; border-bottom: 1px solid var(--c); }
.why__mark--max { --c: var(--tick-2); padding-left: .5rem; }
.why__mark::before, .why__mark::after { content: ""; position: absolute; top: 100%; left: -1px; width: 1px; height: .375rem; background: var(--c); }
.why__mark::after { left: auto; right: -1px; }
.why__ticks { display: grid; grid-template-columns: repeat(100, minmax(0, 1fr)); gap: clamp(1px, .3vw, 4px); height: clamp(2.75rem, 5vw, 4.25rem); }
.why__ticks i { --c: var(--tick-0); border-radius: 999px; background: var(--c); transform-origin: 50% 100%; }
.why__ticks i:nth-child(-n+30) { --c: var(--tick-1); }
.why__ticks i:nth-child(n+31):nth-child(-n+85) { --c: var(--tick-2); }
.why__axis { position: relative; height: 1rem; margin-top: .625rem; font-family: var(--mono); font-size: .6875rem; line-height: 1rem; color: var(--ink-2); }
.why__axis span { position: absolute; top: 0; left: calc(var(--at) * 1%); transform: translateX(-50%); }
.why__axis span:first-child { transform: none; }
.why__axis span:last-child { left: auto; right: 0; transform: none; }
.why__source { grid-area: source; font-size: .8125rem; color: var(--ink-2); }

/* Moments */
.moments .h2 { margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.moments__list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.moment { display: flex; flex-direction: column; padding: .5rem .5rem 1.5rem; border-radius: var(--r-card); background: var(--card); }
.moment__thumb { display: grid; place-items: center; height: 7.5rem; border-radius: calc(var(--r-card) - .5rem); color: var(--white); }
.moment__thumb .icon { width: 2rem; height: 2rem; }
/* Light grounds take an ink line instead of a white one */
.moment__thumb.mat--sand, .moment__thumb.mat--sky { color: var(--ink); }
.moment h3 { margin: 1.25rem 1rem 0; font-size: var(--fs-h3); font-weight: 500; letter-spacing: -.02em; line-height: 1.25; }
.moment p { margin: .5rem 1rem 0; font-size: var(--fs-small); color: var(--ink-2); }

/* Consultation: three rows */
.consult { padding-top: 0; }
.consult__head { display: flex; flex-direction: column; align-items: center; gap: 2rem; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.features { display: grid; gap: var(--gap); counter-reset: step; }
.feature { counter-increment: step; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: .5rem; padding: .5rem; border-radius: var(--r-panel); background: var(--panel); }
.feature__text { display: flex; flex-direction: column; padding: clamp(1.25rem, 3vw, 2.25rem); }
/* The step count sits at the foot of the text column (the h3 already says "Paso n" to screen readers) */
.feature__text::after { content: counter(step, decimal-leading-zero) " / 03" / ""; margin-top: auto; padding-top: 2rem; font-family: var(--mono); font-size: .75rem; letter-spacing: .06em; color: var(--ink-2); }
.feature__text h3 { font-size: clamp(1.375rem, 1.2rem + .6vw, 1.75rem); font-weight: 500; letter-spacing: -.025em; line-height: 1.15; }
.feature__text p { margin-top: .75rem; max-width: 24rem; color: var(--ink-2); }
.feature__visual {
  display: grid; place-items: center; min-height: clamp(19rem, 27vw, 24rem);
  padding: clamp(1.25rem, 3vw, 2.5rem); border-radius: calc(var(--r-panel) - .5rem);
}

.ui-card {
  width: min(100%, 21rem); padding: 1.1rem 1.15rem 1.2rem;
  border-radius: 1rem; background: var(--white); color: var(--ink);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .55);
}
.ui-card__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; }
.ui-card__icon { display: grid; place-items: center; flex: none; width: 2.25rem; height: 2.25rem; border-radius: 50%; background: var(--card); }
.ui-card__icon .icon { width: 1.1rem; height: 1.1rem; }
.ui-card__title { font-size: .9375rem; font-weight: 600; letter-spacing: -.01em; }
.ui-card__sub { font-size: .8125rem; color: var(--ink-2); }
.ui-list { display: grid; gap: .7rem; margin-top: 1rem; }
.ui-list li { display: grid; grid-template-columns: 2.25rem minmax(0, 1fr) auto; align-items: center; gap: .75rem; margin: -.3rem; padding: .3rem; border-radius: .8rem; font-size: .875rem; line-height: 1.3; }
.ui-list b { display: block; font-weight: 500; }
.ui-list small { display: block; font-size: .75rem; color: var(--ink-2); }
.ui-thumb { display: grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: .55rem; color: var(--white); }
.ui-thumb .icon { width: 1.125rem; height: 1.125rem; }
/* Light grounds take an ink line instead of a white one */
.ui-thumb.mat--sand, .ui-thumb.mat--sky { color: var(--ink); }
.ui-tick { display: grid; place-items: center; width: 1.375rem; height: 1.375rem; border-radius: 50%; background: var(--petrol); color: var(--white); }
.ui-tick .icon { width: .8rem; height: .8rem; }
.ui-bars { display: grid; gap: .8rem; margin-top: 1.1rem; }
.ui-bars span { display: grid; gap: .35rem; font-size: .8125rem; }
.ui-bars i { font-style: normal; font-weight: 500; }
.ui-bars span::after { content: ""; height: .5rem; border-radius: 999px; background: linear-gradient(var(--c), var(--c)) 0 0 / calc(var(--v) * 100%) 100% no-repeat, var(--card); }

/* ---------- Results on black: the BIA scene ---------- */
.results { background: var(--night); color: var(--on-black); padding-block: var(--section); }
.bia {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); grid-template-areas: "text demo" "reveal demo";
  gap: 2rem clamp(2rem, 6vw, 6rem); align-items: center;
}
.bia__text { grid-area: text; }
.bia__text p { margin-top: 1.5rem; max-width: 30rem; color: var(--on-black-2); }
.bia__text strong { color: var(--on-black); }
.bia-demo { grid-area: demo; }
.bia__reveal {
  grid-area: reveal; align-self: start; display: none; max-width: 24rem;
  font-size: var(--fs-lead); line-height: 1.4; color: var(--on-black-2);
  opacity: var(--reveal, 1); transform: translateY(calc((1 - var(--reveal, 1)) * .75rem));
}
.bia__reveal b { display: block; margin-bottom: .5rem; font-family: var(--serif); font-size: clamp(3.25rem, 2rem + 4.2vw, 5.5rem); font-weight: 400; letter-spacing: -.035em; line-height: 1; color: var(--on-black); }
.bia[data-state="b"] .bia__reveal { display: block; animation: fade-in var(--t-slow) var(--ease-out); }
.bia[data-state="b"] .bia__text, .bia--scrub .bia__text { align-self: end; }

/* Scroll-played version: the weight holds while three months pass under the reader's thumb */
.bia--scrub .bia__reveal { display: block; animation: none; }
/* The switch thumb snaps with the state (not with the scroll) so a label never sits half on black, half on grey */
.bia--scrub .bia-demo__thumb { transition: transform var(--t-base) var(--ease-out); }
.bia--scrub .metric__fill { transition: none; }
.bia--scrub .metric__delta { display: inline-block; animation: none; opacity: min(1, calc(var(--t, 0) * 6)); }
.bia--scrub .metric__ghost { transition: none; opacity: calc(min(1, calc(var(--t, 0) * 6)) * .55); }
.bia-track.is-pinned .bia { position: sticky; top: calc(var(--header-h) + 1.5rem); }

.bia-demo { --ring: var(--petrol); padding: clamp(1.5rem, 3vw, 2.25rem); border-radius: var(--r-panel); background: var(--white); color: var(--ink); }
.bia-demo__title { font-size: 1.0625rem; font-weight: 500; letter-spacing: -.01em; }
.bia-demo__switch { display: none; }
.bia-demo__visual { display: none; }
.bia-demo__table { width: 100%; margin-top: 1rem; font-size: var(--fs-small); }
.bia-demo__table caption { text-align: left; font-weight: 500; padding-bottom: .5rem; }
.bia-demo__table th, .bia-demo__table td { padding: .6rem .5rem; border-bottom: 1px solid var(--line); text-align: right; font-variant-numeric: tabular-nums; }
.bia-demo__table th:first-child, .bia-demo__table td:first-child { text-align: left; }
.bia-demo__table thead th { font-size: .8125rem; color: var(--ink-2); font-weight: 500; }
.bia-demo__note { margin-top: 1.25rem; font-size: .875rem; color: var(--ink-2); }

.bia-demo--live .bia-demo__switch {
  position: relative; display: grid; grid-template-columns: 1fr 1fr; margin-top: 1.1rem; padding: .3rem;
  border-radius: 999px; background: var(--card);
}
.bia-demo__switch button { position: relative; z-index: 1; min-height: 2.75rem; padding: .5rem .9rem; white-space: nowrap; border-radius: 999px; font-size: .9375rem; font-weight: 500; color: var(--ink-2); transition: color var(--t-base) var(--ease-out); }
.bia-demo__switch button[aria-pressed="true"] { color: var(--white); }
.bia-demo__thumb { position: absolute; z-index: 0; top: .3rem; bottom: .3rem; left: .3rem; width: calc(50% - .3rem); border-radius: 999px; background: var(--petrol); transition: transform var(--t-slow) var(--ease-out); }
.bia[data-state="b"] .bia-demo__thumb { transform: translateX(100%); }
.bia-demo--live .bia-demo__visual { display: block; margin-top: 1.5rem; }
.bia-demo--live .bia-demo__data { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; margin: -1px; }

.scale { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding-bottom: 1.1rem; border-bottom: 1px solid var(--line); }
.scale__label { font-size: var(--fs-small); color: var(--ink-2); }
.scale__value { font-size: clamp(2.25rem, 1.8rem + 1.4vw, 3rem); font-weight: 300; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.scale__value small { margin-left: .2em; font-family: var(--mono); font-size: .32em; font-weight: 500; letter-spacing: 0; color: var(--ink-2); }
.scale__same { display: inline-flex; align-items: center; gap: .4rem; margin-top: .6rem; font-family: var(--mono); font-size: .6875rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); }

.metric { margin-top: 1.25rem; }
.metric__row { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.metric__name { display: inline-flex; align-items: center; gap: .55rem; font-weight: 500; }
.metric__swatch { width: .7rem; height: .7rem; border-radius: 3px; background: var(--c); }
.metric__value { font-variant-numeric: tabular-nums; font-weight: 500; }
.metric__delta { display: none; min-width: 4.4em; margin-left: .5rem; font-family: var(--mono); font-size: .75rem; text-align: right; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.bia[data-state="b"] .metric__delta { display: inline-block; animation: fade-in var(--t-slow) var(--ease-out); }
.metric__track { position: relative; height: .625rem; margin-top: .55rem; border-radius: 999px; background: var(--card); overflow: hidden; }
.metric__fill { position: absolute; inset: 0; border-radius: inherit; background: var(--c); transform-origin: left; transform: scaleX(var(--v, 0)); transition: transform 900ms var(--ease-out); }
.metric__ghost { position: absolute; top: -2px; bottom: -2px; width: 2px; left: calc(var(--g, 0) * 100%); background: var(--ink); opacity: 0; transition: opacity var(--t-base); }
.bia[data-state="b"] .metric__ghost { opacity: .55; }

/* ---------- About ---------- */
.about__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2.5rem clamp(2rem, 6vw, 6rem); align-items: center; }
.about__text .lead { margin-top: 1.75rem; }
.about__text > p:not(.lead) { margin-top: 1rem; color: var(--ink-2); }
.about__text .links-row { margin-top: 1.75rem; }
.about__media { aspect-ratio: 1 / 1; }
.about__media > img { object-position: 30% 50%; }
.creds { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); margin-top: clamp(2.5rem, 5vw, 4rem); }
.cred { display: flex; flex-direction: column; gap: .3rem; padding: 1.25rem 1.35rem 1.35rem; border-radius: var(--r-card); background: var(--card); }
.cred b { font-weight: 500; letter-spacing: -.01em; line-height: 1.3; }
.cred span { font-size: .875rem; color: var(--ink-2); }
/* Each card opens with the institution's logo, in one ink so the four sit
   together as a set (No-Accent Rule). The files are single-colour shapes
   used as masks (set per logo, not through a variable, so the url resolves from this file); each logo has its own height so their weight evens out. */
.cred__brand { display: flex; align-items: center; height: 3.5rem; margin-bottom: 1.5rem; }
.cred__logo {
  display: block; height: calc(var(--h) * var(--k, 1)); aspect-ratio: var(--ar); max-width: 100%;
  background: var(--ink-2);
  -webkit-mask: no-repeat 0 50% / contain; mask: no-repeat 0 50% / contain;
}
.cred__logo--iob { -webkit-mask-image: url("../assets/logos/iob.png"); mask-image: url("../assets/logos/iob.png"); --ar: 2.2; --h: 1.75rem; }
.cred__logo--vhio { -webkit-mask-image: url("../assets/logos/vhio.png"); mask-image: url("../assets/logos/vhio.png"); --ar: 1.417; --h: 3.5rem; }
.cred__logo--uab { -webkit-mask-image: url("../assets/logos/uab.svg"); mask-image: url("../assets/logos/uab.svg"); --ar: 2.664; --h: 2.6rem; }
.cred__logo--ub { -webkit-mask-image: url("../assets/logos/ub.svg"); mask-image: url("../assets/logos/ub.svg"); --ar: 2.099; --h: 3.5rem; }
@media (forced-colors: active) { .cred__logo { background: CanvasText; forced-color-adjust: none; } }

/* ---------- Outreach ---------- */
.outreach { padding-top: 0; }
.outreach .h2 { margin-bottom: clamp(2.5rem, 5vw, 3.5rem); }
.meta { font-size: .875rem; color: var(--ink-2); }
.bento { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }

.photo-tile {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; flex-direction: column; justify-content: flex-end; min-height: 26rem;
  padding: 1.5rem; border-radius: var(--r-panel); background: #20140F; color: var(--white);
}
.photo-tile > img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 28% 40%; transition: transform 900ms var(--ease-out); }
.photo-tile::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(0deg, rgba(10, 8, 6, .78) 0%, rgba(10, 8, 6, .2) 42%, rgba(10, 8, 6, 0) 60%); }
.photo-tile h3 { font-size: 1.375rem; font-weight: 500; letter-spacing: -.02em; line-height: 1.2; max-width: 16ch; }
.photo-tile__meta { margin-top: .4rem; font-size: .875rem; color: rgba(255, 255, 255, .8); }
.photo-tile__go { position: absolute; top: 1rem; right: 1rem; display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 50%; background: var(--white); color: var(--ink); }
.photo-tile__go .icon { transition: transform var(--t-base) var(--ease-out); }
.photo-tile:hover > img { transform: scale(1.03); }
.photo-tile:hover .photo-tile__go .icon { transform: translate(2px, -2px); }
.stretched::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.photo-tile:focus-within { outline: 2px solid var(--petrol); outline-offset: 3px; }
.photo-tile .stretched:focus-visible { outline: none; }

.media-item { display: flex; flex-direction: column; padding: .5rem; border-radius: var(--r-panel); background: var(--card); }
.media-item .visual { aspect-ratio: 16 / 9; border-radius: calc(var(--r-panel) - .5rem); }
.media-item .visual img { object-position: 50% 30%; }
.media-item__body { display: flex; flex-direction: column; gap: .4rem; flex: 1; padding: 1.25rem 1rem 1rem; }
.media-item h3 { font-size: 1.1875rem; font-weight: 500; letter-spacing: -.02em; line-height: 1.25; }
.media-item__links { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: auto; padding-top: 1.1rem; }

.visual { position: relative; overflow: hidden; background: var(--card-2); }
.visual img { width: 100%; height: 100%; object-fit: cover; transition: transform 900ms var(--ease-out); }
.media-item:hover .visual img { transform: scale(1.03); }
.visual iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; animation: fade-in var(--t-slow) var(--ease-out); }
.video:not(.is-playing) { cursor: pointer; }
@keyframes fade-in { from { opacity: 0; } }

.press { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); margin-top: var(--gap); }
.press a {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .35rem 1rem; align-items: start; height: 100%;
  padding: 1.25rem 1.25rem 1.25rem 1.5rem; border-radius: var(--r-card); background: var(--card);
  transition: background-color var(--t-base) var(--ease-out);
}
.press a:hover { background: var(--card-2); }
.press__title { font-weight: 500; letter-spacing: -.01em; line-height: 1.35; }
.press__src { grid-column: 1; font-size: .875rem; color: var(--ink-2); }
.press__go { grid-column: 2; grid-row: 1 / span 2; display: grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: 50%; background: var(--white); }
.press__go .icon { transition: transform var(--t-base) var(--ease-out); }
.press a:hover .press__go .icon { transform: translate(2px, -2px); }

/* Instagram: a card-grey panel; the profile row always, the six latest
   posts once a feed is configured and loaded */
.insta { margin-top: var(--gap); padding: .5rem; border-radius: var(--r-panel); background: var(--card); }
.insta__head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: .75rem .75rem .75rem 1rem; }
.insta__id { display: flex; align-items: center; gap: .9rem; min-width: 0; }
.insta__avatar { display: grid; place-items: center; flex: none; width: 3rem; height: 3rem; overflow: hidden; border-radius: 50%; background: var(--night); color: var(--white); }
.insta__avatar .icon { width: 1.35rem; height: 1.35rem; }
.insta__avatar img { width: 100%; height: 100%; object-fit: cover; }
.insta__name { display: block; font-weight: 500; letter-spacing: -.01em; overflow-wrap: anywhere; }
.insta__meta { display: block; font-size: .875rem; color: var(--ink-2); }
.insta__grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: .5rem; padding-top: .25rem; }
.insta__grid a, .insta__skel {
  position: relative; display: block; aspect-ratio: 1 / 1; overflow: hidden;
  border-radius: calc(var(--r-panel) - .5rem); background: var(--card-2);
}
.insta__grid img { width: 100%; height: 100%; object-fit: cover; transition: transform 900ms var(--ease-out), opacity var(--t-slow) var(--ease-out); }
.insta__grid img:not(.is-in) { opacity: 0; }
.insta__grid a:hover img { transform: scale(1.04); }
.insta__grid a:focus-visible { outline-offset: 2px; }
.insta__badge { position: absolute; top: .5rem; right: .5rem; display: grid; place-items: center; width: 1.75rem; height: 1.75rem; border-radius: 50%; background: rgba(10, 10, 10, .55); color: var(--white); }
.insta__badge .icon { width: .9rem; height: .9rem; }
.insta__skel { animation: skel 1.4s ease-in-out infinite alternate; }
@keyframes skel { to { background: var(--card); } }

/* ---------- FAQ ---------- */
.faq { padding-top: 0; }
.faq__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 2rem clamp(2rem, 6vw, 6rem); align-items: start; }
.faq__list { display: grid; gap: .5rem; }
.faq__item { border-radius: var(--r-card); background: var(--card); }
.faq__item summary {
  display: flex; justify-content: space-between; align-items: center; gap: 1.25rem;
  min-height: 3.5rem; padding: 1.1rem 1.1rem 1.1rem 1.5rem; cursor: pointer; list-style: none;
  font-size: 1.0625rem; font-weight: 500; letter-spacing: -.01em; line-height: 1.4;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary .icon { display: grid; place-items: center; width: 2.25rem; height: 2.25rem; padding: .5rem; border-radius: 50%; background: var(--white); transition: transform var(--t-slow) var(--ease-out), background-color var(--t-base), color var(--t-base); }
.faq__item summary:hover .icon { background: var(--card-2); }
.faq__item[open] summary .icon { transform: rotate(45deg); background: var(--petrol); color: var(--white); }
.faq__item::details-content { block-size: 0; overflow: clip; transition: block-size var(--t-slow) var(--ease-out), content-visibility var(--t-slow) allow-discrete; }
.faq__item[open]::details-content { block-size: auto; }
.faq__answer { padding: 0 4.5rem 1.5rem 1.5rem; color: var(--ink-2); }

/* ---------- Final call: the hero photograph again, defocused ---------- */
.final { padding: 0 var(--inset) var(--inset); }
.final__frame {
  position: relative; isolation: isolate; overflow: hidden;
  padding: clamp(5rem, 11vw, 9rem) var(--gutter);
  border-radius: var(--r-panel); background: var(--night); color: var(--on-black); text-align: center;
}
.final__bg { position: absolute; inset: 0; z-index: -2; }
.final__bg img { position: absolute; inset: -12%; width: 124%; height: 124%; max-width: none; object-fit: cover; object-position: 50% 30%; filter: blur(42px) grayscale(1) contrast(.85) brightness(1.25); }
/* The defocused photo becomes a petrol duotone: its light reads as a glow
   between night and petrol, so white type holds at 8:1 or more */
.final__frame::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--petrol); mix-blend-mode: multiply; }
.final__frame::after { content: ""; position: absolute; inset: 0; z-index: -1; background-image: var(--grain); background-size: 160px; opacity: .14; mix-blend-mode: overlay; pointer-events: none; }
.final__title { margin-inline: auto; max-width: 22ch; font-family: var(--serif); font-size: clamp(2.6rem, 1.6rem + 3.4vw, 4.5rem); font-weight: 340; line-height: 1.02; letter-spacing: -.025em; color: var(--white); }
.final__line { display: block; }
.final__soft { color: rgba(255, 255, 255, .62); }
.final__content > p { margin: 1.5rem auto 0; max-width: 32rem; color: rgba(255, 255, 255, .84); }
.final__actions { display: flex; justify-content: center; flex-wrap: wrap; gap: .5rem; margin-top: 2.25rem; }
.final__content .final__where { margin-top: 2rem; max-width: 40rem; font-size: .875rem; color: rgba(255, 255, 255, .72); }

/* ---------- Footer ---------- */
.site-footer { --mark-1: var(--on-black); margin: 0 var(--inset) var(--inset); border-radius: var(--r-panel); background: var(--night); color: var(--on-black); padding: clamp(3.5rem, 7vw, 6rem) 0 2rem; }
.footer-top { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1.3fr) minmax(0, .7fr); gap: 2rem var(--gutter); }
.footer-col p, .footer-col li { font-size: var(--fs-small); color: var(--on-black-2); }
.footer-col .footer-brand { display: flex; align-items: center; gap: .65rem; font-size: 1.125rem; font-weight: 600; letter-spacing: -.03em; color: var(--on-black); }
.footer-brand .brand__mark { width: 1.67rem; height: 1.6rem; }
.footer-col--brand p + p { margin-top: .5rem; }
.footer-col h3 { margin-bottom: .75rem; font-size: .875rem; font-weight: 500; color: var(--on-black); }
.footer-col a { display: inline-flex; align-items: center; gap: .5rem; min-height: 2.75rem; transition: color var(--t-fast); }
.footer-mail { overflow-wrap: anywhere; }
.footer-col a:hover { color: var(--on-black); }
.footer-disclaimer { margin-top: 3rem; max-width: 46rem; font-size: .875rem; color: var(--on-black-2); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-top: 2rem; padding-top: 1.25rem; border-top: 1px solid var(--line-dark); font-size: .875rem; color: var(--on-black-2); }
.footer-bottom ul { display: flex; gap: .25rem 1.5rem; flex-wrap: wrap; }
.footer-bottom a { display: inline-flex; align-items: center; gap: .4rem; min-height: 2.75rem; transition: color var(--t-fast); }
.footer-bottom a:hover { color: var(--on-black); }

/* ---------- Legal pages ---------- */
.legal-header { position: sticky; top: 0; z-index: 10; border-bottom: 1px solid var(--line); background: var(--white); }
.legal-header .site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: var(--header-h); }
.legal-back { display: inline-flex; align-items: center; gap: .45rem; min-height: 2.75rem; padding-inline: 1rem; border-radius: 999px; background: var(--card); font-size: .9375rem; font-weight: 500; white-space: nowrap; transition: background-color var(--t-base); }
.legal-back:hover { background: var(--card-2); }
.legal { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
.legal__inner { max-width: 40rem; }
.legal h1 { margin-bottom: 2.25rem; font-family: var(--serif); font-size: clamp(2.6rem, 1.5rem + 4vw, 4.5rem); font-weight: 340; letter-spacing: -.025em; line-height: 1.02; }
.legal h2 { margin: 3rem 0 1rem; padding-top: 1.5rem; border-top: 1px solid var(--line); font-size: clamp(1.4rem, 1.15rem + .8vw, 1.85rem); font-weight: 500; letter-spacing: -.025em; line-height: 1.2; }
.legal p, .legal li { color: var(--ink-2); }
.legal p + p, .legal ul { margin-top: 1rem; }
.legal ul { list-style: disc; padding-left: 1.25rem; }
.legal li + li { margin-top: .4rem; }
.legal a { color: var(--ink); font-weight: 500; text-decoration: underline; text-underline-offset: .22em; text-decoration-color: var(--line-strong); }
.legal a:hover { text-decoration-color: currentColor; }
.legal mark { background: var(--beige-2); color: var(--ink); padding: 0 .25em; border-radius: 3px; }
.legal-notice { padding: 1rem 1.25rem; border-radius: var(--r-card); background: var(--beige); font-size: var(--fs-small); }
.legal-next { margin-top: 3.5rem !important; }
.legal a.link-arrow { display: inline-flex; align-items: center; gap: .45rem; min-height: 2.75rem; text-decoration: none; }
.legal-footer { --mark-1: var(--on-black); padding-block: 1.5rem; background: var(--night); color: var(--on-black-2); }
.legal-footer .footer-bottom { margin-top: 0; padding-top: 0; border-top: 0; }

/* ==========================================================================
   Motion: the hero photograph settling, the header turning into a floating
   bar, the white cards rising onto their grounds as they enter, and the BIA
   scene; quiet feedback elsewhere.
   ========================================================================== */
@media (prefers-reduced-motion: no-preference) {
  .hero__media img { animation: settle 1800ms var(--ease-out) both; }
  .hero__line { animation: line-up 1000ms var(--ease-out) 200ms both; }
  .hero__line + .hero__line { animation-delay: 320ms; }
  .hero__content > :not(h1) { animation: rise 800ms var(--ease-out) 560ms both; }
  .hero__content > :nth-child(3) { animation-delay: 660ms; }
  .hero__facts { animation: fade-in 900ms var(--ease-out) 900ms both; }

  /* The ruler sweeps in once as it scrolls into view: the 30 ink ticks rise
     first, a beat, then the sand up to 85; each bracket draws after its run */
  .why__chart.is-armed i { transition: transform 620ms var(--ease-out), background-color 420ms var(--ease-out); transition-delay: var(--d, 0ms); }
  .why__chart.is-armed:not(.is-in) i { background: var(--tick-0); transform: scaleY(.16); }
  .why__chart.is-armed .why__mark { clip-path: inset(-1rem -1rem -1rem 0); transition: clip-path 700ms var(--ease-out) 380ms, opacity 400ms var(--ease-out) 380ms; }
  .why__chart.is-armed .why__mark--max { transition-delay: 900ms; }
  .why__chart.is-armed:not(.is-in) .why__mark { opacity: 0; clip-path: inset(-1rem 100% -1rem 0); }

  /* The ribbon ties itself in the header as the page opens: from its left
     foot up, round the loop and down to the right, then the outer legs */
  .mark-tie path { animation: tie 1050ms cubic-bezier(.5, 0, .2, 1) 350ms backwards; }
  .mark-tie .mark-tie__leg { animation-duration: 760ms; animation-delay: 1000ms; }

  /* The closing call answers the hero: when it is reached, its two lines
     rise and unclip the way the opening statement did, then the rest */
  .final__content.is-armed:not(.is-in) .final__line, .final__content.is-armed:not(.is-in) > :not(h2) { opacity: 0; }
  .final__content.is-in .final__line { animation: line-up 1000ms var(--ease-out) both; }
  .final__content.is-in .final__line + .final__line { animation-delay: 140ms; }
  .final__content.is-in > :not(h2) { animation: rise 800ms var(--ease-out) 420ms both; }
  .final__content.is-in > .final__actions { animation-delay: 520ms; }
  .final__content.is-in > .final__where { animation-delay: 620ms; }

  /* Moving to the legal pages and back keeps the monogram in place while
     the page cross-fades */
  @view-transition { navigation: auto; }
  .site-header .brand__mark, .legal-header .brand__mark { view-transition-name: brand-mark; }
  ::view-transition-group(brand-mark) { animation-duration: 520ms; animation-timing-function: var(--ease-out); }
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: 260ms; }

  /* Each consultation card acts out its step once, as it comes into view:
     the first visit is ticked off item by item, the plan is put together
     piece by piece, and the follow-up bars are measured out */
  .feature__visual.is-armed .ui-tick { transition: background-color 320ms var(--ease-out) var(--d), box-shadow 320ms var(--ease-out) var(--d); }
  .feature__visual.is-armed .ui-tick .icon { clip-path: inset(-2px -2px -2px -2px); transition: clip-path 460ms var(--ease-out) calc(var(--d) + 140ms); }
  .feature__visual.is-armed:not(.is-in) .ui-tick { background: transparent; box-shadow: inset 0 0 0 1.5px var(--line-strong); }
  .feature__visual.is-armed:not(.is-in) .ui-tick .icon { clip-path: inset(-2px 100% -2px -2px); }
  .feature__visual.is-in .ui-list--check li { animation: row-pass 720ms ease-out calc(var(--d) - 260ms) both; }

  .feature__visual.is-armed .ui-list--plan li { transition: opacity 520ms var(--ease-out) var(--d), transform 640ms var(--ease-out) var(--d); }
  .feature__visual.is-armed .ui-list--plan .ui-thumb { transition: transform 640ms var(--ease-out) calc(var(--d) + 60ms); }
  .feature__visual.is-armed .ui-list--plan li > :nth-child(2) { clip-path: inset(-.4em -.4em -.4em 0); transition: clip-path 760ms var(--ease-out) calc(var(--d) + 120ms); }
  .feature__visual.is-armed:not(.is-in) .ui-list--plan li { opacity: 0; transform: translateY(.75rem); }
  .feature__visual.is-armed:not(.is-in) .ui-list--plan .ui-thumb { transform: scale(.55); }
  .feature__visual.is-armed:not(.is-in) .ui-list--plan li > :nth-child(2) { clip-path: inset(-.4em 100% -.4em 0); }

  .feature__visual.is-armed .ui-bars span::after { transition: background-size 1200ms var(--ease-out) var(--d); }
  .feature__visual.is-armed .ui-bars i { transition: opacity 420ms var(--ease-out) var(--d); }
  .feature__visual.is-armed:not(.is-in) .ui-bars span::after { background-size: 0% 100%, auto; }
  .feature__visual.is-armed:not(.is-in) .ui-bars i { opacity: 0; }

  /* The white cards rise onto their grounds as each row scrolls in */
  @supports (animation-timeline: view()) {
    .feature__visual .ui-card, .intro__media .id-card {
      animation: card-in linear both; animation-timeline: view(); animation-range: entry 0% entry 90%;
    }
    .moment__thumb, .feature__visual { animation: ground-in linear both; animation-timeline: view(); animation-range: entry 0% entry 100%; }
  }
}
@keyframes rise { from { opacity: 0; transform: translateY(1rem); } }
@keyframes row-pass { 0%, 100% { background-color: transparent; } 40% { background-color: var(--card); } }
@keyframes tie { from { stroke-dashoffset: 1; stroke-width: 8.6; } to { stroke-dashoffset: 0; stroke-width: 8.6; } }
@keyframes settle { from { transform: scale(1.08); } }
@keyframes line-up { from { opacity: 0; transform: translateY(.42em); clip-path: inset(0 0 100% 0); } to { clip-path: inset(-.25em -.1em -.25em -.1em); } }
@keyframes card-in { from { opacity: 0; transform: translateY(2.5rem) scale(.97); } }
@keyframes ground-in { from { background-position: 0 1.5rem, 0 -1.5rem, 0 0; } }

/* Reduced motion: keep state changes legible with short fades, drop travel */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero__line, .hero__content > :not(h1), .hero__facts { animation: fade-in 240ms ease-out both; }
  .site-header__bar { transition-duration: 1ms; }
  .bia-demo__thumb, .metric__fill { transition-duration: 1ms; }
  .site-nav__pill { transition: opacity var(--t-base) ease-out; }
  .mobile-menu nav li { transform: none; transition: opacity 180ms ease-out; }
  .media-item:hover .visual img, .photo-tile:hover > img, .insta__grid a:hover img { transform: none; }
  .insta__skel { animation: none; }
  .btn:active { transform: none; }
  .faq__item::details-content { transition-duration: 1ms; }
  .faq__item summary .icon { transition-duration: 1ms; }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1120px) {
  .site-nav { display: none; }
  .menu-toggle { display: inline-grid; }
}

@media (max-width: 1000px) {
  /* Hero: the portrait crop fills the frame, the words sit low over the
     dark floor of the stage */
  .hero__frame { min-height: max(34rem, calc(100svh - 2 * var(--inset))); }
  .hero__media img { object-position: 38% 0%; }
  .hero__frame::before {
    background:
      linear-gradient(0deg, rgba(6, 20, 24, .88) 0%, rgba(6, 20, 24, .66) 40%, rgba(6, 20, 24, .3) 62%, rgba(6, 20, 24, 0) 80%),
      linear-gradient(180deg, rgba(6, 20, 24, .5) 0%, rgba(6, 20, 24, 0) 18%);
  }
  .hero__content { align-self: end; justify-self: stretch; width: auto; margin: 0; padding: 0 var(--gutter) 1.5rem; }
  .hero__title { max-width: 15ch; }
  .hero__facts { justify-content: flex-start; padding-inline: calc(var(--gutter) - 1.25rem); padding-top: 0; }

  .intro__grid, .about__grid, .faq__grid, .bia { grid-template-columns: 1fr; }
  .intro__media { max-width: 36rem; width: 100%; margin-inline: auto; }
  .bia { grid-template-areas: "text" "demo" "reveal"; }
  .moments__list, .creds { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .why__head { grid-template-columns: 1fr; }
  .why__figure { grid-template-columns: 1fr; grid-template-areas: "text" "chart" "source"; row-gap: 1.75rem; }
  .why__text { display: flex; align-items: flex-end; gap: 1rem 2rem; }
  .why__caption { margin-top: 0; padding-bottom: .2rem; }
  .feature { grid-template-columns: 1fr; }
  .feature__text { padding-bottom: .5rem; }
  .feature__text::after { padding-top: 1.25rem; }
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .photo-tile { grid-column: 1 / -1; min-height: 0; aspect-ratio: 16 / 10; }
  .photo-tile > img { object-position: 28% 30%; }
  .press { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  :root { --header-h: 4rem; }
  /* The bar spans the frame: over the photograph its contents line up with
     the hero text; once floating it keeps an 8px margin to the screen edge */
  .site-header { padding-inline: var(--inset); }
  .site-header__bar { gap: .5rem; padding-inline: calc(var(--gutter) - var(--inset)) calc(var(--gutter) - var(--inset) - .625rem); }
  .site-header.is-scrolled .site-header__bar, .menu-open .site-header__bar { margin-top: var(--inset); padding-inline: .75rem .25rem; }
  .site-header__actions .icon-btn { display: none; }
  .hero__content { padding-inline: calc(var(--gutter) - var(--inset)); }
  .hero__actions { width: 100%; }
  .hero__actions .btn { flex: 1 1 100%; }
  /* On phones the fact strip becomes one quiet line of text under the
     buttons, as Everlab does: no icons, no mono, the VHIO role left to
     "Sobre mí" */
  .hero__facts {
    display: block; padding: 0 calc(var(--gutter) - var(--inset)) 1.4rem;
    font-family: var(--sans); font-size: .875rem; letter-spacing: 0; text-transform: none; color: rgba(255, 255, 255, .78);
  }
  .hero__facts li { display: inline; padding: 0; }
  .hero__facts li + li { border-left: 0; }
  .hero__facts .icon, .hero__facts li:nth-child(2) { display: none; }
  .hero__facts li:first-child::after { content: ","; }
  .hero__facts li:last-child { text-transform: lowercase; }
  .bento { grid-template-columns: 1fr; }
  .insta__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .insta__head .btn { width: 100%; }
  .photo-tile { aspect-ratio: 4 / 5; }
  .metric__delta { min-width: 3.4em; }
  .faq__item summary { font-size: 1rem; padding-left: 1.25rem; }
  .faq__answer { padding: 0 1.25rem 1.25rem; }
  .final__actions .btn { width: 100%; }
  .footer-top { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 600px) {
  .moments__list, .creds { grid-template-columns: 1fr; }
  .why__text { display: block; }
  .why__caption { margin-top: .875rem; padding-bottom: 0; }
  .why__marks { font-size: .75rem; }
  /* A moment becomes a row: the swatch beside the words */
  .moment { display: grid; grid-template-columns: 4.5rem minmax(0, 1fr); column-gap: 1rem; padding: .5rem 1rem .5rem .5rem; }
  .moment__thumb { grid-row: span 2; height: 100%; min-height: 4.5rem; }
  .moment__thumb .icon { width: 1.625rem; height: 1.625rem; }
  /* A credential becomes a row too: the logo beside the role */
  .cred { display: grid; grid-template-columns: 6rem minmax(0, 1fr); align-items: center; column-gap: 1.125rem; row-gap: .2rem; padding: 1rem 1.125rem; }
  .cred__brand { --k: .78; grid-row: span 2; height: 100%; min-height: 2.75rem; margin: 0; }
  .cred > b { align-self: end; }
  .cred > span:last-child { align-self: start; }
  .moment h3 { margin: .75rem 0 0; }
  .moment p { margin: .3rem 0 .75rem; }
  .cta-long { display: none; }
  .bia-demo__switch button { padding-inline: .5rem; font-size: .875rem; }
  .id-card { left: .75rem; bottom: .75rem; padding: .7rem .95rem .75rem; }
  .feature__visual { min-height: 17rem; padding: 1.25rem; }
  .legal-header .brand__tag { display: none; }
}

/* Below 360px the mark would squeeze the CTA and the 44px menu toggle;
   the name and the favicon carry the identity there. */
@media (max-width: 359px) {
  .site-header .brand__mark { display: none; }
}

@media (max-width: 380px) {
  :root { --gutter: 1rem; }
  .site-header .brand__tag { display: none; }
  .brand__name { font-size: 1.0625rem; }
  .site-header__bar { gap: .5rem; }
  .site-header .btn--sm { padding-inline: .9rem; font-size: .875rem; }
}

@media print {
  .site-header, .mobile-menu, .final__actions, .bia-demo__switch { display: none !important; }
  body { background: #fff; }
  .results, .site-footer, .hero__frame, .final__frame { background: #fff !important; color: #000 !important; }
  .hero__media, .final__bg { display: none; }
}
