/* ───────── Tokens ───────── */
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-var.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #ecf0f1;           /* page + loader curtain */
  --ink: #141414;             /* primary text */
  --muted: #8d8d8d;           /* numbers, meta */
  --line: rgba(20, 20, 20, .1);
  --card: #fbfbfb;
  --accent: #8443b6;          /* the purple from the original site */
  --accent-soft: #d980fa;
  --accent-ink: #fff;

  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --gutter: clamp(16px, 3.4vw, 48px);
  --card-w: 620px;
  --radius: 22px;

  /* Where the card comes to rest after the intro, from the top of the viewport. */
  --rest: 34svh;

  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-io: cubic-bezier(.76, 0, .24, 1);
  --t-rise: .95s;       /* per-line text rise */
  --t-stagger: .09s;
  --t-curtain: 1.05s;
  --t-card: 1.15s;
}

/* ───────── Base ───────── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.45;
  font-feature-settings: "ss01", "cv11"; /* Inter: open digits, single-storey a */
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; }
em { font-style: normal; color: var(--accent); }
.skip {
  position: absolute; left: 12px; top: -60px; z-index: 50; padding: 10px 14px;
  background: var(--ink); color: var(--paper); border-radius: 10px; text-decoration: none; font-weight: 700;
}
.skip:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ───────── Stage: sticky hero with the sheet travelling over it ─────────
   The hero is sticky inside .stage, which ends before the footer, so the hero
   releases there. The page scrollbar is the only scroll container. */
.stage { position: relative; }

.hero {
  position: sticky; top: 0; z-index: 0;
  height: 100vh; height: 100svh; overflow: hidden;
  background: #d9d3ec;
}
.hero__media, .hero__media img {
  position: absolute; inset: 0; width: 100%; height: 100%;
}
.hero__media img { object-fit: cover; object-position: 72% 30%; }

.curtain {
  display: none; position: absolute; inset: 0; z-index: 1; background: var(--paper);
}

.hero__type {
  position: absolute; inset: 0; z-index: 2; pointer-events: none;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(var(--gutter) + env(safe-area-inset-top, 0px)) var(--gutter) var(--gutter);
  text-transform: uppercase;
}
.hero__name {
  margin: 0; font-weight: 900; letter-spacing: -.045em; line-height: .86;
  /* sized so ANDREWS fits the left margin beside the centred card */
  font-size: clamp(46px, calc((100vw - var(--card-w)) / 9.6 - 14px), 112px);
}
.hero__title {
  margin: 0; font-weight: 800; letter-spacing: -.035em; line-height: .9;
  font-size: clamp(26px, 2.8vw, 54px);
}
.line { display: block; overflow: hidden; padding-bottom: .06em; margin-bottom: -.06em; }
.line__in { display: block; }

/* ───────── The sheet: ordinary flow, pulled back over the hero ───────── */
.sheet {
  position: relative; z-index: 2;
  margin-top: -100vh; margin-top: -100svh;
  padding: var(--rest) 16px 22svh;
  pointer-events: none; /* transparent area must not swallow clicks */
}
.card {
  pointer-events: auto;
  width: 100%; max-width: var(--card-w); margin: 0 auto;
  background: var(--card); border-radius: var(--radius); overflow: hidden;
  box-shadow: 0 30px 80px -30px rgba(40, 20, 70, .35), 0 2px 6px rgba(0, 0, 0, .04);
}

/* Profile block */
.profile {
  display: grid; grid-template-columns: 148px minmax(0, 1fr); gap: 22px;
  padding: 22px 22px 24px; align-items: start;
}
.profile__avatar {
  aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: #e6e3ea;
}
.avatar-stage { position: relative; width: 100%; height: 100%; transform-origin: 56% 40%; /* her face */ }
.avatar { display: block; width: 100%; height: 100%; object-fit: cover; }
.avatar--live {
  position: absolute; inset: 0; opacity: 0; transition: opacity .9s ease;
  pointer-events: none;
}
.avatar--live.is-live { opacity: 1; }

/* Portrait motion: a slow settle as the card lands, then a barely-there drift.
   Two animations on one property: the drift starts exactly where the settle ends (scale 1). */
.js .avatar-stage { transform: scale(1.16) translate(1.5%, 3%); }
.js.is-ready .avatar-stage {
  animation:
    portrait-settle 3.6s cubic-bezier(.33, 0, .2, 1) .5s both,
    portrait-drift 16s ease-in-out 4.1s infinite alternate;
}
@keyframes portrait-settle {
  from { transform: scale(1.16) translate(1.5%, 3%); filter: saturate(.85) brightness(1.04); }
  to   { transform: scale(1) translate(0, 0); filter: none; }
}
@keyframes portrait-drift {
  from { transform: scale(1) translate(0, 0); }
  to   { transform: scale(1.055) translate(-1.2%, -.8%); }
}
.profile__id { min-width: 0; }
.profile__name {
  margin: 4px 0 0; text-transform: uppercase; font-weight: 850; font-size: 22px;
  line-height: .95; letter-spacing: -.035em;
}
.profile__role {
  margin: 4px 0 0; text-transform: uppercase; font-weight: 800; font-size: 15px;
  line-height: 1; letter-spacing: -.02em; color: var(--muted);
}
.contact { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 6px; }
.contact__link {
  display: inline-flex; align-items: center; gap: 10px; max-width: 100%;
  text-decoration: none; font-weight: 650; font-size: 15px; letter-spacing: -.02em; color: #555;
  transition: color .25s ease;
}
.contact__link span { overflow-wrap: anywhere; }
.contact__link:hover { color: var(--accent); }
.ico { width: 17px; height: 17px; flex: none; color: var(--accent); }

