/* Base */
:root {
  --bg: #eef6f4;
  --surface: #fffdf8;
  --surface-2: #e0ece8;
  --text: #162021;
  --muted: #4c5b57;
  --accent: #2f6f75;
  --line: #bfd2cc;
  --shadow: rgba(11, 32, 34, 0.09);
  --wash-1: #f8fbf8;
  --wash-2: #d6ece8;
  --font-body: "Work Sans", sans-serif;
  --heading-weight: 600;
  --lead-size: 1.1rem;
  --lead-line-height: 1.6;
  --label-size: clamp(0.68rem, 1.5vw, 0.9rem);
  --label-weight: 600;
  --label-line-height: 1.08;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: var(--font-body);
  line-height: 1.6;
  color: var(--text);
  text-transform: lowercase;
  background:
    radial-gradient(circle at 15% 10%, var(--wash-1) 0, transparent 36%),
    radial-gradient(circle at 85% 0%, var(--wash-2) 0, transparent 32%),
    var(--bg);
  letter-spacing: 0;
  transition: background-color 180ms ease, color 180ms ease;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.25;
  background-image: linear-gradient(
      to right,
      rgba(34, 28, 22, 0.025) 1px,
      transparent 1px
    ),
    linear-gradient(to bottom, rgba(34, 28, 22, 0.025) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* Shared site frame */
.site-header,
main,
.page-shell,
footer {
  width: min(1020px, 92vw);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

main,
.page-shell {
  padding: 1.5rem 0 3rem;
}

/* Home page */
.home-page {
  --sidebar-width: 270px;
  --home-content-max-width: 1124px;
  --home-content-sidebar-gap: 3.6rem;
  --home-content-edge-gap: 2rem;
}

.home-page .site-header {
  position: fixed;
  top: 1.1rem;
  left: 1.2rem;
  width: var(--sidebar-width);
  max-height: calc(100vh - 2.2rem);
  overflow-y: auto;
  margin: 0;
  padding: 0.2rem 0.1rem 0.2rem 0;
  background: transparent;
  z-index: 3;
}

.home-page main,
.home-page footer {
  width: min(
    var(--home-content-max-width),
    calc(100vw - var(--sidebar-width) - var(--home-content-sidebar-gap) - var(--home-content-edge-gap))
  );
  max-width: var(--home-content-max-width);
  margin-left: calc(
    var(--sidebar-width) + var(--home-content-sidebar-gap) + max(
      0px,
      (100vw - var(--sidebar-width) - var(--home-content-sidebar-gap) - var(--home-content-edge-gap) - var(--home-content-max-width)) / 2
    )
  );
  margin-right: var(--home-content-edge-gap);
}

.site-header {
  display: grid;
  justify-items: start;
  gap: 0.7rem;
  padding: 1.35rem 0 0.75rem;
}

.site-menu {
  display: flex;
  gap: 0.45rem 0.6rem;
  flex-wrap: wrap;
  max-width: 760px;
}

.identity {
  margin: 0;
  font-style: normal;
  text-align: left;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
  max-width: 32ch;
}

.identity-name {
  color: var(--text);
  font-family: inherit;
  font-size: 1.1rem;
  line-height: 1.2;
  font-weight: 600;
}

.identity a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}

.identity a:hover {
  color: var(--text);
  border-color: var(--accent);
}

.identity a:focus-visible,
.site-menu a:focus-visible,
.discipline-link:focus-visible,
.image-link:focus-visible,
.track-btn:focus-visible,
.music-menu summary:focus-visible,
.genre-menu summary:focus-visible,
.language-link:focus-visible,
.back-link a:focus-visible,
footer a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.identity-image {
  display: block;
  width: min(100%, 260px);
  margin-top: 0.7rem;
  height: auto;
}

.site-menu a {
  color: var(--muted);
  text-decoration: none;
  border: 1px solid var(--line);
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.88rem;
  transition: color 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.site-menu a:hover,
.site-menu a:focus-visible {
  color: var(--text);
  border-color: var(--accent);
  transform: translateY(-1px);
}

.hero {
  padding: 2.7rem 0 2.5rem;
  animation: fade-up 700ms ease both;
}

.memoir-section {
  width: min(100%, 62ch);
  padding: 2.7rem 0 0.4rem;
}

.memoir-title {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 2.2vw, 1.55rem);
  line-height: 1.25;
  text-transform: none;
}

.memoir-links,
.language-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.6rem;
}

.memoir-links {
  margin-top: 0.8rem;
}

.bio-language-controls {
  margin: 0;
  padding: 0;
  border: 0;
}

.memoir-link,
.language-link {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.18rem 0.7rem;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.5;
  text-decoration: none;
}

.memoir-link,
.language-link {
  cursor: pointer;
}

.language-switch {
  margin-top: 0.55rem;
}

.memoir-link:hover,
.memoir-link:focus-visible,
.language-link:hover,
.language-link:focus-visible {
  color: var(--text);
  border-color: var(--accent);
}

#bio-lang-en:focus-visible ~ .language-switch label[for="bio-lang-en"],
#bio-lang-fr:focus-visible ~ .language-switch label[for="bio-lang-fr"],
#bio-lang-en:checked ~ .language-switch label[for="bio-lang-en"],
#bio-lang-fr:checked ~ .language-switch label[for="bio-lang-fr"] {
  color: var(--text);
  border-color: var(--accent);
}

