/* HUMAN Lab — design system
   Palette sampled from the logo: orange #E28243, magenta #B6609E, cyan #46A5C8, ink. */

:root {
  --orange: #e28243;
  --magenta: #b6609e;
  --cyan: #46a5c8;
  --orange-ink: #a8501a;   /* AA-contrast text variants on light bg */
  --magenta-ink: #8e3b78;
  --cyan-ink: #1f6f8e;

  --bg: #fbf8f4;
  --bg-tint: #f3eee7;
  --surface: #ffffff;
  --ink: #17141b;
  --ink-2: #4a4550;
  --ink-3: #7a7480;
  --rule: #e4ddd3;
  --footer-bg: #17141b;
  --footer-ink: #efe9e1;

  --grad: linear-gradient(90deg, var(--orange), var(--magenta) 50%, var(--cyan));
  --serif: "DM Serif Display", Georgia, "Times New Roman", serif;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --wrap: 1200px;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(23, 20, 27, .05), 0 8px 30px -12px rgba(23, 20, 27, .18);
  --on-accent: #fff;
  --orange-deep: #b5561f; --magenta-deep: #9a4784; --cyan-deep: #27789a;
  --orange-tint: #fbeee4; --magenta-tint: #f6e9f2; --cyan-tint: #e5f2f8;
  color-scheme: light;
}

/* Dark theme: follows the system unless the visitor picked one with the toggle
   (stored as <html data-theme="light|dark">). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --orange-ink: #f0a273;
    --magenta-ink: #dd93c8;
    --cyan-ink: #7cc6e2;
    --bg: #141217;
    --bg-tint: #1c1920;
    --surface: #211d25;
    --ink: #f1ece6;
    --ink-2: #c5bec9;
    --ink-3: #958d99;
    --rule: #332e38;
    --footer-bg: #0d0b0f;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 10px 30px -12px rgba(0, 0, 0, .6);
    --on-accent: var(--bg);
    --orange-tint: #2d211b; --magenta-tint: #2a1d27; --cyan-tint: #182429;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
    --orange-ink: #f0a273;
    --magenta-ink: #dd93c8;
    --cyan-ink: #7cc6e2;
    --bg: #141217;
    --bg-tint: #1c1920;
    --surface: #211d25;
    --ink: #f1ece6;
    --ink-2: #c5bec9;
    --ink-3: #958d99;
    --rule: #332e38;
    --footer-bg: #0d0b0f;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 10px 30px -12px rgba(0, 0, 0, .6);
    --on-accent: var(--bg);
    --orange-tint: #2d211b; --magenta-tint: #2a1d27; --cyan-tint: #182429;
    color-scheme: dark;
}

/* ------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 1.0625rem/1.65 var(--sans);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--magenta-ink); }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.08; letter-spacing: -.015em; margin: 0; }
h1 em, h2 em, .hero-title em {
  font-style: normal; font-weight: inherit;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  padding: .08em .1em .2em .12em; margin: -.08em -.1em -.2em -.12em;
}
p { margin: 0 0 1em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
.muted { color: var(--ink-3); }
.label, .section-num, .card-kicker, .news-date, .pub-type, .pub-year-label, .chip, .tags li, .brand-sub, .person-role {
  font-family: var(--mono); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase;
}
.label { color: var(--ink-3); margin: 0 0 .5rem; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
.icon { flex: none; vertical-align: -0.2em; }

.prose p:last-child { margin-bottom: 0; }
.prose strong { font-weight: 600; }
.prose a { color: var(--magenta-ink); }
.prose ul { padding-left: 1.2em; }
.narrow { max-width: 60ch; margin-bottom: 2rem; }

/* acronym letters: HUMan fActors in iNteraction */
.acr { font-weight: 700; }
.acr:nth-of-type(1), .acr:nth-of-type(2) { color: var(--orange-ink); }
.acr:nth-of-type(3), .acr:nth-of-type(4) { color: var(--magenta-ink); }
.acr:nth-of-type(5) { color: var(--cyan-ink); }

/* ------------------------------------------------------------ buttons */
.btn {
  display: inline-flex; align-items: center; gap: .55em; padding: .8em 1.35em;
  border-radius: 999px; font: 600 .95rem/1 var(--sans); text-decoration: none; cursor: pointer;
  border: 1.5px solid transparent; transition: transform .2s, background .2s, color .2s, border-color .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--ink); color: var(--bg); }
