/* Xander overrides on top of the ID—C stylesheet: type scale, one-row header on the 12-col grid, blue loader, scramble. */

/* ---------- Fonts: same as the 4180 portfolio ----------
   Alpha Lyrae Medium (one weight, SIL OFL) for everything; Fragment Mono (Google Fonts) for file-name captions. */
@font-face {
  font-family: "Alpha Lyrae";
  src: url("/assets/fonts/AlphaLyrae-Medium.woff2") format("woff2"), url("/assets/fonts/AlphaLyrae-Medium.woff") format("woff");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
body { font-family: "Alpha Lyrae", "Helvetica Neue", Helvetica, Arial, sans-serif; font-weight: 500; }
/* Univers Thin brackets have no Alpha Lyrae equivalent: keep them quiet with color instead of weight */
.thin { font-weight: inherit; color: rgb(var(--grey-40)); }
.mono, .media-caption, .xv-file {
  font-family: "Fragment Mono", ui-monospace, Menlo, monospace;
  font-weight: 400; font-size: 11px; line-height: 1; letter-spacing: 0; text-transform: uppercase;
}

/* ---------- Type scale: three sizes, nothing in between ----------
   display  the one statement per page (the description under the header)
   text     reading copy, section headings, case titles, stats, footer
   small    UI and metadata: menu, clock, card titles, tags, captions, labels */
:root {
  /* All copy is set in capitals. Capitals need more air than lowercase, so tracking opens up as size drops:
     tight at display, neutral at text, open at small. */
  --t-display: 42px; --t-display-lh: 46px; --t-display-ls: -0.01em;
  --t-text: 24px;    --t-text-lh: 28px;    --t-text-ls: 0em;
  --t-small: 14px;   --t-small-lh: 18px;   --t-small-ls: 0.03em;
}
/* All caps, everywhere. Image alt text and aria-labels are untouched (screen readers get normal case). */
body { text-transform: uppercase; }
@media all and (max-width: 950px) {
  :root {
    --t-display: 28px; --t-display-lh: 32px;
    --t-text: 20px;    --t-text-lh: 24px;
    --t-small: 13px;   --t-small-lh: 17px;
  }
}

body { font-size: var(--t-text); line-height: var(--t-text-lh); letter-spacing: var(--t-text-ls); }

/* text: the ID—C 60px headings come down to reading size, so the description is the only large type */
h1, .type-heading-large,
.project-stats .type-heading-large {
  font-size: var(--t-text); line-height: var(--t-text-lh); letter-spacing: var(--t-text-ls);
}
a.section-header-link .icon { font-size: var(--t-text); }

/* small */
.type-detail, .work-card-info .type-detail, .work-detail-meta-wrap.type-detail,
nav ul a, .featured-work-title {
  font-size: var(--t-small); line-height: var(--t-small-lh); letter-spacing: var(--t-small-ls);
}

/* ---------- Header ---------- */
header.xv-header { padding: var(--spacing-12) 0 0; border-bottom: 1px solid rgb(var(--border-subtle)); }
.xv-bar { align-items: baseline; font-size: var(--t-small); line-height: var(--t-small-lh); letter-spacing: var(--t-small-ls); }
.xv-bar a, .xv-bar .header-time { color: rgb(var(--black)); transition: opacity .2s var(--easing); }
/* right half of the grid: clock + four links, equal gaps, first item on column 7, last on the right margin */
.xv-menu { display: flex; justify-content: space-between; align-items: baseline; }
.xv-menu a[aria-current="page"] { opacity: .4; }
.xv-menu a:hover { opacity: .6; }
.xv-bar .header-time { display: block; font-variant-numeric: tabular-nums; }
.xv-bar .header-time .current-time { display: inline; min-width: 0; }

.xv-intro { padding-top: 9.6rem; padding-bottom: var(--spacing-32); }
/* headline breaks are set by hand (data-breaks in build_xv.py) from 1600px, where line 2 fits; narrower screens wrap freely, "pretty" avoids a one-word last line */
.xv-intro p .xv-br { display: none; }
@media all and (min-width: 1600px) { .xv-intro p .xv-br { display: inline; } }
.xv-intro p { text-wrap: pretty; font-size: var(--t-display); line-height: var(--t-display-lh); letter-spacing: var(--t-display-ls); color: rgb(var(--black)); }

@media all and (max-width: 950px) {
  .xv-bar { row-gap: 1.2rem; }
  .xv-bar .xv-name, .xv-bar .xv-menu { width: 100%; }
  .xv-intro { padding-top: 4.8rem; }
  .xv-intro .col { width: 100%; }
}

/* ---------- Scramble ---------- */
.sx { display: inline-block; text-align: center; white-space: pre; letter-spacing: 0; }
.xv-scramble-intro { visibility: hidden; }
.xv-scramble-intro.on { visibility: visible; }
.xv-scramble-intro .w { display: inline-block; white-space: nowrap; }

/* ---------- Loader ---------- */
.loader { position: fixed; inset: 0; z-index: 9000; display: grid; place-items: center; background: #0026FF; color: #fff; will-change: transform; transition: transform .95s cubic-bezier(.76, 0, .24, 1); }
.loader.leave { transform: translateY(-100%); }
.loader-text { font-size: var(--t-text); line-height: 1.1; letter-spacing: -0.02em; white-space: pre; min-height: 1.1em; }
html.loading { overflow: hidden; }
/* Rise-in goes on main + intro, never on #swup: swup waits for #swup's own opacity fade (.transition-fade). */
main, .xv-intro { transition: transform 1.2s cubic-bezier(.2, .7, .2, 1); }
html.loading main, html.loading .xv-intro { transform: translateY(90px); }

/* ---------- Information page (mirrors the 4180 info page on the 12-col grid) ---------- */
.xv-info { padding-top: 0; }
.xv-about { padding-top: 12rem; align-items: flex-start; }
.xv-bio { font-size: var(--t-text); line-height: var(--t-text-lh); letter-spacing: var(--t-text-ls); }
.xv-portrait { margin: 0; }
.xv-portrait .tile { position: relative; aspect-ratio: 1 / 1; overflow: hidden; }
.xv-portrait .tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.xv-portrait figcaption { margin-top: .8rem; }
.dither { position: absolute; inset: 0; width: 100%; height: 100%; image-rendering: pixelated; pointer-events: none; }
.xv-lists { padding-top: 12rem; padding-bottom: 12rem; row-gap: 4rem; }
.xv-list h2 { margin-bottom: 2rem; }
.xv-list li { font-size: var(--t-small); line-height: var(--t-small-lh); letter-spacing: var(--t-small-ls); }
html.xv-page-information .xv-intro { display: none; }
@media all and (max-width: 950px) {
  .xv-about { padding-top: 4.8rem; row-gap: 4rem; }
  .xv-lists { padding-top: 6rem; padding-bottom: 6rem; }
  .xv-list { width: calc((100% - var(--gutter)) / 2); }
}

/* ---------- Black theme (Information page, like 4180) ---------- */
html, body, header.xv-header, nav, footer { transition: background-color .4s var(--easeOut), color .4s var(--easeOut); }
html.xv-dark, html.xv-dark body { background: #000; color: #fff; }
html.xv-dark header.xv-header { background: #000; border-bottom-color: rgba(255, 255, 255, .14); }
html.xv-dark nav { background-color: rgba(0, 0, 0, .9); }
html.xv-dark .xv-bar a, html.xv-dark .xv-bar .header-time,
html.xv-dark .xv-intro p, html.xv-dark main, html.xv-dark main p,
html.xv-dark footer, html.xv-dark footer a, html.xv-dark footer p,
html.xv-dark .color-green-100, html.xv-dark .color-black { color: #fff; }
html.xv-dark .thin, html.xv-dark .color-grey-40, html.xv-dark .color-grey-60 { color: rgba(255, 255, 255, .4); }
html.xv-dark footer, html.xv-dark .footer-bottom { border-color: rgba(255, 255, 255, .14); }

/* ---------- Description: homepage only ----------
   Hidden by default; html.xv-home (set before first paint by the inline script, then kept in sync by xv.js on
   page swaps) brings it back. Without it the header is just the one-row bar, so content sits right under it. */
.xv-intro { display: none; }
html.xv-home .xv-intro { display: flex; }
header.xv-header { padding-bottom: var(--spacing-12); }
html.xv-home header.xv-header { padding-bottom: 0; }

/* ---------- Square corners everywhere ----------
   The ID—C sheet rounds images, cards and controls with eight different radii; this flattens all of them. */
*, *::before, *::after { border-radius: 0 !important; }


/* Playground blue (like the 4180 portfolio). xv.js sets html.xv-blue on click, before swup fades the old
   content out, so nav, background and content change together over one short fade. */
html { background: #fff; }
html, body { transition: background-color .35s ease, color .35s ease; }
header, header a, header span, footer, footer a, footer span { transition: color .35s ease, border-color .35s ease, background-color .35s ease; }
html.xv-blue, html.xv-blue body { background: #0026FF; color: #fff; }
html.xv-blue :is(header, main, footer, a, span, p, h1, h2, h3) { color: #fff; }
html.xv-blue :is(.color-grey-60, .xv-file) { color: rgba(255,255,255,.6); }
html.xv-blue .media { background: #0020D6; }
html.xv-blue :is(header, footer, .grid-overlay) { background: transparent; border-color: rgba(255,255,255,.3); }

/* Playground is temporarily unavailable: crossed out, not clickable */
.xv-disabled { text-decoration: line-through; text-decoration-thickness: 1px; opacity: .45; cursor: default; transition: opacity .25s; }
.xv-disabled:hover { opacity: .7; }
/* "In the lab" tooltip for Playground: a blue tag that types itself in under the link */
.xv-tip { position: fixed; z-index: 9500; pointer-events: none; background: #0026FF; color: #fff;
  font: 400 11px/1 "Fragment Mono", ui-monospace, monospace; letter-spacing: .02em; text-transform: uppercase;
  padding: 7px 9px 6px; white-space: pre; opacity: 0; transform: translateY(-4px);
  transition: opacity .18s ease, transform .28s cubic-bezier(.16,1,.3,1); }
.xv-tip.on { opacity: 1; transform: none; }
.xv-tip::after { content: ""; display: inline-block; width: .55em; height: 1em; margin-left: 3px; vertical-align: -2px;
  background: currentColor; animation: xv-blink 1s steps(1) infinite; }
@keyframes xv-blink { 50% { opacity: 0; } }

/* Footer: ID—C made it a full screen tall (room for its illustration); ours ends with the content. */
footer { min-height: 0 !important; }
/* Hero flip-book: frames without an image yet stay out of the stack. */
.featured-work-cards[data-xv] .featured-work-card:not(.loaded) { visibility: hidden; }

/* Projects not open yet: visible, not clickable */
.xv-soon { cursor: default; }

/* Work in progress: greyscale cards, the blue tag says so on hover */
.xv-soon .media img, .xv-soon .media video { filter: grayscale(1); transition: filter .4s ease, opacity .4s ease; }
.xv-soon:hover .media img { opacity: .82; }
.xv-soon .work-title { color: rgb(var(--grey-60)); }

/* Information on phones: label on top, text full width underneath */
@media all and (max-width: 950px) {
  .xv-info-row > .col { --span: 8; --offset: 0; margin-left: 0; width: 100%; }
  .xv-info-row > .col:first-child p { color: rgb(var(--grey-60)); margin-bottom: .6rem; }
  .xv-info-row .text-content { overflow-wrap: break-word; }
  .xv-info-row .text-content p, .xv-info-row > .col:first-child p { font-size: 16px; line-height: 1.3; }
}

/* Portrait drawn in type over a hidden photo (the photo still loads, for the alt text and the sampler) */
.xv-portrait .tile { color: rgb(var(--black)); background: transparent; }
html.xv-dark .xv-portrait .tile { color: #fff; }

/* ---------- Photography: scattered editorial grid ---------- */
.xv-photos { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: var(--gutter); row-gap: 9vh;
  padding: 18vh var(--pageMarginTotal) 20vh; align-items: start; }
.xv-photo { grid-column: var(--c) / span var(--s); margin: var(--mt) 0 0; }
.xv-photo a { display: block; cursor: zoom-in; }
.xv-photo img { width: 100%; height: auto; display: block; transition: opacity .4s ease; }
.xv-photo a:hover img { opacity: .88; }
.xv-photo figcaption { margin-top: .5rem; color: rgb(var(--grey-60)); display: flex; gap: .6em; }
@media all and (max-width: 950px) {
  .xv-photos { grid-template-columns: repeat(6, 1fr); row-gap: 6vh; padding-top: 12vh; }
  .xv-photo { grid-column: var(--cm) / span var(--sm); margin-top: 0; }
}
/* full-screen viewer */
.xv-lightbox { position: fixed; inset: 0; z-index: 9800; background: rgb(var(--white)); display: grid; place-items: center;
  opacity: 0; pointer-events: none; transition: opacity .25s ease; cursor: zoom-out; }
.xv-lightbox.on { opacity: 1; pointer-events: auto; }
.xv-lightbox img { max-width: calc(100vw - 2 * var(--pageMarginTotal)); max-height: calc(100vh - 7rem); width: auto; height: auto; object-fit: contain; }
.xv-lightbox .bar { position: absolute; left: var(--pageMarginTotal); right: var(--pageMarginTotal); bottom: 1.4rem;
  display: flex; justify-content: space-between; color: rgb(var(--grey-60)); pointer-events: none; }
.xv-lightbox .nav { position: absolute; top: 0; bottom: 0; width: 30%; cursor: w-resize; }
.xv-lightbox .nav.next { right: 0; cursor: e-resize; }
.xv-lightbox .nav.prev { left: 0; }
html.xv-lb-open { overflow: hidden; }

/* Photography header: pinned over the photos as they scroll; difference blend keeps it legible on any image */
.xv-photos-head { position: sticky; top: 4.4rem; z-index: 40; height: 0; overflow: visible; pointer-events: none;
  padding: 0 var(--pageMarginTotal); mix-blend-mode: difference; color: #fff; }
.xv-photos-head p { margin: 0; max-width: 34ch; }
.xv-photos-head .type-heading-large { padding-top: 2.2rem; }
.xv-photos-sub { margin-top: .9rem !important; max-width: 46ch !important; font-size: 14px; line-height: 1.35; text-transform: none; opacity: .85; }
@media all and (max-width: 950px) { .xv-photos-head { top: 5.6rem; } .xv-photos-head .type-heading-large { padding-top: 1.2rem; } .xv-photos-sub { font-size: 13px; } }
.xv-photos-page { background: rgb(var(--white)); }
/* the pinned photography line uses the homepage's display type */
.xv-photos-head.columns { padding: 0 var(--pageMarginTotal); }
.xv-photos-head .xv-photos-title { font-size: var(--t-display); line-height: var(--t-display-lh); letter-spacing: var(--t-display-ls);
  max-width: none; padding-top: 0.4rem; margin: 0; }   /* first line matches the homepage intro */
@media all and (max-width: 950px) { .xv-photos-head .col { width: 100%; } .xv-photos-head .xv-photos-title { padding-top: 1.2rem; } }
/* start the photos below the pinned line; it overlays them once you scroll */
.xv-photos { padding-top: calc(var(--head-h, 30vh) + 8vh); }

/* thin close X, top right of the photo viewer */
.xv-lightbox .close { position: absolute; z-index: 2; top: max(1.1rem, env(safe-area-inset-top)); right: var(--pageMarginTotal);
  width: 28px; height: 28px; padding: 0; border: 0; background: none; color: rgb(var(--black)); cursor: pointer; opacity: .85; transition: opacity .2s; }
.xv-lightbox .close:hover { opacity: 1; }
.xv-lightbox .close svg { width: 100%; height: 100%; display: block; }
@media all and (max-width: 950px) { .xv-lightbox .close { width: 24px; height: 24px; } }

/* phone header: the clock sits top right, opposite the name; the four links share the next line evenly */
@media all and (max-width: 950px) {
  .xv-bar { position: relative; }
  .xv-menu { justify-content: space-between; }
  .xv-menu > a, .xv-menu > span { white-space: nowrap; }
  .xv-menu .header-time { position: absolute; right: var(--pageMarginTotal); top: var(--xv-name-top, 0); margin: 0; }
}

/* phone viewer: big tap target for the X, no tap zones, no flashes or fades */
.xv-lightbox, .xv-lightbox * { -webkit-tap-highlight-color: transparent; }
.xv-lightbox img { will-change: transform; touch-action: pan-y; }
@media (hover: none) {
  .xv-lightbox { transition: none; cursor: default; }
  .xv-lightbox .nav { display: none; }
  .xv-lightbox .close { width: 56px; height: 56px; padding: 16px; top: max(.4rem, env(safe-area-inset-top)); right: calc(var(--pageMarginTotal) - 16px); }
}

/* Card hover (19 Nov): the cover zooms in toward the pointer, so it leans to whichever side you enter from,
   and eases back out the way it came. Open projects only; off for touch and reduced motion. */
.media.square.xv-zoom { overflow: hidden; }
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  /* Smoother (Xander, 19 Nov): fixed centre, small zoom, one long ease in and out. No pointer-following. */
  .xv-zoom img, .xv-zoom video {
    transform: scale(1.001); transform-origin: 50% 50%;
    transition: transform 1.6s cubic-bezier(.22, 1, .36, 1);
    will-change: transform; backface-visibility: hidden;
  }
  .work-listing-card:hover .xv-zoom img, .work-listing-card:hover .xv-zoom video { transform: scale(1.05); }
}

/* Old-site case-study copy between images (from _src/case-copy.json) */
.xv-story { margin: 6rem 0 7rem; }
.xv-story .xv-story-head { margin-bottom: 1.6rem; }
.xv-story .text-content p + p { margin-top: 1em; }
.xv-story .text-content { max-width: 40em; }
@media all and (max-width: 950px) { .xv-story { margin: 3rem 0 4rem; } }

/* Info rows: label column is always 2 grid columns, and keeps a clear gap from the copy (Xander, 2026-11-19: no crowding) */
@media (min-width: 1024px) {
  .xv-info-row > .col:first-child { padding-right: 1.5em; }
  .xv-info-row > .col:first-child p { overflow-wrap: normal; hyphens: none; }
}
.sx-w { display: inline; white-space: nowrap; }

/* ---- layout kinds beyond full / half (20 Nov) ---- */
.content-row .xv-bleed{margin-left:var(--negPageMargin);width:var(--fullBleedWidth)!important;max-width:none}
.content-row .xv-inset{padding-block:var(--spacing-80)}
.content-row .xv-narrow{align-self:flex-end}
.content-row .xv-aside{padding-block:var(--spacing-120)}
@media (max-width:950px){
  .content-row .xv-inset{padding-block:var(--spacing-24)}
  .content-row .xv-aside{padding-block:var(--spacing-40)}
}

/* Text selection in the brand blue (21 Nov). On the blue Playground page it flips to white so it stays visible. */
::selection { background: #0026FF; color: #fff; }
html.xv-blue ::selection { background: #fff; color: #0026FF; }

/* + cursor on everything clickable (Xander 2026-11-24, after sort-office.com). Thin crosshair, white edge so it reads on dark images. */
:root {
  --xv-plus: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='17' height='17' viewBox='0 0 17 17'%3E%3Cpath d='M8.5 0v17M0 8.5h17' stroke='%23fff' stroke-width='3'/%3E%3Cpath d='M8.5 0v17M0 8.5h17' stroke='%23000' stroke-width='1'/%3E%3C/svg%3E") 8 8, pointer;
}
a[href], button, [role="button"], summary, label[for], .xv-photo a,   /* not the hero reel: it isn't clickable */
.xv-lightbox, .xv-lightbox .nav, .xv-lightbox .nav.next, .xv-lightbox .close { cursor: var(--xv-plus); }
.xv-disabled, .xv-soon, .xv-soon a { cursor: default; }

/* Hi button, fixed bottom left on every page (Xander 2026-11-24): bare 44px emoji, page-margin spacing, waves on hover; hover tag = rotating contact line (xv.js). */
.xv-contact-fab { position: fixed; z-index: 8000; left: var(--pageMarginTotal); bottom: max(var(--pageMarginTotal), env(safe-area-inset-bottom));
  display: grid; place-items: center; width: 70px; height: 70px; border: 0; background: transparent;
  font-size: 31px; line-height: 1; text-decoration: none; transition: background .2s var(--easing), opacity .2s var(--easing); }
.xv-contact-fab span { display: block; transform-origin: 70% 75%; }
.xv-contact-fab:hover span { animation: xv-wave .9s ease-in-out; }
@keyframes xv-wave { 0%, 100% { transform: rotate(0); } 20%, 60% { transform: rotate(16deg); } 40%, 80% { transform: rotate(-8deg); } }
html.loading .xv-contact-fab { opacity: 0; }
@media (prefers-reduced-motion: reduce) { .xv-contact-fab:hover span { animation: none; } }
@media print { .xv-contact-fab { display: none; } }
html.xv-no-hi .xv-contact-fab, html.xv-at-footer .xv-contact-fab { opacity: 0; visibility: hidden; pointer-events: none; }
.xv-contact-fab { transition: opacity .25s var(--easing), visibility .25s; }

/* Case pages: back-to-top arrow, top left of the sticky row, mirrors the close X (Xander 2026-11-24). Shows once you scroll. */
.xv-to-top-col { position: relative; }
.xv-to-top { position: absolute; left: 0; top: .2em; height: 2.4rem; width: 2.4rem; font-size: 1.35rem; padding: 0; border: 0;
  background: none; color: rgb(var(--black)); display: flex; align-items: center; justify-content: flex-start;
  opacity: 0; visibility: hidden; transition: opacity .25s var(--easing), visibility .25s, color .2s var(--easeOut); }
.xv-to-top svg { transform: rotate(-90deg); }
.xv-to-top:hover { color: rgb(var(--grey-40)); }
html.xv-scrolled .xv-to-top { opacity: 1; visibility: visible; }
.xv-to-top-col { transform: translateY(-0.4rem); }   /* same nudge the close column gets */
@media all and (max-width: 950px) { .xv-to-top { display: none; } }   /* phones: the row stacks; tap the status bar for top */

/* Contact links (footer Enquiries/Social + Information Contact row) hover in the site blue (Xander 2026-11-24).
   Not on the blue Playground or dark pages, where blue wouldn't read. */
html:not(.xv-blue):not(.xv-dark) footer p a:hover,
html:not(.xv-blue):not(.xv-dark) .xv-contact-row a:hover { color: #0026FF; }
footer p a:after { display: none; }   /* no underline on footer links (Xander 2026-11-24) */
.xv-contact-row a { transition: color .2s var(--easeOut); }