.bio-version {
  display: none;
}

#bio-lang-en:checked ~ .bio-versions #bio-en,
#bio-lang-fr:checked ~ .bio-versions #bio-fr {
  display: block;
}

.kicker {
  margin: 0;
  letter-spacing: 0.08em;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 600;
}

h1,
h2 {
  font-family: inherit;
  line-height: 1.08;
  margin: 0;
  font-weight: var(--heading-weight);
}

.lead {
  margin: 0.9rem 0 0;
  max-width: 62ch;
  font-size: var(--lead-size);
  line-height: var(--lead-line-height);
  color: var(--muted);
}

.panel {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  animation: fade-up 700ms ease both;
}

p {
  margin: 0;
}

.work {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem 1.5rem;
  margin-top: 3.5rem;
}

.discipline-card {
  display: flex;
  flex-direction: column;
  width: min(100%, 460px);
  justify-self: center;
}

.discipline {
  order: 2;
  font-size: var(--label-size);
  line-height: var(--label-line-height);
  margin: 0;
  padding: 0.3rem 0 0;
  border: 0;
  color: var(--accent);
  text-align: left;
  align-self: flex-start;
  font-weight: var(--label-weight);
}

.discipline-link {
  color: inherit;
  text-decoration: none;
}

@media (min-width: 860px) {
  .home-page .discipline-card {
    display: grid;
    grid-template-columns: minmax(0, var(--card-width)) minmax(5.6rem, 7.4rem);
    gap: 0 0.9rem;
    align-items: end;
    width: min(100%, calc(var(--card-width) + 8.3rem));
  }

  .home-page .image-link {
    grid-column: 1;
    grid-row: 1;
  }

  .home-page .discipline {
    grid-column: 2;
    grid-row: 1;
    align-self: end;
    padding: 0 0 0.03rem;
    font-size: clamp(0.9rem, 1.4vw, 1.08rem);
    line-height: 1.1;
    font-weight: 700;
  }
}

.image-link {
  display: block;
  width: 100%;
  align-self: stretch;
  color: inherit;
  text-decoration: none;
}

.music-menu {
  order: 2;
  align-self: flex-start;
  width: 100%;
}

.music-menu summary {
  list-style: none;
  cursor: pointer;
}

.music-menu summary::-webkit-details-marker {
  display: none;
}

.music-groups {
  margin-top: 0.35rem;
  display: grid;
  gap: 0.3rem;
}

.genre-menu summary {
  color: var(--accent);
  cursor: pointer;
  font-size: 0.83rem;
}

.track-list {
  margin: 0.25rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.16rem;
}

.track-btn {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  text-align: left;
  font: inherit;
  color: var(--accent);
  font-size: 0.83rem;
  cursor: pointer;
}

.track-btn:hover,
.track-btn:focus-visible {
  text-decoration: underline;
}

.track-btn.is-active {
  font-weight: 500;
  text-decoration: underline;
}

.music-player {
  margin-top: 0.45rem;
  width: 100%;
  max-width: 360px;
}

.now-playing {
  margin-top: 0.25rem;
  font-size: 0.78rem;
  color: var(--muted);
}

.image-space {
  order: 1;
  display: block;
  width: 100%;
  margin-top: 0;
  min-height: 180px;
}

.artwork-image {
  display: block;
  min-height: 0;
  height: auto;
  object-fit: cover;
}

.film-image {
  width: 100%;
}

.triptych {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.35rem;
  min-height: 0;
}

.triptych img {
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  object-position: center 42%;
}

.triptych-photo {
  object-position: center 42%;
}

/* Homepage cards */
.performances-card {
  --card-width: 620px;
  width: min(100%, var(--card-width));
}

.sound-card {
  --card-width: 390px;
  width: min(100%, var(--card-width));
}