.btn-primary:hover { background: var(--magenta-ink); color: var(--on-accent); }
.btn-ghost { border-color: var(--rule); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn .icon { transition: transform .2s; }
.btn:hover .icon-arrow { transform: translateX(3px); }

/* ------------------------------------------------------------ header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .3s;
}
.site-header.scrolled { border-bottom-color: var(--rule); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 76px; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-mark { width: 46px; height: 46px; flex: none; overflow: visible; }
.brand-mark .s-data { fill: var(--bg); }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name { font-family: var(--serif); font-size: 1.35rem; font-weight: 400; letter-spacing: -.01em; }
.brand-sub { font-size: .66rem; color: var(--ink-3); letter-spacing: .04em; }
.site-nav { margin-left: auto; }
.site-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.site-nav a {
  display: block; white-space: nowrap; padding: .55em .95em; border-radius: 999px; text-decoration: none;
  font-weight: 500; font-size: .95rem; color: var(--ink-2); transition: background .2s, color .2s;
}
.site-nav a:hover { background: var(--bg-tint); color: var(--ink); }
.site-nav a[aria-current="page"] { background: var(--ink); color: var(--bg); }
.header-tools { display: flex; align-items: center; gap: 6px; }
.theme-toggle {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--rule); background: var(--surface); color: var(--ink); cursor: pointer;
  transition: border-color .2s, transform .3s;
}
.theme-toggle:hover { border-color: var(--ink); transform: rotate(-15deg); }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: block; }
}
.nav-toggle { display: none; background: none; border: 0; color: var(--ink); padding: 8px; cursor: pointer; }
.nav-close { display: none; }

@media (max-width: 1120px) { .brand-sub { display: none; } }
@media (max-width: 940px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed; inset: 76px 0 auto 0; background: var(--bg); border-bottom: 1px solid var(--rule);
    padding: 12px 16px 24px; transform: translateY(-8px); opacity: 0; visibility: hidden; transition: .25s;
  }
  .site-nav ul { flex-direction: column; }
  .site-nav a { font-size: 1.15rem; padding: .8em 1em; }
  .nav-is-open .site-nav { transform: none; opacity: 1; visibility: visible; }
  .nav-is-open .nav-open { display: none; }
  .nav-is-open .nav-close { display: inline; }
  .brand-sub { display: none; }
}

/* ------------------------------------------------------------ hero */
.hero { padding: clamp(28px, 6vh, 72px) 0 clamp(8px, 2vh, 24px); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: clamp(24px, 4vw, 64px); align-items: center; }
.hero-kicker { font-family: var(--mono); font-size: .82rem; letter-spacing: .02em; color: var(--ink-2); margin-bottom: clamp(.8rem, 2.2vh, 1.4rem); }
.hero-kicker::before { content: ""; display: inline-block; width: 28px; height: 2px; background: var(--grad); vertical-align: middle; margin-right: 12px; }
.hero-title { font-size: clamp(2.3rem, min(4.6vw, 7.4vh), 4.25rem); font-weight: 400; letter-spacing: -.015em; line-height: 1.02; margin-bottom: clamp(.9rem, 2.4vh, 1.4rem); }
.hero-lead { font-size: clamp(1rem, 1.2vw, 1.15rem); color: var(--ink-2); max-width: 38em; margin-bottom: clamp(1.1rem, 3vh, 1.8rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-art { position: relative; aspect-ratio: 1 / 1; width: min(100%, 62vh, 460px); justify-self: center; }
.head-art { width: 100%; height: 100%; overflow: visible; }
.head-art .s-solid { animation: none; }
.head-art .s-data { fill: var(--bg); opacity: .95; transform-box: fill-box; transform-origin: left center; animation: grow 1.4s cubic-bezier(.2, .7, .2, 1) both, breathe 5s ease-in-out infinite alternate; animation-delay: var(--d), calc(var(--d) + 1.4s); }
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { order: -1; width: min(300px, 70vw); margin: 0 auto; }
  .hero { padding-bottom: 24px; }
}

/* home: below the hero starts faded and comes in as the visitor scrolls.
   --p goes 0 → 1 (set by main.js); without JS it stays 1 and nothing is hidden. */
.below-hero {
  --p: 1;
  -webkit-mask-image: linear-gradient(to bottom, rgb(0 0 0 / calc(.35 + .65 * var(--p))), rgb(0 0 0 / calc(.04 + .96 * var(--p))) min(45vh, 360px));
          mask-image: linear-gradient(to bottom, rgb(0 0 0 / calc(.35 + .65 * var(--p))), rgb(0 0 0 / calc(.04 + .96 * var(--p))) min(45vh, 360px));
}
.js .below-hero { --p: 0; }
.below-hero.is-revealed { -webkit-mask-image: none; mask-image: none; }

/* stripes graphic */
.s-orange { fill: var(--orange); }
.s-magenta { fill: var(--magenta); }
.s-cyan { fill: var(--cyan); }
.stripes .s-line { opacity: .55; transform-box: fill-box; transform-origin: right center; animation: grow 1.4s cubic-bezier(.2, .7, .2, 1) both; animation-delay: var(--d); }
.stripes .s-solid { transform-box: fill-box; transform-origin: right center; animation: grow 1s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes grow { from { transform: scaleX(0); } }
@keyframes breathe { to { transform: scaleX(.82); opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .stripes rect { animation: none !important; } html { scroll-behavior: auto; } }

/* ------------------------------------------------------------ sections */
.section { padding: clamp(36px, 4.5vw, 64px) 0; }
/* two sections on the same background: don't stack both paddings */
.section:not(.section-tinted) + .section:not(.section-tinted) { padding-top: 0; }
.section-tinted + .section-tinted { padding-top: 0; }
.section-flush { padding-top: 0; }
.page-hero + .section:not(.section-tinted) { padding-top: 0; }
.section-tinted { background: var(--bg-tint); }
.section-head { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 6px 24px; margin-bottom: clamp(20px, 2.6vw, 32px); }
.section-num { grid-column: 1 / -1; color: var(--ink-3); margin: 0; }
.section-num span { color: var(--ink); font-weight: 500; }
.section-head h2 { font-size: clamp(1.8rem, 3.2vw, 2.6rem); }
.more { display: inline-flex; gap: .4em; align-items: center; font-weight: 600; text-decoration: none; font-size: .95rem; white-space: nowrap; }
.more:hover .icon { transform: translateX(3px); }
.more .icon { transition: transform .2s; }
.subhead { font-size: 1.5rem; margin: 44px 0 20px; }

.page-hero { padding: clamp(36px, 6vw, 80px) 0 clamp(28px, 4vw, 56px); position: relative; }
.page-hero .section-num::before { content: ""; display: inline-block; width: 28px; height: 2px; background: var(--grad); vertical-align: middle; margin-right: 12px; }
.page-hero h1 { font-size: clamp(2.3rem, 4.8vw, 3.9rem); font-weight: 400; letter-spacing: -.015em; margin: 1rem 0 1.4rem; max-width: 16ch; }
.page-intro { font-size: clamp(1.08rem, 1.4vw, 1.22rem); color: var(--ink-2); max-width: 44em; }
.page-intro strong { color: var(--ink); }
.jump { display: flex; gap: 10px; margin-top: 2rem; flex-wrap: wrap; }
.jump a { padding: .5em 1em; border: 1px solid var(--rule); border-radius: 999px; text-decoration: none; font-weight: 500; font-size: .92rem; }
.jump a:hover { border-color: var(--ink); color: var(--ink); }
.jump sup { font-family: var(--mono); font-size: .7em; color: var(--ink-3); }

/* accents */
.accent-orange { --accent: var(--orange); --accent-ink: var(--orange-ink); --accent-deep: var(--orange-deep); --accent-tint: var(--orange-tint); }
.accent-magenta { --accent: var(--magenta); --accent-ink: var(--magenta-ink); --accent-deep: var(--magenta-deep); --accent-tint: var(--magenta-tint); }
.accent-cyan { --accent: var(--cyan); --accent-ink: var(--cyan-ink); --accent-deep: var(--cyan-deep); --accent-tint: var(--cyan-tint); }

/* research lines */
.lines-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.line-card {
  position: relative; padding: 24px 26px 24px; background: var(--surface); border-radius: var(--radius);
  border: 1px solid var(--rule); overflow: hidden;
}
.line-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--accent); }
.line-index { font-family: var(--serif); font-size: 2.6rem; line-height: 1; color: var(--accent); font-weight: 400; }
.line-card h3 { font-size: 1.4rem; margin: 10px 0 8px; }
.line-card .prose { color: var(--ink-2); font-size: 1rem; }

/* ------------------------------------------------------------ news */
.news-list { display: flex; flex-direction: column; }
.news-item {
  display: grid; grid-template-columns: 130px 1fr; gap: 8px 32px; padding: 20px 0;
  border-top: 1px solid var(--rule);
}
.news-item:last-child { border-bottom: 1px solid var(--rule); }
.news-item.has-img { grid-template-columns: 130px 1fr 200px; }
.news-date { color: var(--magenta-ink); padding-top: .3em; }
.news-body h3 { font-size: 1.3rem; margin-bottom: .4rem; }
.news-body .prose { color: var(--ink-2); max-width: 62ch; }
.news-body .prose strong, .news-body .prose em { color: var(--ink); }
.news-link { display: inline-flex; gap: .35em; align-items: center; margin-top: .6rem; font-weight: 600; font-size: .9rem; text-decoration: none; color: var(--cyan-ink); }
.news-img { width: 200px; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; }
.news-year { display: grid; grid-template-columns: 160px 1fr; gap: 24px; margin-bottom: 40px; }
.news-year-label { font-size: 3rem; font-weight: 400; position: sticky; top: 100px; align-self: start; color: var(--ink-3); }
@media (max-width: 760px) {
  .news-item, .news-item.has-img { grid-template-columns: 1fr; }
  .news-img { width: 100%; max-width: 420px; }
  .news-year { grid-template-columns: 1fr; gap: 0; }
  .news-year-label { position: static; font-size: 2.2rem; margin-bottom: 12px; }
}

/* ------------------------------------------------------------ cards */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 24px; }
.cards-compact { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.card {
  display: flex; flex-direction: column; background: var(--surface); border-radius: var(--radius);
  border: 1px solid var(--rule); overflow: hidden; transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card-media { position: relative; aspect-ratio: 16 / 9; background: var(--bg-tint); border-bottom: 4px solid var(--accent); }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-placeholder { position: absolute; inset: 0; display: flex; align-items: center; padding: 18px 0; }
.card-placeholder .stripes { width: 100%; height: 100%; }
.chip { position: absolute; top: 14px; left: 14px; background: var(--surface); color: var(--ink); padding: .35em .75em; border-radius: 999px; font-size: .66rem; }
.chip.live::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #3fbf7f; margin-right: 6px; box-shadow: 0 0 0 3px rgba(63, 191, 127, .2); vertical-align: 1px; }
.card-body { padding: 24px 26px 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-kicker { color: var(--accent-ink); margin: 0; font-weight: 500; }
.card h3 { font-size: 1.4rem; }
.card-summary { color: var(--ink-2); font-size: .98rem; margin: 0; }
.card.compact { border-top: 4px solid var(--accent); }
.card.compact .card-body { padding: 20px 22px; }
.card.compact h3 { font-size: 1.15rem; }
.card-more summary { cursor: pointer; font-weight: 600; font-size: .9rem; color: var(--accent-ink); }
.card-more .prose { font-size: .95rem; color: var(--ink-2); margin-top: .6rem; }
.card-meta { margin: 6px 0 0; display: grid; gap: 4px; font-size: .88rem; }
.card-meta div { display: grid; grid-template-columns: 76px 1fr; gap: 10px; }
.card-meta dt { font-family: var(--mono); font-size: .7rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); padding-top: .2em; }
.card-meta dd { margin: 0; color: var(--ink-2); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 4px 0 0; padding: 0; }
.tags li { font-size: .65rem; padding: .3em .7em; border-radius: 999px; background: var(--bg-tint); color: var(--ink-2); }
.card-link { margin-top: auto; padding-top: 8px; display: inline-flex; align-items: center; gap: .35em; font-weight: 600; font-size: .9rem; text-decoration: none; color: var(--accent-ink); }

/* project poster tiles */
.cards:has(.poster) { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.poster {
  position: relative; display: flex; flex-direction: column; gap: 10px; min-height: 360px; padding: 22px 22px 24px;
  border-radius: 20px; overflow: hidden; isolation: isolate;
  background: var(--accent-deep); color: #fff;
  transition: transform .3s cubic-bezier(.2, .7, .2, 1), box-shadow .3s;
}
.poster:hover { transform: translateY(-4px) rotate(-.4deg); box-shadow: var(--shadow); }
.poster-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -1; opacity: .22; mix-blend-mode: luminosity; }
.poster-art { position: absolute; right: -36px; top: 16px; width: 190px; height: 105px; opacity: .28; z-index: -1; }
.poster-art svg { width: 100%; height: 100%; display: block; }
.poster-status { display: inline-flex; align-items: center; gap: 7px; margin: 0; font: 500 .68rem var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.poster-status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px rgba(255, 255, 255, .25); }
.poster-acr {
  font-size: clamp(1.55rem, 2.3vw, 2rem); line-height: 1.05; letter-spacing: -.005em; margin: 4px 0 0;
  overflow-wrap: break-word; hyphens: auto; max-width: 92%;
}
.poster-body { margin-top: auto; padding-top: 24px; display: flex; flex-direction: column; gap: 8px; }
.poster-title { font-weight: 600; font-size: 1rem; line-height: 1.3; margin: 0; }
.poster-summary { font-size: .9rem; line-height: 1.5; margin: 0; color: rgba(255, 255, 255, .92); }
.poster-more summary { cursor: pointer; font-weight: 600; font-size: .86rem; list-style: none; display: inline-flex; gap: 6px; align-items: center; }
.poster-more summary::-webkit-details-marker { display: none; }
.poster-more summary::before { content: "+"; font-family: var(--mono); width: 1em; }
.poster-more[open] summary::before { content: "–"; }
.poster-more .prose { font-size: .88rem; margin-top: 8px; color: rgba(255, 255, 255, .92); }
.poster-more .prose a { color: #fff; }
.poster-meta { margin: 10px 0 0; display: grid; gap: 4px; font-size: .84rem; }
.poster-meta div { display: grid; grid-template-columns: 70px 1fr; gap: 8px; }
.poster-meta dt { font: 500 .64rem var(--mono); text-transform: uppercase; letter-spacing: .06em; opacity: .75; padding-top: .25em; }
.poster-meta dd { margin: 0; }
.poster-tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 4px 0 0; padding: 0; }
.poster-tags li { font: 500 .62rem var(--mono); text-transform: uppercase; letter-spacing: .05em; padding: .3em .7em; border-radius: 999px; background: rgba(255, 255, 255, .16); }
.poster-link { display: inline-flex; gap: .35em; align-items: center; font-weight: 600; font-size: .88rem; color: #fff; text-decoration: none; margin-top: 2px; }
.poster-link:hover { color: #fff; text-decoration: underline; }
.poster :focus-visible { outline-color: #fff; }
/* completed projects: tinted, smaller */
.poster.is-past { background: var(--accent-tint); color: var(--ink); min-height: 220px; }
.poster.is-past .poster-status, .poster.is-past .poster-acr { color: var(--accent-ink); }
.poster.is-past .poster-status::before { box-shadow: none; }
.poster.is-past .poster-summary { color: var(--ink-2); }
.poster.is-past .poster-art { color: var(--accent); opacity: .35; }
.poster.is-past .poster-acr { font-size: clamp(1.35rem, 1.9vw, 1.6rem); }
@media (prefers-reduced-motion: reduce) { .poster, .poster:hover { transition: none; transform: none; } }

/* ------------------------------------------------------------ publications */
.pub-tools { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 14px; }
.pub-search { flex: 1 1 280px; display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--rule); border-radius: 999px; padding: 0 18px; color: var(--ink-3); }
.pub-search:focus-within { border-color: var(--ink); }
.pub-search input { flex: 1; border: 0; background: none; font: inherit; color: var(--ink); padding: .75em 0; outline: none; min-width: 0; }
.pub-filters { display: flex; flex-wrap: wrap; gap: 6px; }
.filter, #pub-year {
  font: 500 .88rem/1 var(--sans); padding: .7em 1em; border-radius: 999px; border: 1px solid var(--rule);
  background: var(--surface); color: var(--ink-2); cursor: pointer;
}
.filter:hover { border-color: var(--ink-3); }
.filter.is-on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.pub-count { font-family: var(--mono); font-size: .75rem; color: var(--ink-3); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 18px; }
.pub-year { display: grid; grid-template-columns: 120px 1fr; gap: 24px; border-top: 2px solid var(--ink); padding-top: 18px; margin-bottom: 40px; }
.pub-year-label { font-family: var(--serif); font-size: 2.2rem; font-weight: 400; letter-spacing: -.02em; text-transform: none; position: sticky; top: 96px; align-self: start; }
.pub-list { list-style: none; margin: 0; padding: 0; }
.pub { display: grid; grid-template-columns: 104px 1fr; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--rule); }
.pub:last-child { border-bottom: 0; }
.pub-type { align-self: start; justify-self: start; font-size: .62rem; padding: .35em .65em; border-radius: 6px; border: 1px solid currentColor; margin-top: .25em; }
.type-journal .pub-type { color: var(--magenta-ink); }
.type-conference .pub-type { color: var(--cyan-ink); }
.type-book .pub-type, .type-chapter .pub-type { color: var(--orange-ink); }
.type-thesis .pub-type, .type-other .pub-type { color: var(--ink-3); }
.pub-title { font-family: var(--serif); font-size: 1.18rem; font-weight: 400; line-height: 1.3; margin: 0 0 .3em; letter-spacing: -.005em; }
.pub-title a { text-decoration: none; background-image: linear-gradient(var(--magenta), var(--magenta)); background-size: 0 1px; background-repeat: no-repeat; background-position: 0 100%; transition: background-size .3s; }
.pub-title a:hover { background-size: 100% 1px; color: inherit; }
.pub-authors { font-size: .93rem; color: var(--ink-2); margin: 0 0 .15em; }
.pub-authors strong { color: var(--ink); font-weight: 600; }
.pub-venue { font-size: .9rem; color: var(--ink-3); margin: 0; }
.pub-venue em { color: var(--ink-2); }
.pub-actions { display: flex; gap: 14px; margin-top: .5em; font-size: .8rem; }
.pub-actions a, .bib-btn { display: inline-flex; gap: .3em; align-items: center; font: 500 .8rem/1 var(--mono); color: var(--ink-3); text-decoration: none; background: none; border: 0; padding: 0; cursor: pointer; text-transform: uppercase; letter-spacing: .04em; }
.pub-actions a:hover, .bib-btn:hover { color: var(--magenta-ink); }
.bib-btn.copied { color: #2e9d64; }
.pub.featured .pub-title::after { content: "★"; color: var(--orange); font-size: .8em; margin-left: .4em; }
@media (max-width: 760px) {
  .pub-year { grid-template-columns: 1fr; gap: 6px; }
  .pub-year-label { position: static; font-size: 1.8rem; }
  .pub { grid-template-columns: 1fr; gap: 6px; }
}

/* ------------------------------------------------------------ about */
.about-hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(24px, 5vw, 64px); align-items: end; }
.team-photo { margin: 0; position: relative; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.team-photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.team-photo .band-rule { height: 6px; }
.team-photo figcaption {
  position: absolute; left: 14px; bottom: 20px; padding: .45em .9em; border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  font-family: var(--mono); font-size: .68rem; color: var(--ink); text-transform: uppercase; letter-spacing: .06em;
}
@media (max-width: 860px) { .about-hero { grid-template-columns: 1fr; } }

.people { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 32px 20px; }
.person-photo { aspect-ratio: 1; border-radius: 50%; overflow: hidden; background: var(--surface); margin-bottom: 14px; position: relative; border: 1px solid var(--rule); }
.person-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.person:hover .person-photo img { transform: scale(1.05); }
.person:nth-child(3n+1) .person-photo { box-shadow: 0 0 0 0 var(--orange); }
.person-photo { transition: box-shadow .3s; }
.person:nth-child(3n+1):hover .person-photo { box-shadow: 0 0 0 4px var(--orange); }
.person:nth-child(3n+2):hover .person-photo { box-shadow: 0 0 0 4px var(--magenta); }
.person:nth-child(3n):hover .person-photo { box-shadow: 0 0 0 4px var(--cyan); }
.initials { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--serif); font-size: 2.4rem; color: var(--ink-3); }
.person-name { font-family: var(--serif); font-size: 1.12rem; font-weight: 400; margin: 0 0 .2em; line-height: 1.2; }
.person-name a { text-decoration: none; }
.person-role { color: var(--ink-3); margin: 0; font-size: .68rem; }
.person-extra { font-size: .82rem; color: var(--magenta-ink); margin: .2em 0 0; }

.alumni { margin-top: 44px; padding-top: 24px; border-top: 1px solid var(--rule); }
.alumni-title { font-size: 1.5rem; margin-bottom: 22px; }
.alumni-title span { font-family: var(--mono); font-size: .8rem; color: var(--ink-3); font-weight: 400; margin-left: 6px; }
.alumni-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px 20px; }
.alum { display: flex; align-items: center; gap: 12px; }
.alum { position: relative; }
.alum-photo {
  position: relative; flex: none; width: 46px; height: 46px; border-radius: 50%; overflow: hidden;
  background: var(--surface); border: 1px solid var(--rule);
  transition: transform .35s cubic-bezier(.2, .8, .2, 1.15), box-shadow .35s, border-color .35s;
}
.alum-photo img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.05); opacity: .9; transition: filter .35s, opacity .35s; }
/* hover: a magnifier "peek" — the portrait grows over its neighbours, in colour, with a brand-colour ring */
.alum:hover { z-index: 3; }
.alum:hover .alum-photo {
  transform: scale(2.4); border-color: transparent; z-index: 3;
  box-shadow: 0 0 0 1.5px var(--ring, var(--magenta)), 0 10px 24px -6px rgba(23, 20, 27, .45);
}
.alum:hover .alum-photo img { filter: none; opacity: 1; }
.alum:nth-child(3n+1) { --ring: var(--orange); }
.alum:nth-child(3n+2) { --ring: var(--magenta); }
.alum:nth-child(3n) { --ring: var(--cyan); }
.alum-name { transition: color .25s; }
.alum:hover .alum-name { color: var(--ring); }
.alum-text { transition: transform .35s cubic-bezier(.2, .8, .2, 1); }
.alum:hover .alum-text { transform: translateX(34px); }
@media (prefers-reduced-motion: reduce) {
  .alum-photo, .alum-text { transition: none; }
  .alum:hover .alum-photo { transform: none; }
  .alum:hover .alum-text { transform: none; }
}
.alum-photo .initials { font-size: 1rem; }
.alum-text { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.alum-name { font-size: .95rem; font-weight: 500; }
.alum-role { font-family: var(--mono); font-size: .64rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); }