/* Marquee */
.marquee {
  display: flex; overflow: hidden; background: var(--accent); color: var(--accent-ink);
  padding: 13px 0; user-select: none;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee__track {
  flex: none; display: flex; margin: 0; padding: 0; list-style: none;
  animation: marquee 26s linear infinite;
}
.marquee__track li {
  display: flex; align-items: center; white-space: nowrap;
  text-transform: uppercase; font-weight: 800; font-size: 15px; letter-spacing: -.01em;
}
.marquee__track li::after {
  content: ""; width: 6px; height: 6px; margin: 0 22px; border-radius: 50%;
  background: var(--accent-soft);
}
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-100%); } }

/* Sections */
.sec { padding: 34px 22px 8px; }
.sec + .sec { border-top: 1px solid var(--line); margin-top: 26px; }
.sec__head {
  display: flex; gap: 10px; align-items: baseline; margin-bottom: 18px;
  text-transform: uppercase; font-weight: 800; font-size: 15px; letter-spacing: -.02em;
}
.sec__num { color: var(--muted); }
.sec__label { margin: 0; font: inherit; }

.lead {
  margin: 0 0 20px; font-weight: 800; font-size: clamp(21px, 2vw + 12px, 27px);
  line-height: 1.08; letter-spacing: -.035em;
}
.prose p {
  margin: 0 0 16px; font-weight: 520; font-size: 16.5px; line-height: 1.5;
  letter-spacing: -.012em; color: #2a2a2a; white-space: pre-line;
}
.prose a {
  color: var(--accent); font-weight: 650; text-decoration: underline;
  text-decoration-thickness: 1.5px; text-underline-offset: 3px;
  text-decoration-color: color-mix(in srgb, var(--accent) 35%, transparent);
  transition: text-decoration-color .25s ease;
}
.prose a:hover { text-decoration-color: var(--accent); }

