/*
 * DiSC lab — recreates the look of the original Squarespace 7.0 template.
 * Measurements were taken from the live site at a 1280px-wide viewport.
 *
 * Fonts: the same as the Squarespace site. Proxima Nova, Adobe Garamond Pro and Effra
 * come from the lab's Adobe Fonts web project (kit xtb8lri, linked in
 * _layouts/default.html); Montserrat comes from Google Fonts.
 */
:root {
  --font-sans: "proxima-nova", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-serif: "adobe-garamond-pro", Garamond, "Times New Roman", serif;
  --font-banner-title: "Montserrat", "Helvetica Neue", Arial, sans-serif;
  --font-banner-sub: "effra", "Helvetica Neue", Arial, sans-serif;
  --ls-title: 1px;
  --ls-caps: 2px;
  --ls-serif: 0;

  --text: #000;
  --heading: rgba(26, 26, 26, 0.9);
  --muted: rgba(26, 26, 26, 0.4);
  --link: #3d9991;
  --folder-label: #00746b;
  --rule: rgba(0, 0, 0, 0.15);
  --header-bg: #212121;
  --prefooter-bg: #f7f7f7;
  --footer-bg: #1f1f1f;
  --footer-text: rgba(255, 255, 255, 0.4);
  --content: 980px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: #fff; color: var(--text);
  font: 400 18px/1.6 var(--font-serif); letter-spacing: var(--ls-serif);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--link); text-decoration: none; }
/* Like the live site, body links don't change on hover; only list titles, list tags and the
   folder sidebar do (below). */
p { margin: 0 0 18px; }
strong { font-weight: 700; }
hr { border: 0; border-top: 1px solid var(--rule); margin: 32px 0; }
h1 { font: 400 32px/1.2 var(--font-serif); color: var(--heading); margin: 32px 0 16px; }
h2 { font: 400 26px/1.2 var(--font-serif); color: var(--heading); margin: 28px 0 14px; }
h3 { font: 600 16px/1.2 var(--font-sans); letter-spacing: var(--ls-caps); text-transform: uppercase; color: var(--heading); margin: 0 0 20px; }
h4 { font: 600 14px/1.2 var(--font-sans); letter-spacing: 1px; text-transform: uppercase; color: var(--heading); margin: 24px 0 12px; }
.center { text-align: center; }
.main-content > :first-child, .sqs-content > :first-child { margin-top: 0; }

/* ---------------------------------------------------------------- header */
/* Like Squarespace: thin (grayscale) smoothing only in the header, banner and footer;
   body text keeps the browser default, which renders slightly heavier on macOS. */