.partners { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.partner-card {
  position: relative; display: flex; flex-direction: column; height: 100%; text-decoration: none; color: var(--ink);
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius); overflow: hidden;
  transition: transform .25s, box-shadow .25s, border-color .25s;
}
.partner-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--accent); transform: scaleX(.18); transform-origin: left; transition: transform .35s cubic-bezier(.2, .7, .2, 1); z-index: 1; }
.partner-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--accent) 45%, var(--rule)); color: var(--ink); }
.partner-card:hover::before { transform: scaleX(1); }
.partner-logo { display: grid; place-items: center; aspect-ratio: 16 / 9; padding: 22px 26px; background: #fff; }
.partner-logo img { max-height: 64px; max-width: 100%; width: auto; object-fit: contain; transition: transform .3s; }
.partner-card:hover .partner-logo img { transform: scale(1.06); }
.partner-name { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; padding: 14px 16px 16px; font-size: .9rem; font-weight: 500; line-height: 1.3; border-top: 1px solid var(--rule); }
.partner-name .icon { color: var(--ink-3); margin-top: 2px; }
.partner-card:hover .partner-name .icon { color: var(--accent-ink); }

.join { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 64px); padding: clamp(32px, 5vw, 64px); border-radius: calc(var(--radius) * 1.5); background: var(--footer-bg); color: var(--footer-ink); position: relative; overflow: hidden; }
.join::after { content: ""; position: absolute; right: -60px; top: -60px; width: 260px; height: 260px; border-radius: 50%; background: conic-gradient(from 200deg, var(--orange), var(--magenta), var(--cyan), var(--orange)); filter: blur(60px); opacity: .55; }
.join > * { position: relative; z-index: 1; }
.join h2 { font-size: clamp(2rem, 4vw, 3rem); margin-top: 1rem; }
.join .section-num, .join .section-num span { color: #b6aebb; }
.join .prose { color: #d4cdd8; margin-bottom: 1.6rem; }
.join .prose a { color: #f0b7dd; }
.join .btn-primary { background: var(--footer-ink); color: var(--footer-bg); }
.join .btn-primary:hover { background: var(--magenta); color: #fff; }
@media (max-width: 760px) { .join { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------ instagram band */
.insta-band {
  display: grid; grid-template-columns: auto 1fr auto; gap: 24px; align-items: center; text-decoration: none;
  padding: 28px 32px; border-radius: calc(var(--radius) * 1.4); color: #fff;
  background: linear-gradient(110deg, var(--orange), var(--magenta) 55%, var(--cyan));
  transition: transform .25s, box-shadow .25s;
}
.insta-band:hover { color: #fff; transform: translateY(-2px); box-shadow: var(--shadow); }
.insta-copy { display: flex; flex-direction: column; gap: 2px; }
.insta-copy strong { font-family: var(--serif); font-size: 1.6rem; font-weight: 400; }
.insta-copy span { opacity: .92; }
.insta-handle { font-family: var(--mono); font-size: .9rem; display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; }
@media (max-width: 760px) { .insta-band { grid-template-columns: 1fr; gap: 12px; } }

/* ------------------------------------------------------------ contact */
.contact-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.contact-block { padding: 26px 0; border-top: 1px solid var(--rule); }
.contact-block:first-child { border-top: 0; padding-top: 0; }
.contact-block address { font-style: normal; color: var(--ink-2); margin-bottom: .6rem; }
.contact-big { font-family: var(--serif); font-weight: 400; font-size: clamp(1.3rem, 2.2vw, 1.75rem); margin: 0; word-break: break-word; }
.contact-big a { text-decoration: none; background: var(--grad) 0 100% / 100% 2px no-repeat; padding-bottom: 2px; }
.text-link { display: inline-flex; gap: .35em; align-items: center; font-weight: 600; font-size: .92rem; text-decoration: none; color: var(--cyan-ink); }
.profile-links { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.profile-links a {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 14px 16px;
  border: 1px solid var(--rule); border-radius: 12px; text-decoration: none; background: var(--surface); font-weight: 500;
  transition: border-color .2s, transform .2s;
}
.profile-links a:hover { border-color: var(--ink); color: var(--ink); transform: translateY(-1px); }
.pl-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--bg-tint); color: var(--ink); }
.profile-links li:nth-child(3n+1) .pl-icon { color: var(--orange-ink); }
.profile-links li:nth-child(3n+2) .pl-icon { color: var(--magenta-ink); }
.profile-links li:nth-child(3n) .pl-icon { color: var(--cyan-ink); }
.pl-arrow { color: var(--ink-3); }

.contact-form { background: var(--surface); border: 1px solid var(--rule); border-radius: calc(var(--radius) * 1.4); padding: clamp(24px, 4vw, 44px); box-shadow: var(--shadow); position: relative; }
.contact-form::before { content: ""; position: absolute; top: -1px; left: 32px; right: 32px; height: 4px; background: var(--grad); border-radius: 0 0 4px 4px; }
.contact-form h2 { font-size: 1.9rem; margin-bottom: 24px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); margin-bottom: 6px; }
.field input, .field textarea, .field select {
  width: 100%; font: inherit; color: var(--ink); background: var(--bg); border: 1px solid var(--rule); border-radius: 10px;
  padding: .75em .9em; transition: border-color .2s, box-shadow .2s;
}
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--magenta); box-shadow: 0 0 0 3px color-mix(in srgb, var(--magenta) 18%, transparent); }
.field textarea { resize: vertical; min-height: 140px; }
.hp { position: absolute; left: -9999px; }
.form-status { margin: 14px 0 0; font-weight: 500; min-height: 1.5em; }
.form-status.ok { color: #2e9d64; }
.form-status.err { color: #c2412d; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .profile-links { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------ footer */
.site-footer { background: var(--footer-bg); color: var(--footer-ink); margin-top: 0; }
.band-rule { display: flex; height: 6px; }
.band-rule i { flex: 1; }
.band-rule .o { background: var(--orange); } .band-rule .m { background: var(--magenta); } .band-rule .c { background: var(--cyan); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; padding-top: 64px; padding-bottom: 48px; }
.footer-name { font-family: var(--serif); font-size: 2.2rem; font-weight: 400; margin: 0 0 .2em; letter-spacing: -.02em; }
.footer-full { font-family: var(--mono); font-size: .85rem; color: #b6aebb; margin: 0 0 .3em; }
.footer-full .acr:nth-of-type(n) { color: inherit; }
.footer-full .acr:nth-of-type(1), .footer-full .acr:nth-of-type(2) { color: var(--orange); }
.footer-full .acr:nth-of-type(3), .footer-full .acr:nth-of-type(4) { color: #d98cc4; }
.footer-full .acr:nth-of-type(5) { color: var(--cyan); }
.footer-aff { color: #8f8794; font-size: .9rem; }
.site-footer .label { color: #8f8794; }
.site-footer address { font-style: normal; color: #cfc7d3; font-size: .95rem; }
.site-footer a { color: #e7e0ea; text-decoration: none; }
.site-footer a:hover { color: #fff; }
.footer-col p { font-size: .95rem; }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: .95rem; }
.footer-links a { display: inline-flex; gap: 10px; align-items: center; }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding-top: 22px; padding-bottom: 28px; border-top: 1px solid #2c2731; font-size: .82rem; color: #8f8794; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }

/* ------------------------------------------------------------ misc */
.notfound { min-height: 50vh; }
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }
@media print {
  .site-header, .site-footer, .pub-tools, .hero-art, .insta-band { display: none !important; }
  body { background: #fff; color: #000; }
}

/* overflow safety on small screens */
.hero-grid > *, .contact-grid > *, .about-hero > *, .join > *, .section-head > * { min-width: 0; }
h1, h2, h3, .contact-big { overflow-wrap: break-word; }
body { overflow-x: hidden; }
@media (max-width: 520px) { .section-head { grid-template-columns: 1fr; } .section-head .more { justify-self: start; } }