/* Features */
.features { list-style: none; margin: 0 0 18px; padding: 0; }
.features li + li { border-top: 1px solid var(--line); }
.feat {
  position: relative; display: grid; gap: 4px; padding: 16px 44px 16px 0;
  text-decoration: none; transition: transform .45s var(--ease-out);
}
.feat__kicker { font-size: 13px; font-weight: 700; letter-spacing: -.01em; color: var(--muted); text-transform: uppercase; }
.feat__title { font-size: 18px; font-weight: 800; line-height: 1.15; letter-spacing: -.03em; }
.feat__meta { font-size: 14px; font-weight: 600; color: #666; letter-spacing: -.01em; }
.feat__arrow {
  position: absolute; right: 4px; top: 50%; width: 22px; height: 22px; margin-top: -11px;
  color: var(--accent); transition: transform .45s var(--ease-out);
}
.feat:hover { transform: translateX(6px); }
.feat:hover .feat__title { color: var(--accent); }
.feat:hover .feat__arrow { transform: translate(3px, -3px); }

/* ───────── Intro sequence (only with JS) ─────────
   html.js            text lines sit below their masks, curtain covers the photo, card is off-screen
   html.is-intro      lines rise in, staggered
   html.is-revealed   curtain wipes away to the left, revealing the photo
   html.is-ready      card rises into the centre; scrolling is unlocked */
.js .curtain { display: block; transition: clip-path var(--t-curtain) var(--ease-io); clip-path: inset(0 0 0 0); }
.js .line__in {
  transform: translateY(108%);
  transition: transform var(--t-rise) var(--ease-out);
  transition-delay: calc(var(--i, 0) * var(--t-stagger));
}
.js.is-intro .line__in { transform: none; }
.js.is-revealed .curtain { clip-path: inset(0 100% 0 0); }
.js .card { transform: translateY(105vh); transition: transform var(--t-card) var(--ease-out); }
.js.is-ready .card { transform: none; }
.js:not(.is-ready) body { overflow: hidden; }

/* Scroll-in reveals inside the card */
.js .reveal {
  opacity: 0; transform: translateY(22px); filter: blur(6px);
  transition: opacity .8s var(--ease-out), transform .8s var(--ease-out), filter .8s var(--ease-out);
}
.js .reveal.in { opacity: 1; transform: none; filter: none; }

/* Hero name eases back as the card passes over it */
.hero__type { transition: opacity .2s linear; }

@media (prefers-reduced-motion: reduce) {
  .js .line__in, .js .card, .js .curtain, .js .reveal { transition: none !important; }
  .js .avatar-stage, .js.is-ready .avatar-stage { animation: none; transform: none; }
  .js .reveal { opacity: 1; transform: none; filter: none; }
  .marquee__track { animation: none; }
  .marquee { overflow-x: auto; }
}

/* ───────── Responsive ───────── */
@media (max-width: 1180px) {
  :root { --card-w: 540px; }
}
@media (max-width: 760px) {
  :root { --rest: 56svh; --radius: 18px; }
  /* Phone: drop the photo below a lavender band so the name sits clear of her face. */
  .hero { background: #dfdaf2; }
  .hero__media img {
    top: 24svh; height: calc(100% - 24svh); object-position: 77% 0;
    -webkit-mask-image: linear-gradient(to bottom, transparent, #000 14%);
            mask-image: linear-gradient(to bottom, transparent, #000 14%);
  }
  .hero__title .line { display: inline-block; vertical-align: top; margin-right: .22em; }
  .hero__type { justify-content: flex-start; gap: 10px; }
  .hero__name { font-size: clamp(44px, 13.5vw, 64px); }
  .hero__title { font-size: clamp(17px, 5vw, 26px); color: #2b2b2b; }
  .profile { grid-template-columns: 112px minmax(0, 1fr); gap: 16px; padding: 16px 16px 20px; }
  .profile__name { font-size: 20px; }
  .profile__role { font-size: 13px; }
  .contact { margin-top: 12px; }
  .contact__link { font-size: 14px; gap: 8px; }
  .sec { padding: 28px 18px 6px; }
  .feat__title { font-size: 17px; }
}
@media (max-width: 380px) {
  .profile { grid-template-columns: 1fr; }
  .profile__avatar { width: 120px; }
}

/* ───────── ATG branding footer (shared house block) ─────────
   Portable: set the three --atg-foot-* tokens per site; nothing else changes. */
.atg-foot {
  --atg-foot-fg: var(--paper, #fff);
  --atg-foot-muted: rgba(255, 255, 255, .69);
  --atg-foot-line: var(--faint, rgba(255, 255, 255, .14));
  text-align: center; color: var(--atg-foot-fg);
  border-top: 1px solid var(--atg-foot-line);
  padding: clamp(36px, 6vh, 56px) 16px calc(clamp(28px, 5vh, 44px) + var(--dock-space, 0px));
  transition: padding .5s ease;
}
.atg-foot__copy { margin: 0; font-size: clamp(15px, 1vw + 8px, 18px); font-weight: 500; }
.atg-foot__credit {
  margin: 2.25vh 0 0; font-family: system-ui, sans-serif; font-size: 90%; font-weight: 400;
  text-transform: lowercase; color: #eee;
}
.atg-foot__brand { display: inline-block; margin-left: .14rem; text-transform: lowercase; }
.atg-foot__brand a { color: var(--atg-foot-fg); text-decoration: none; }
.atg-foot__brand a:hover { text-decoration: underline; text-underline-offset: 3px; }
.atg-foot__brand::after {
  /* external-link mark as a masked SVG so it takes the text colour; swap to FA ("\f14c") on sites that load the kit */
  content: ""; display: inline-block; width: .74em; height: .74em; margin-left: .3rem; vertical-align: -.04em;
  background-color: currentColor; opacity: .85;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 4h6v6'/%3E%3Cpath d='M20 4l-8.5 8.5'/%3E%3Cpath d='M19 14.5V19a1.5 1.5 0 0 1-1.5 1.5h-12A1.5 1.5 0 0 1 4 19V7a1.5 1.5 0 0 1 1.5-1.5H10'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 4h6v6'/%3E%3Cpath d='M20 4l-8.5 8.5'/%3E%3Cpath d='M19 14.5V19a1.5 1.5 0 0 1-1.5 1.5h-12A1.5 1.5 0 0 1 4 19V7a1.5 1.5 0 0 1 1.5-1.5H10'/%3E%3C/svg%3E") center / contain no-repeat;
}
.atg-foot__brand b { font-weight: 700; }
.atg-foot__tag-link { display: inline-block; margin-top: 1.5vh; border-radius: 50%; }
.atg-foot__tag {
  display: inline-block; vertical-align: middle; border-radius: 50%;
  filter: grayscale(100%); transform: scale(1);
  transition: filter 1s ease-in-out, transform 1s ease-in-out;
}
.atg-foot__tag-link:hover .atg-foot__tag,
.atg-foot__tag-link:focus-visible .atg-foot__tag { filter: grayscale(0%); transform: scale(1.25); }
.atg-foot__tag-link:focus-visible { outline: 2px solid var(--atg-foot-fg); outline-offset: 6px; }

/* Site-specific footer surface: the original site's black band. */
.atg-foot { position: relative; z-index: 3; background: #111; --atg-foot-fg: #fff; }