.site-header, .banner, .pre-footer, .site-footer { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
.site-header { position: relative; z-index: 20; height: 140px; background: var(--header-bg); }
.has-banner .site-header { position: absolute; top: 0; left: 0; right: 0; background: transparent; }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 100%; padding: 20px; }
.logo img { width: 100px; height: 100px; }
.main-nav > ul { display: flex; align-items: center; gap: 4.5px; list-style: none; margin: 0; padding: 0; }
.main-nav a, .folder-toggle {
  display: block; padding: 9.75px 13px; background: none; border: 0; cursor: pointer;
  font: 600 13px/13px var(--font-sans); letter-spacing: var(--ls-caps); text-transform: uppercase;
  color: rgba(255, 255, 255, .9); transition: color .1s ease-in-out;
}
.main-nav a:hover, .folder-toggle:hover { color: #fff; }
.main-nav .nav-button { margin-left: 13px; }
.main-nav .nav-button a {
  border: 2px solid #fff; border-radius: 300px; padding: 13px 19.5px; color: #fff;
  transition: background-color .1s ease-in-out, color .1s ease-in-out;
}
.main-nav .nav-button a:hover { background-color: #fff; color: #181818; }
.folder { position: relative; }
/* Dropdowns unroll downward like Squarespace's (scaleY 0 -> 1 over 0.14s). */
.subnav {
  position: absolute; top: 100%; left: -6.5px; z-index: 1000; min-width: 167px; list-style: none;
  margin: 0; padding: 13px 0; background: var(--header-bg);
  transform: scaleY(0); transform-origin: 0 0; transition: transform .14s ease-in-out; visibility: hidden;
}
.subnav a { padding: 6.5px 19.5px; color: rgba(255, 255, 255, .9); white-space: nowrap; transition: color .1s ease-in-out; }
.folder:hover > .subnav, .folder:has(:focus-visible) > .subnav, .folder.open > .subnav { transform: scaleY(1); visibility: visible; }
.folder > .subnav { transition: transform .14s ease-in-out, visibility 0s .14s; }
.folder:hover > .subnav, .folder:has(:focus-visible) > .subnav, .folder.open > .subnav { transition: transform .14s ease-in-out, visibility 0s; }
.nav-toggle { display: none; }

/* ---------------------------------------------------------------- banner */
.banner {
  position: relative; background-color: #000;
  padding: 110px 0 65px; text-align: center; color: #fff;
}
.banner-image { position: absolute; inset: 0; background-size: cover; background-repeat: no-repeat; }
.banner-overlay { position: absolute; inset: 0; background: rgba(0, 0, 0, .3); }
.banner-desc { position: relative; max-width: 956px; margin: 0 auto; padding: 32px; }
.banner-desc p { margin: 20px 0; }
.banner-title { font: 400 67px/46px var(--font-banner-title); }
.banner-subtitle { font: 400 20px/14px var(--font-banner-sub); letter-spacing: .81px; }

/* ---------------------------------------------------------------- layout */
.page { max-width: calc(var(--content) + 40px); margin: 0 auto; padding: 50px 20px; display: flex; gap: 0; }
.main-content { flex: 1; min-width: 0; }
.pre-footer { background: var(--prefooter-bg); height: 124px; box-sizing: border-box; padding-top: 32px; overflow: hidden; }
/* Like Squarespace: the band's content waits 12px low and invisible until it scrolls into view. */
.pre-footer-inner { transition: all .25s ease-in-out .1s; }
.pre-footer.unscrolled .pre-footer-inner { opacity: 0; transform: translate3d(0, 12px, 0); }
.pre-footer a { display: block; width: 131px; margin: 0 auto; border-bottom: 1px solid rgba(0, 0, 0, .3); }
.pre-footer a:hover { border-bottom-color: #000; }
.pre-footer img { width: 131px; height: 59px; }
.site-footer {
  background: var(--footer-bg); color: var(--footer-text); text-align: center;
  padding: 91px 20px 64px;
}
.site-footer p { margin: 0 0 18px; }
.site-footer p:last-child { margin-bottom: 0; }

/* Folder (sidebar) navigation, e.g. Research > Projects / Artifacts */
.folder-nav { flex: 0 0 255px; }
.folder-nav ul { list-style: none; margin: 0; padding: 0; }
.folder-nav .nav-section-label { font: 400 22px/26.4px var(--font-serif); color: var(--folder-label); margin-bottom: 11px; }
.folder-nav a {
  display: block; padding: 5px 0; font: 600 14px/17.5px var(--font-sans); letter-spacing: var(--ls-caps);
  text-transform: uppercase; color: var(--muted);
}
.folder-nav a.active, .folder-nav a:hover { color: #1a1a1a; }

/* ---------------------------------------------------------------- summaries */
.summary-title { font: 400 20px/24px var(--font-sans); letter-spacing: var(--ls-title); color: #000; }
.summary-title a { color: inherit; }
.summary-title a:hover { color: var(--link); }
.summary-meta a { color: inherit; }
.summary-meta a:hover { color: var(--link); }
.summary-meta { font: 400 13px/18.2px var(--font-serif); color: var(--muted); opacity: .7; }
.summary-heading { font: 400 14px/1.2 var(--font-sans); letter-spacing: var(--ls-title); margin-bottom: 15px; }
.block-label { margin: 0; }

/* Home */
.two-col { display: grid; grid-template-columns: 1fr 1fr; column-gap: 34px; margin-bottom: 34px; }
.home-papers .summary-item { margin-bottom: 7px; }
.home-papers .summary-meta { margin-top: 2px; }
.home-news .summary-item { display: grid; grid-template-columns: 122px 1fr; column-gap: 20px; margin-bottom: 17px; padding-bottom: 17px; align-items: start; }
.home-news .summary-thumbnail img { width: 122px; height: 50.8px; object-fit: cover; }
.home-news .summary-title, .news-grid .summary-title { font-size: 14px; line-height: 16.8px; margin-bottom: 2px; }
.home-news .summary-title { margin-top: 0; }
.home-intro { margin-top: 0; }
.home-intro > :last-child { margin-bottom: 0; }
.spacer { height: 34px; }

.carousel-header { display: flex; justify-content: space-between; align-items: flex-start; height: 34.5px; }
.carousel-track .summary-title { margin-top: 2px; }
.carousel-pager button {
  background: none; border: 0; cursor: pointer; font: 300 28px/1 var(--font-sans); color: #000;
  padding: 0 6px; opacity: .8;
}
.carousel-pager button:disabled { opacity: .25; cursor: default; }
.carousel-track { display: grid; grid-auto-flow: column; grid-auto-columns: calc(25% - 0px); overflow: hidden; scroll-behavior: smooth; margin: 0 -10px; }
.carousel-track .summary-item, .carousel-list .summary-item { padding: 0 10px 2px; margin-bottom: 24px; }
.carousel-list { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0 -10px; }

.sponsors-title { margin: 0; }
.sponsors { list-style: none; padding: 0; margin: 0 0 20px; display: grid; grid-template-columns: repeat(6, 1fr); column-gap: 19.6px; row-gap: 20px; align-items: center; }
.sponsors img { width: 100%; max-height: 147px; object-fit: contain; }

/* Publications */
.papers .summary-item { margin-bottom: 44px; }
.papers .summary-title { margin-bottom: 10px; }
.papers .summary-excerpt p { font-size: 14px; line-height: 19.6px; margin: 0 0 10px; }
.papers .summary-excerpt p:last-child { margin-bottom: 0; }

/* News */
/* Without JS: plain 4-column grid. site.js turns it into a left-to-right masonry like Squarespace's. */
/* Squarespace rounds the first three columns down to whole pixels (182px at 980) and gives
   the last one the remainder; rows are 83px apart, like the columns. */
.news-grid { display: grid; grid-template-columns: repeat(3, calc((100% - 249px) / 4 - .75px)) 1fr; column-gap: 83px; align-items: start; }
.news-grid .masonry-col { min-width: 0; }
.news-grid .summary-item { margin-bottom: 83px; }
.news-grid .summary-thumbnail { display: block; margin-bottom: 15px; }
.news-grid .summary-thumbnail img { width: 100%; object-fit: cover; }
.news-grid .summary-title { margin-bottom: 10px; }

/* Single post / paper */
.entry, .pagination { max-width: 700px; margin-left: auto; margin-right: auto; }
.entry-dateline { color: var(--muted); }
.entry-title { margin: 12px 0; }
.entry .sqs-content img { margin: 0 auto 18px; }
.sqs-content > p > img:only-child { margin: 0 auto; }
.pagination { display: flex; justify-content: space-between; gap: 40px; margin-top: 108px; padding-top: 24px; border-top: 1px solid var(--rule); }
.pagination a { display: flex; flex-direction: column; color: #000; max-width: 50%; }
.pagination .older { text-align: right; margin-left: auto; }
.pagination .label { font: 600 12px/1.4 var(--font-sans); letter-spacing: 2px; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.pagination .title { font: 400 18px/1.4 var(--font-serif); }

/* Squarespace 12-column rows kept by the exporter (e.g. Classes) */
.sqs-row { display: flex; margin: 0 -17px; }
.sqs-row.v-center { align-items: center; }  /* e.g. a photo next to a logo in a news post */
.sqs-col { padding: 0 17px; min-width: 0; }
.sqs-col > :first-child { margin-top: 0; }
.span-1 { flex: 0 0 8.3333%; max-width: 8.3333%; }
.span-2 { flex: 0 0 16.6667%; max-width: 16.6667%; }
.span-3 { flex: 0 0 25.0000%; max-width: 25.0000%; }
.span-4 { flex: 0 0 33.3333%; max-width: 33.3333%; }
.span-5 { flex: 0 0 41.6667%; max-width: 41.6667%; }
.span-6 { flex: 0 0 50.0000%; max-width: 50.0000%; }
.span-7 { flex: 0 0 58.3333%; max-width: 58.3333%; }
.span-8 { flex: 0 0 66.6667%; max-width: 66.6667%; }
.span-9 { flex: 0 0 75.0000%; max-width: 75.0000%; }
.span-10 { flex: 0 0 83.3333%; max-width: 83.3333%; }
.span-11 { flex: 0 0 91.6667%; max-width: 91.6667%; }
.span-12 { flex: 0 0 100.0000%; max-width: 100.0000%; }

/* Content blocks converted from Squarespace */
.sqs-content blockquote { margin: 0 0 18px; padding: 0 0 0 20px; border-left: 2px solid var(--rule); }
.sqs-content ul, .sqs-content ol { margin: 0 0 18px; padding-left: 1.4em; }
.sqs-content li { margin-bottom: 6px; }
.sqs-content table { border-collapse: collapse; margin-bottom: 18px; }
.sqs-content td, .sqs-content th { border: 1px solid var(--rule); padding: 6px 10px; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; margin-bottom: 18px; }
.gallery figure { margin: 0; }
.gallery figcaption { font-size: 14px; color: var(--muted); }
.button-row { text-align: center; }
.sqs-button, .button-row .button {
  display: inline-block; padding: 16px 25px; background: #272727; color: #fff;
  font: 600 12px/1 var(--font-sans); letter-spacing: 1px; text-transform: uppercase;
}

/* ---------------------------------------------------------------- team */
.team-grid { list-style: none; margin: 0 0 40px; padding: 0; display: grid; }
.team-grid.large { grid-template-columns: repeat(4, 220px); justify-content: space-between; row-gap: 40px; }
.team-grid.small { grid-template-columns: repeat(auto-fill, 135px); column-gap: 34px; row-gap: 30px; }
.person img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.person .caption { margin-top: 18px; font-size: 15.75px; line-height: 19.6875px; }
.person .caption p { margin: 0 0 15.75px; }
.person .caption p:last-child { margin-bottom: 0; }
h1.spaced { margin-top: 80px; }
.slideshow { margin-bottom: 64px; }
/* Like the Squarespace gallery (auto-crop off): each photo is shown whole, centered in a
   980x551 frame; the caption sits on a gradient over the photo itself (placed by site.js). */
.slideshow .slides { position: relative; aspect-ratio: 980 / 551; overflow: hidden; background: rgba(175, 175, 175, .1); }
.slideshow .slide { display: none; position: absolute; inset: 0; margin: 0; }
.slideshow .slide.active, .slideshow .slide.leaving { display: block; }
.slideshow .slide.active { z-index: 1; }
.slideshow.animated .slide.active { animation: slide-in .7s cubic-bezier(.22,.58,.38,1) both; }
.slideshow.animated .slide.leaving { animation: slide-out .7s cubic-bezier(.22,.58,.38,1) both; }
@keyframes slide-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes slide-out { from { opacity: 1; } to { opacity: 0; } }
.slideshow .slide img { width: 100%; height: 100%; object-fit: contain; }
.slideshow figcaption {
  position: absolute; bottom: 0; left: 0; right: 0; height: 67px; box-sizing: border-box;
  padding: 30px 20px 0; color: #fff; font-family: var(--font-serif); font-size: 18px;
  line-height: 21.6px; letter-spacing: 1px;
  background: linear-gradient(rgba(0, 0, 0, 0) 0%, rgba(30, 30, 30, .3) 100%);
}
.slideshow .slides button {
  position: absolute; top: 50%; width: 44px; height: 60px; margin-top: -30px;
  background: rgba(0, 0, 0, .12); border: 0; cursor: pointer; z-index: 1;
}
.slideshow .slides button:hover { background: rgba(0, 0, 0, .2); }
.slideshow .slides button::before {
  content: ""; position: absolute; top: 50%; width: 10px; height: 10px; margin-top: -5px;
  border: solid #fff; border-width: 0 0 1.5px 1.5px;
}
.slideshow .prev { left: 0; }
.slideshow .prev::before { left: 18px; transform: rotate(45deg); }
.slideshow .next { right: 0; }
.slideshow .next::before { right: 18px; transform: rotate(-135deg); }
.slideshow .thumbs { overflow: hidden; margin-top: 20px; }
.slideshow .thumbs-track { display: flex; width: max-content; transition: transform .3s cubic-bezier(.215,.61,.355,1); }
.slideshow .thumb { flex: 0 0 auto; height: 79px; padding: 0; border: 0; background: none; cursor: pointer; opacity: .5; }
.slideshow .thumb.active, .slideshow .thumb:hover { opacity: 1; }
.slideshow .thumb img { display: block; height: 79px; width: auto; }
.team-grid + h3, h3 + .team-grid { margin-top: 0; }
h1#alumni + h3 { margin-top: 32px; }
.team-grid.small + h3 { margin-top: 56px; }
h3 { margin-bottom: 8px; }
.join { margin-top: 80px; }

/* ---------------------------------------------------------------- mobile */
@media (max-width: 900px) {
  .site-header { height: 90px; }
  .header-inner { padding: 12px 16px; }
  .logo img { width: 66px; height: 66px; }
  .nav-toggle {
    display: flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 44px; height: 44px; background: none; border: 0; cursor: pointer; padding: 10px;
  }
  .nav-toggle span { display: block; height: 2px; background: #fff; }
  .main-nav {
    position: fixed; top: 0; right: 0; bottom: 0; width: 260px; background: var(--header-bg);
    transform: translateX(100%); transition: transform .25s ease; padding: 80px 24px 24px; overflow-y: auto;
  }
  .main-nav.open { transform: none; }
  .main-nav > ul { flex-direction: column; align-items: stretch; gap: 0; }
  .main-nav .nav-button { margin: 12px 0 0; }
  .main-nav .nav-button a { text-align: center; }
  .subnav { position: static; padding: 0 0 0 12px; display: none; transform: none; visibility: visible; transition: none; }
  .folder:hover > .subnav, .folder:has(:focus-visible) > .subnav { display: none; }
  .folder.open > .subnav { display: block; transition: none; }
  .nav-open .nav-toggle { position: relative; z-index: 30; }

  .banner { padding: 100px 0 30px; }
  .banner-desc { padding: 16px; }
  .banner-title { font-size: 44px; line-height: 1.05; }
  .banner-subtitle { font-size: 17px; line-height: 1.3; }
  .page { flex-direction: column; padding: 32px 16px; }
  .sqs-row { flex-direction: column; }
  .sqs-col[class*="span-"] { flex: none; max-width: none; }
  .folder-nav { flex: none; margin-bottom: 24px; }
  .two-col { grid-template-columns: 1fr; row-gap: 24px; }
  .carousel-track { grid-auto-columns: 50%; }
  .carousel-list { grid-template-columns: repeat(2, 1fr); }
  .sponsors { grid-template-columns: repeat(3, 1fr); }
  .news-grid { grid-template-columns: repeat(2, 1fr); column-gap: 24px; }
  .team-grid.large { grid-template-columns: repeat(2, 1fr); column-gap: 20px; }
  .team-grid.small { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); column-gap: 20px; }
}
@media (max-width: 480px) {
  .news-grid { grid-template-columns: 1fr; }
  .carousel-track { grid-auto-columns: 100%; }
  .carousel-list { grid-template-columns: 1fr; }
}

/* Live site keeps the normal heading gap under an article title */
.entry .sqs-content > h1:first-child, .entry .sqs-content > h2:first-child { margin-top: 32px; }

/* ---------------------------------------------------------------- load animations
   Same as the Squarespace template: on each page load the header fades in, the banner
   photo fades in, and the banner text (or a post's date and title) rises into place. */
@keyframes header-anim { 0%, 72% { opacity: 0; } 100% { opacity: 1; } }
@keyframes feature-bg-anim { 0%, 50% { opacity: 0; } 100% { opacity: 1; } }
@keyframes feature-text-anim {
  0%, 75% { opacity: 0; transform: translate3d(0, 10px, 0); }
  100% { opacity: 1; transform: translate3d(0, 0, 0); }
}
.header-inner { animation: header-anim 1s ease-in-out; }
.banner-image { animation: feature-bg-anim .6s ease-in-out; }
.banner-desc, .entry-dateline, .entry-title { animation: feature-text-anim .75s ease-in-out; }
@media (prefers-reduced-motion: reduce) {
  .header-inner, .banner-image, .banner-desc, .entry-dateline, .entry-title { animation: none; }
  .pre-footer-inner { transition: none; }
}
