:root {
  --paper: #f4f6f8;
  --mist: #e4e9ef;
  --line: #c6cfd9;
  --ink: #0f1b2d;
  --ink-soft: #44536a;
  --blue: #004c9b;
  --navy: #002d72;
  --night: #0a1a33;
  --signal: #ffdc00;
  --white: #ffffff;
  --stencil: "Big Shoulders Stencil Display", Impact, sans-serif;
  --text: "Public Sans", system-ui, sans-serif;
  --measure: 68ch;
  --gutter: clamp(16px, 4vw, 56px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.6 var(--text);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--navy); }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.hero-wrap :focus-visible, .band-ink :focus-visible, .foot :focus-visible { outline-color: var(--signal); }

.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--white); padding: 8px 14px; z-index: 10; }
.skip:focus { left: 8px; }

h1, h2, h3 { font-family: var(--stencil); font-weight: 800; line-height: 1.02; margin: 0; letter-spacing: 0.01em; }
h2 { font-size: clamp(40px, 6vw, 72px); }
h3 { font-size: 26px; font-weight: 600; }

/* header */
.top {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 10px var(--gutter);
  background: rgba(244, 246, 248, 0.95);
  backdrop-filter: blur(6px);
  border-bottom: 3px solid var(--signal);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 15px; }
