/*
  Jost (SIL OFL, self-hosted from public/fonts/) — a free geometric sans built
  to match Futura's proportions closely, used as the primary face so every
  visitor sees the same type regardless of what's installed/synced locally
  (see git history on this file for how relying on a system/Adobe-synced
  Futura went: it silently broke after an unrelated OS update).
*/
@font-face {
  font-family: 'Jost';
  src: url('/fonts/jost-book.woff2') format('woff2');
  font-weight: 400;   font-style: normal;  font-display: swap;
}
@font-face {
  font-family: 'Jost';
  src: url('/fonts/jost-light.woff2') format('woff2');
  font-weight: 300;   font-style: normal;  font-display: swap;
}

/* Clean, minimal, editorial. Light base with restrained type. */
:root {
  /* Palette: "Cool concrete" — architectural, understated. */
  --bg: #f4f5f6;   /* cool white */
  --fg: #1b1e22;   /* charcoal */
  --muted: #6a7075; /* slate */
  --line: #e2e5e8;  /* hairline */
  /* Sparing accent — currently only the CV page's entry hierarchy (title
     black / institution-venue red / dates & supporting text gray). Muted
     enough to sit quietly next to the rest of the "cool concrete" palette. */
  --accent: #7d332e; /* dark brick red */
  --maxw: 1200px;
  --gap: clamp(1rem, 2vw, 2rem);
  /* Consistent page buffer from the screen edge — used everywhere so "leftmost"
     / "rightmost" content lines up (a small, even margin, never the true edge).
     +10px is a deliberate nudge past the clamp's responsive value — change
     here only; every dependent element reads this one variable.
     --edge-rest (the ceiling branch, pulled out on its own) is --edge's value
     before any shrink pressure — --nav-edge below borrows it without also
     inheriting --edge's shrink *schedule* (see --nav-edge). */
  --edge-rest: calc(3rem + 10px);
  --edge: clamp(calc(1.5rem + 10px), calc(3vw + 10px), var(--edge-rest));
  /* --edge's own clamp is tuned for general page margins, and starts
     shrinking (from its 3vw term) at a much wider viewport than the top nav's
     other fluid elements (name, links — see Nav.astro) do — if --nav-edge
     capped against the live var(--edge), the hamburger gutter would already
     be visibly squeezed while "Marc Dunand" and the right-hand links are
     still sitting at full size, nowhere near colliding. Capping against
     --edge-rest (its fixed, pre-shrink value) instead means --nav-edge stays
     flat until its own 10vw term drops below that ceiling — tuned to happen
     around the same ~640-660px viewport width where .name (5vw vs. a 32px
     ceiling) and .link (3vw vs. --menu-size) start shrinking, i.e. only once
     the name and links are actually about to collide. */
  --nav-edge: clamp(1.1rem, 10vw, var(--edge-rest));
  --nav-h: 72px; /* roomier so the large name sits comfortably */
  /* "Behind the Project" working-area background (slightly grayer than base) */
  --behind-bg: #e9ebed;
  --behind-dot: #d3d7db;
  /* Futura weights: larger text = Book (400), smaller text = Light (300) */
  --fw-book: 400;
  --fw-light: 300;
  /* Base text bumped +2pt over the browser default; the very large name text
     (nav + CV) is pinned to a fixed size so it is unaffected. */
  --name-size: 32px; /* fixed → stays the same when base text grows */
  /* Page titles (About/Contact/CV heading): 2pt smaller than the nav name. */
  --title-size: calc(var(--name-size) - 2pt);
  /* Shared size for top-right nav links, the work tabs, and each piece's
     inline title (Title, Year). */
  --menu-size: 1.05rem;
  font-size: calc(1em + 2pt);
  font-family: 'Jost', 'Futura', 'Futura PT', 'Century Gothic', 'Avenir Next',
    'Avenir', ui-sans-serif, system-ui, 'Segoe UI', Helvetica, Arial, sans-serif;
  /* Without this, mobile Safari/Chrome "font boosting" can inflate the font
     size of short text nodes (e.g. the drawer's lone "×" close button) well
     past their set rem value at certain viewport widths. */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

* { box-sizing: border-box; }

/* Browsers don't inherit the page's font onto form controls by default (only
   <a> gets that for free) — without this, any <button> with text (drawer
   close, work tabs, CV download, lightbox controls, contact submit) silently
   renders in the browser's UI font instead of the site's, which is exactly
   what caused the drawer close button's "×" to sit at a visibly different
   vertical position than text next to it despite identical box centering:
   two different fonts, not a layout bug. */
button, input, select, textarea { font: inherit; color: inherit; }

html, body { margin: 0; padding: 0; }

body {
  background: var(--bg);
  color: var(--fg);
  line-height: 1.5;
  font-weight: var(--fw-light); /* smaller/body text = Futura Light */
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }

img, video { max-width: 100%; display: block; }

/* Placeholder fill for any <img>/<video> still loading (see MediaLoading.astro,
   included site-wide in BaseLayout) — a slow pulse between the hairline and
   base tones rather than a moving shimmer, to stay quiet/editorial. Harmless
   on media whose box has no size yet (nothing to paint until layout resolves),
   and invisible once real content covers the box. */
@keyframes media-pulse {
  0%, 100% { background-color: var(--line); }
  50% { background-color: var(--bg); }
}
img.media-pending, video.media-pending {
  animation: media-pulse 1.6s ease-in-out infinite;
}

/* larger text = Futura Book */
h1, h2, h3 { font-weight: var(--fw-book); letter-spacing: -0.01em; line-height: 1.15; }

/* Full-screen width with a consistent edge buffer (no max-width cap). */
.container {
  width: 100%;
  padding-inline: var(--edge);
}

.muted { color: var(--muted); }

/* Print: used by the CV "download" (browser print-to-PDF). */
@media print {
  .no-print { display: none !important; }
  body { background: #fff; }
}
.nav[data-astro-cid-dmqpwcec]{position:sticky;top:0;z-index:50;height:var(--nav-h);background:color-mix(in srgb,var(--bg) 92%,transparent);backdrop-filter:saturate(1.2) blur(6px);border-bottom:1px solid var(--line)}.nav-inner[data-astro-cid-dmqpwcec]{position:relative;height:100%;width:100%;display:flex;align-items:center;justify-content:space-between;padding-inline:var(--nav-edge)}.brand[data-astro-cid-dmqpwcec]{display:flex;align-items:center}.name[data-astro-cid-dmqpwcec]{font-weight:var(--fw-book);font-size:clamp(1.25rem,5vw,var(--name-size));letter-spacing:-0.01em;text-decoration:none;white-space:nowrap}.links[data-astro-cid-dmqpwcec]{display:flex;align-items:center;gap:clamp(0.5rem,2vw,1.6rem)}.link[data-astro-cid-dmqpwcec]{color:var(--muted);font-size:clamp(0.75rem,3vw,var(--menu-size));font-weight:var(--fw-book);text-decoration:none;white-space:nowrap}.link[data-astro-cid-dmqpwcec]:hover{color:var(--fg)}.link[data-astro-cid-dmqpwcec].active{color:var(--fg);border-bottom:2px solid currentColor;padding-bottom:2px}.icon-link[data-astro-cid-dmqpwcec]{display:inline-flex;align-items:center;color:var(--muted)}.icon-link[data-astro-cid-dmqpwcec]:hover{color:var(--fg)}.icon-link[data-astro-cid-dmqpwcec] svg[data-astro-cid-dmqpwcec]{width:clamp(0.95rem,3vw,1.25rem);height:clamp(0.95rem,3vw,1.25rem);display:block}.menu-toggle[data-astro-cid-dmqpwcec]{position:absolute;left:0;top:50%;transform:translateY(-50%);width:var(--nav-edge);display:flex;align-items:center;justify-content:center;border:0;background:none;padding:0;color:var(--fg);cursor:pointer}.menu-toggle[data-astro-cid-dmqpwcec]:hover{opacity:0.65}.menu-toggle[data-astro-cid-dmqpwcec] svg[data-astro-cid-dmqpwcec]{width:clamp(1.1rem,4vw,1.55rem);height:clamp(1.1rem,4vw,1.55rem);display:block}.footer[data-astro-cid-sz7xmlte]{margin-top:6rem;border-top:1px solid var(--line)}.foot-inner[data-astro-cid-sz7xmlte]{display:flex;flex-wrap:wrap;justify-content:space-between;column-gap:2rem;row-gap:0.75rem;padding-block:1.5rem;font-size:0.9rem;color:var(--muted)}.foot-link[data-astro-cid-sz7xmlte]{display:inline-flex;align-items:center;gap:0.5rem;text-decoration:none}.foot-link[data-astro-cid-sz7xmlte]:hover{color:var(--fg)}.icon[data-astro-cid-sz7xmlte]{width:1.1rem;height:1.1rem;flex:none}img.lightbox-trigger { cursor: zoom-in; }.lightbox[data-astro-cid-gixpweiw]{position:fixed;inset:0;z-index:1000;background:rgba(0,0,0,0.92);display:flex;align-items:center;justify-content:center;padding:5vh 5vw;cursor:zoom-out}.lightbox[data-astro-cid-gixpweiw][hidden]{display:none}.lightbox-img[data-astro-cid-gixpweiw]{max-width:100%;max-height:100%;object-fit:contain;display:block;cursor:default}.lightbox-close[data-astro-cid-gixpweiw]{position:absolute;top:1.25rem;right:1.5rem;background:none;border:0;color:#fff;font-size:2.25rem;line-height:1;cursor:pointer;padding:0.5rem}.lightbox-arrow[data-astro-cid-gixpweiw]{position:absolute;top:50%;transform:translateY(-50%);border:0;background:rgba(255,255,255,0.08);color:#fff;font-size:2.5rem;line-height:1;width:56px;height:72px;cursor:pointer}.lightbox-arrow[data-astro-cid-gixpweiw]:hover{background:rgba(255,255,255,0.18)}.lightbox-arrow[data-astro-cid-gixpweiw][hidden]{display:none}.lightbox-prev[data-astro-cid-gixpweiw]{left:0.75rem}.lightbox-next[data-astro-cid-gixpweiw]{right:0.75rem}