.paintings-card {
  --card-width: 430px;
  width: min(100%, var(--card-width));
}

.films-card {
  --card-width: 470px;
  width: min(100%, var(--card-width));
}

.pedagogy-card {
  --card-width: 520px;
  width: min(100%, var(--card-width));
  margin-top: 0;
}

.pedagogy-image {
  display: block;
  width: 100%;
  height: auto;
  min-height: 0;
  border: 0;
  background: none;
}

.pedagogy-sequence {
  display: grid;
  gap: 3rem;
}

.pedagogy-entry {
  display: grid;
  grid-template-areas:
    "media"
    "copy";
  gap: 1rem 1.45rem;
  width: min(100%, 900px);
  margin: 0;
  align-items: start;
}

.pedagogy-entry.image-left {
  justify-self: start;
}

.pedagogy-entry.image-right {
  justify-self: end;
}

.pedagogy-media {
  grid-area: media;
  margin: 0;
}

.pedagogy-media img {
  display: block;
  width: 100%;
  height: auto;
}

.pedagogy-copy {
  grid-area: copy;
  width: min(100%, 58ch);
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.65;
  text-transform: none;
}

.pedagogy-title {
  margin: 0 0 0.45rem;
  color: var(--accent);
  font-size: 0.95rem;
  font-style: italic;
  font-weight: 500;
}

.pedagogy-copy p {
  margin: 0 0 0.85rem;
}

.pedagogy-copy p:last-child {
  margin-bottom: 0;
  color: var(--accent);
  font-size: 0.86rem;
}

/* Secondary pages */
.page-nav {
  display: grid;
  gap: 0.65rem;
  margin-bottom: 1.5rem;
}

.page-nav,
.page-nav > * {
  position: relative;
  z-index: 1;
}

.back-link {
  margin: 0;
  color: var(--accent);
}

.back-link {
  font-size: 0.88rem;
}

.back-link a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}

.back-link a:hover,
.back-link a:focus-visible {
  border-color: var(--accent);
}

.page-intro {
  display: none;
  width: min(100%, 760px);
  margin: 0 0 1.8rem;
  padding: 1.2rem 1.3rem 1.35rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: var(--accent);
  text-transform: none;
  line-height: 1.8;
  scroll-margin-top: 1rem;
}

.page-intro:target {
  display: block;
}

.page-intro-title {
  margin: 0 0 0.9rem;
  color: inherit;
  font-size: clamp(1.15rem, 2vw, 1.45rem);
  line-height: 1.2;
  font-weight: 500;
}

.page-intro p {
  margin: 0 0 1rem;
  max-width: 65ch;
}

.page-intro p:last-child {
  margin-bottom: 0;
}

.performance-grid,
.sound-grid,
.paintings-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.2rem;
}

.performance-entry {
  display: grid;
  gap: 0.9rem 1.4rem;
  width: min(100%, 780px);
  justify-self: start;
  margin: 0;
}

.performance-entry img {
  display: block;
  width: min(100%, 420px);
  height: auto;
}

.performance-copy {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
  text-transform: none;
}

.performance-title {
  margin: 0 0 0.8rem;
  color: var(--accent);
  font-style: italic;
}

.performance-poem {
  margin: 0;
  color: var(--accent);
}

.performance-poem p {
  margin: 0;
}

.performance-caption {
  margin: 1rem 0 0;
}

.upcall-section {
  width: min(100%, 900px);
  justify-self: start;
  margin-top: 1.4rem;
}

.upcall-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.upcall-image {
  margin: 0;
}

.upcall-image img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  height: auto;
  object-fit: cover;
}

.upcall-copy {
  width: min(100%, 62ch);
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.65;
  text-transform: none;
}

.upcall-title {
  margin: 0 0 0.35rem;
  color: var(--accent);
  font-size: 0.95rem;
  font-style: italic;
  font-weight: 500;
}

.upcall-copy p {
  margin: 0;
}

.painting-entry {
  --painting-width: 540px;
  --caption-width: 9.75rem;
  --caption-gap: 1rem;
  position: relative;
  width: min(100%, calc(var(--painting-width) + var(--caption-width) + var(--caption-gap)));
  padding-right: calc(var(--caption-width) + var(--caption-gap));
  justify-self: center;
  margin: 0;
}

.painting-entry img {
  width: 100%;
  height: auto;
  display: block;
  max-width: var(--painting-width);
  margin-left: auto;
}

.painting-entry figcaption {
  position: absolute;
  right: 0;
  bottom: 0.1rem;
  width: var(--caption-width);
  margin: 0;
  text-align: left;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.35;
}