.brand img { border-radius: 50%; background: var(--white); }
.top nav { display: flex; gap: 22px; flex-wrap: wrap; }
.top nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; }
.top nav a:hover { color: var(--blue); }
.top .menu { display: none; align-items: center; gap: 8px; border: 1px solid var(--line, #d5dbe3); background: var(--white, #fff); color: var(--ink); font: 700 14px/1 var(--text, inherit); padding: 9px 12px; border-radius: 999px; cursor: pointer; }
.top .menu .bars { display: grid; gap: 3px; width: 16px; }
.top .menu .bars i { display: block; height: 2px; background: currentColor; border-radius: 2px; transition: transform 0.3s ease, opacity 0.2s ease; }
.top.open .menu .bars i:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.top.open .menu .bars i:nth-child(2) { opacity: 0; }
.top.open .menu .bars i:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }
@media (max-width: 860px) {
  .top .menu { display: inline-flex; }
  .top nav { position: absolute; left: 0; right: 0; top: 100%; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 16px; padding: 10px var(--gutter) 18px; background: #f4f6f8; z-index: 6; border-bottom: 3px solid var(--signal); box-shadow: 0 16px 30px -18px rgba(10, 26, 51, 0.45); visibility: hidden; opacity: 0; transform: translateY(-8px); transition: opacity 0.25s ease, transform 0.3s ease, visibility 0s 0.3s; }
  .top.open nav { visibility: visible; opacity: 1; transform: none; transition: opacity 0.25s ease, transform 0.3s ease, visibility 0s; }
  .top nav a { padding: 12px 4px; font-size: 16px; border-bottom: 1px solid rgba(10, 26, 51, 0.08); }
}
@media (prefers-reduced-motion: reduce) { .top nav, .top .menu .bars i { transition: none !important; } }

/* hero */
.hero {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 72px);
  align-items: center;
  padding: clamp(40px, 8vw, 110px) var(--gutter) clamp(40px, 6vw, 80px);
  max-width: 1320px; margin: 0 auto;
}
.hero-wrap { background: var(--night); color: var(--white); }
.where { margin: 0 0 18px; font-weight: 600; color: var(--signal); }
.hero h1 { font-size: clamp(54px, 8.4vw, 120px); max-width: 11ch; }
.lede { max-width: 56ch; font-size: 19px; margin: 28px 0 32px; color: #c9d4e3; }
.hero-links { display: flex; gap: 14px; flex-wrap: wrap; margin: 0; }
.hero-links a {
  display: inline-block; padding: 12px 22px; font-weight: 700; text-decoration: none;
  border: 2px solid var(--white); color: var(--white);
}
.hero-links a:first-child { background: var(--signal); border-color: var(--signal); color: var(--night); }
.hero-links a:hover { background: var(--white); border-color: var(--white); color: var(--night); }

.hero-mark { margin: 0; min-width: 0; }
.chart-box { position: relative; }
#pubChart { display: block; width: 100%; max-width: 560px; height: auto; overflow: visible; }
.hero-mark figcaption { max-width: 52ch; margin: 14px 0 0; font-size: 14px; color: #a9b7ca; }
#pubChart .bar { fill: var(--signal); }
#pubChart .grid { stroke: rgba(201, 212, 227, 0.14); stroke-width: 1; }
#pubChart .axis { stroke: rgba(201, 212, 227, 0.45); stroke-width: 1; }
#pubChart .tick, #pubChart .gl { fill: #a9b7ca; font: 600 12px var(--text); }
#pubChart .pk { fill: var(--white); font: 800 18px var(--stencil); }
#pubChart .hit { fill: transparent; cursor: pointer; outline: none; }
#pubChart .hit:focus-visible { fill: rgba(255, 220, 0, 0.12); }
#pubChart.grow .bars { transform-origin: 0 270px; animation: rise 0.9s cubic-bezier(.2,.7,.2,1) both; }
@keyframes rise { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.tip { position: absolute; top: 0; transform: translate(-50%, calc(-100% - 10px)); background: var(--white); color: var(--night); font-weight: 700; font-size: 14px; padding: 6px 10px; white-space: nowrap; pointer-events: none; font-variant-numeric: tabular-nums; }
.hero-mark .stat { display: block; font-family: var(--stencil); font-weight: 800; font-size: clamp(20px, 2.4vw, 26px); color: var(--signal); margin-bottom: 4px; }
.chart-table { margin: 12px 0 0; font-size: 14px; color: #c9d4e3; max-width: 520px; }
.chart-table summary { cursor: pointer; font-weight: 600; list-style: none; display: inline-flex; align-items: center; gap: 8px; }
.chart-table summary::-webkit-details-marker { display: none; }
.chart-table summary::before { content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); transition: transform 0.25s ease; }
.chart-table[open] summary::before { transform: rotate(45deg); }
.chart-table .grid-wrap { margin-top: 10px; animation: grid-in 0.35s ease both; }
@keyframes grid-in { from { opacity: 0; transform: translateY(-4px); } }
.chart-table table { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 3px; font-variant-numeric: tabular-nums; font-size: 13px; }
.chart-table th { font-weight: 600; color: #8fa0b6; text-align: center; padding: 0 0 2px; }
.chart-table thead th:first-child { width: 3.4em; }
.chart-table tbody th { text-align: left; font-size: 12.5px; white-space: nowrap; }
.chart-table thead th:last-child, .chart-table td.sum { width: 3.2em; }
.chart-table td { height: 28px; text-align: center; border-radius: 4px; color: var(--white); font-weight: 700; background: rgba(255, 220, 0, calc(0.1 + var(--k, 0) * 0.85)); }
.chart-table td.hot { color: var(--night); }
.chart-table td.zero { background: rgba(201, 212, 227, 0.07); }
.chart-table td.off { background: none; }
.chart-table td.sum { background: none; color: var(--signal); font-family: var(--stencil); font-size: 17px; text-align: right; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { .chart-table .grid-wrap { animation: none; } .chart-table summary::before { transition: none; } }
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
  #pubChart { max-width: 480px; }
}

/* bands */
.band { padding: clamp(56px, 8vw, 104px) var(--gutter); }
.band > * { max-width: 1240px; margin-inline: auto; }
.band-alt { background: var(--mist); }
.band-ink { background: var(--night); color: var(--paper); }
.band-ink a { color: var(--signal); }
.head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px 48px; align-items: end; margin-bottom: 40px; }
.head p { margin: 0; max-width: 52ch; color: inherit; opacity: 0.85; }
@media (max-width: 800px) { .head { grid-template-columns: 1fr; } }

/* invitation to the 3D dig */
.dig-invite { background: var(--mist); }
.dig-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.dig-shot { position: relative; display: block; background: var(--night); border-bottom: 8px solid var(--signal); }
.dig-shot img { display: block; width: 100%; height: auto; }
.dig-play { position: absolute; right: 16px; bottom: 16px; background: var(--signal); color: var(--night); font-weight: 700; font-size: 15px; padding: 8px 14px; }
.dig-shot:hover .dig-play { background: var(--white); }
.dig-copy h2 { margin-bottom: 14px; }
.dig-copy > p { max-width: 52ch; margin: 0 0 18px; }
.dig-floors { list-style: none; padding: 0; margin: 0 0 24px; border-left: 4px solid var(--blue); }
.dig-floors li { display: grid; grid-template-columns: 108px minmax(0, 1fr); gap: 8px; padding: 6px 0 6px 16px; font-weight: 600; }
.dig-floors li + li { border-top: 1px solid var(--line); }
.dig-floors span { font-weight: 700; color: var(--blue); }
@media (max-width: 480px) { .dig-floors li { grid-template-columns: 1fr; gap: 0; } }
.dig-cta a:first-child { background: var(--night); border-color: var(--night); color: var(--white); }
.dig-cta a:hover { background: var(--blue); border-color: var(--blue); color: var(--white); }
@media (max-width: 860px) { .dig-grid { grid-template-columns: minmax(0, 1fr); } }

/* projects */
.projects { list-style: none; padding: 0; margin-block: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 56px; }
.project { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 22px; padding: 28px 0; border-top: 2px solid var(--ink); }
.project h3 { font-size: 28px; margin-bottom: 10px; }
.project p { margin: 0 0 10px; max-width: var(--measure); }
.project .meta { font-size: 14px; color: var(--ink-soft); }
.tag { border-left: 6px solid var(--signal); padding: 2px 0 2px 14px; align-self: start; }
.tag .yrs { display: block; font-family: var(--stencil); font-weight: 800; font-size: 30px; line-height: 1.05; color: var(--blue); }
.tag .area { display: block; margin-top: 6px; font-size: 14px; font-weight: 600; color: var(--ink-soft); }
@media (max-width: 1000px) { .projects { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 520px) { .project { grid-template-columns: minmax(0, 1fr); } }

/* people */
.director { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; align-items: start; margin-bottom: 48px; }
.director img { width: 240px; height: 300px; object-fit: cover; filter: grayscale(1) contrast(1.05); border-bottom: 8px solid var(--signal); }
.director h3 { font-size: 40px; }
.director .role { font-weight: 600; color: var(--blue); margin: 6px 0 14px; }
.director p { max-width: var(--measure); }
@media (max-width: 640px) { .director { grid-template-columns: 1fr; } }

.tools { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-bottom: 28px; }
.tools > label:first-child { font-weight: 700; }
.tools input[type="search"] {
  font: inherit; padding: 10px 14px; min-width: min(320px, 100%);
  border: 2px solid var(--ink); background: var(--white); color: var(--ink);
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button {
  font: 600 14px var(--text); padding: 7px 12px; cursor: pointer;
  border: 2px solid var(--ink); background: transparent; color: var(--ink);
}
.chips button[aria-pressed="true"] { background: var(--ink); color: var(--white); }
.chips button:hover { border-color: var(--blue); }
.check { display: flex; gap: 8px; align-items: center; font-weight: 600; }
.check input { width: 18px; height: 18px; accent-color: var(--blue); }

.people .group { margin-bottom: 40px; }
.people h3 { font-size: 30px; padding-bottom: 8px; border-bottom: 2px solid var(--ink); margin-bottom: 4px; }
.people h3 small { font-family: var(--text); font-size: 15px; font-weight: 600; color: var(--blue); margin-left: 8px; }
.people ul { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 0 32px; }
.people li { padding: 12px 0; border-bottom: 1px solid var(--line); }
.people .n { font-weight: 700; }
.people .n a { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.people .n a:hover { color: var(--blue); }
.people .r { display: block; font-size: 14px; color: var(--blue); }
.people .t { display: block; font-size: 14px; color: var(--ink-soft); }
.mdm { max-width: var(--measure); color: var(--ink-soft); font-size: 15px; }
.empty { font-weight: 600; }

/* publications */
.pubs .yr { font-family: var(--stencil); font-size: 36px; font-weight: 800; color: var(--blue); margin: 28px 0 4px; }
.pubs ul { list-style: none; padding: 0; margin: 0; }
.pubs li { padding: 10px 0; border-bottom: 1px solid var(--line); max-width: 90ch; }
.pubs .pt { font-weight: 600; }
.pubs .key::before { content: ""; display: inline-block; width: 10px; height: 10px; margin-right: 8px; background: var(--blue); transform: rotate(45deg); }
.pubs .pm { display: block; font-size: 14px; color: var(--ink-soft); }
.pubs .cites { display: inline-block; margin-top: 4px; font-size: 12.5px; font-weight: 700; color: var(--blue); background: rgba(0, 45, 114, 0.07); padding: 2px 8px; border-radius: 999px; font-variant-numeric: tabular-nums; animation: cites-in 0.4s ease both; }
@keyframes cites-in { from { opacity: 0; } }
.more { margin-top: 20px; font: 700 15px var(--text); padding: 10px 18px; border: 2px solid var(--ink); background: transparent; cursor: pointer; }
.more:hover { background: var(--ink); color: var(--white); }

/* timeline: a real sequence, so it is numbered by year */
.timeline { list-style: none; padding: 0; margin-block: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0 32px; }
.timeline li { padding: 18px 0 22px; border-top: 2px solid rgba(231, 232, 229, 0.35); }
.timeline .y { display: block; font-family: var(--stencil); font-weight: 800; font-size: 44px; color: var(--signal); line-height: 1; margin-bottom: 8px; }
.timeline p { margin: 0; font-size: 16px; }

/* partners and news */
.partners { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 28px 40px; }
.partners h3 { font-size: 24px; margin-bottom: 10px; }
.partners ul { list-style: none; margin: 0; padding: 0; }
.partners li { padding: 4px 0; font-size: 15px; }
.sub { font-size: 36px; margin: 64px auto 16px; }
.news { list-style: none; padding: 0; margin-block: 0; columns: 2 380px; column-gap: 48px; }
.news li { break-inside: avoid; padding: 10px 0; border-bottom: 1px solid var(--line); }
.news .d { display: block; font-size: 14px; color: var(--blue); font-weight: 600; }

/* join */
.join { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; }
.join h3 { margin-bottom: 10px; }
.join p { margin: 0 0 10px; }
@media (max-width: 860px) { .join { grid-template-columns: 1fr; } }

.foot { padding: 32px var(--gutter); background: var(--night); color: #a9b7ca; font-size: 14px; }
.foot p { max-width: 1240px; margin: 0 auto 6px; }