.painting-title {
  font-style: italic;
}

.painting-meta {
  font-style: normal;
}

.sound-entry,
.sound-library,
.film-entry {
  justify-self: center;
  margin: 0;
}

.sound-entry {
  width: min(50%, 450px);
}

.sound-library,
.film-entry {
  width: min(100%, 900px);
}

.sound-entry img {
  width: 100%;
  height: auto;
  display: block;
}

.sound-entry figcaption {
  margin: 0.45rem 0 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.35;
}

.sound-library {
  padding: 1.1rem 1.3rem 1.35rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.sound-library summary {
  padding-bottom: 0.25rem;
}

.sound-summary {
  font-size: clamp(0.82rem, 1.7vw, 0.95rem);
}

.sound-library .music-groups {
  gap: 0.45rem;
}

.sound-library .genre-menu + .genre-menu {
  border-top: 1px solid rgba(139, 90, 43, 0.12);
  padding-top: 0.4rem;
}

.sound-library .music-player {
  max-width: 100%;
}

.films-grid {
  --films-gap: 2.4rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--films-gap);
}

.film-entry {
  display: grid;
  gap: 0.8rem 1.2rem;
  align-items: end;
}

.film-entry-gap-triple {
  margin-bottom: calc(var(--films-gap) * 2);
}

.film-entry-caption-top {
  align-items: start;
}

.film-entry video {
  width: 100%;
  display: block;
  margin: 0;
  background: #000;
}

.film-caption {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
  max-width: 26ch;
}

.film-title-line {
  margin: 0;
}

.film-meta-line {
  margin: 0.15rem 0 0;
  color: var(--accent);
}

.film-notes {
  margin: 0.35rem 0 0;
}

.film-title {
  font-style: italic;
}

.film-lyrics {
  display: grid;
  gap: 0.75rem;
  margin-top: 0.8rem;
  color: var(--accent);
  text-transform: none;
}

.film-lyrics p {
  margin: 0;
}

.painting-entry.size-a3 {
  --painting-width: 540px;
}

.painting-entry.size-a2 {
  --painting-width: 720px;
}

.painting-entry.size-1m {
  --painting-width: 860px;
}

footer {
  display: grid;
  gap: 0.55rem;
  border-top: 1px solid var(--line);
  padding: 1.2rem 0 2.4rem;
  color: var(--muted);
  font-size: 0.95rem;
}

footer p {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

footer span {
  min-width: 5.4rem;
  font-weight: 600;
  color: var(--text);
}

/* Motion */
@keyframes fade-up {
  from {
    transform: translateY(16px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Responsive */
@media (min-width: 860px) {
  .work {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 2.25rem;
  }

  .performances-card {
    justify-self: start;
  }

  .sound-card {
    justify-self: end;
  }

  .paintings-card {
    justify-self: end;
  }

  .films-card {
    justify-self: start;
  }

  .pedagogy-card {
    justify-self: start;
  }

  .performance-grid,
  .sound-grid,
  .paintings-grid {
    grid-template-columns: 1fr;
    gap: 2.8rem;
  }

  .performance-entry {
    grid-template-columns: minmax(260px, 420px) minmax(14rem, 22rem);
    align-items: end;
  }

  .pedagogy-entry {
    grid-template-columns: minmax(240px, 430px) minmax(18rem, 1fr);
  }

  .pedagogy-entry.image-left {
    grid-template-areas: "media copy";
  }

  .pedagogy-entry.image-right {
    grid-template-areas: "copy media";
  }

  .pedagogy-entry.image-left .pedagogy-media {
    justify-self: start;
    padding-top: 0.45rem;
  }

  .pedagogy-entry.image-right .pedagogy-media {
    justify-self: end;
    padding-top: 0.45rem;
  }

  .page-intro {
    padding-left: 1.6rem;
  }

  .film-entry {
    grid-template-columns: minmax(0, 1fr) minmax(11rem, 15rem);
  }

  footer {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
  }
}

@media (max-width: 700px) {
  .sound-entry {
    width: min(100%, 320px);
  }

  .upcall-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .site-menu {
    max-width: 100%;
  }
}

@media (max-width: 460px) {
  .upcall-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .home-page .site-header {
    position: relative;
    top: auto;
    left: auto;
    width: min(1020px, 92vw);
    max-height: none;
    overflow: visible;
    margin: 0 auto;
    padding: 1.35rem 0 0.75rem;
  }

  .home-page main,
  .home-page footer {
    margin-left: auto;
    margin-right: auto;
    width: min(1020px, 92vw);
  }
}
