:root {
  --purple: #5c35a8;
  --paper: #f4f1ed;
  --ink: #101010;
  --muted: #66635f;
  --line: #d9d4ce;
  --page-pad: clamp(1.5rem, 4vw, 4rem);

  --shell-page-pad: var(--page-pad);
  --shell-accent: var(--purple);
  --shell-header-bg: rgba(244, 241, 237, 0.94);
  --shell-header-text: var(--ink);
  --shell-header-muted: #3f3c39;
  --shell-header-line: var(--line);
  --shell-footer-bg: #0d0d0f;
  --shell-footer-text: #f4f1ed;
  --shell-footer-muted: #aaa5a0;
  --shell-footer-line: rgba(255,255,255,.08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: var(--paper);
  font-family: Arial, Helvetica, sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; }
button { cursor: pointer; }
img { display: block; max-width: 100%; }

.shell-project-title--visuals {
  width: 132px;
  height: 44px;
}

.visuals-hero {
  min-height: 410px;
  padding: 5rem var(--page-pad) 4.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #f8f6f2, var(--paper));
}

.visuals-hero-logo {
  width: min(360px, 72vw);
  margin-bottom: 1.75rem;
}

.visuals-hero p {
  max-width: 620px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(.95rem, 1.4vw, 1.12rem);
  line-height: 1.65;
}

.visuals-divider {
  position: relative;
  width: 138px;
  height: 1px;
  margin-top: 2rem;
  background: var(--line);
}

.visuals-divider::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 7px;
  height: 7px;
  background: var(--paper);
  border: 1px solid var(--purple);
  transform: translate(-50%, -50%) rotate(45deg);
}

.gallery-section {
  padding: 2rem var(--page-pad) 7rem;
}

.gallery-toolbar {
  width: min(100%, 1500px);
  margin: 0 auto 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: .65rem;
}

.filter-button {
  min-width: 76px;
  padding: .72rem 1.1rem;
  color: #3f3c39;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 6px;
  font-size: .72rem;
  font-weight: 700;
  transition: background 180ms ease, color 180ms ease, border-color 180ms ease;
}

.filter-button.active,
.filter-button:hover,
.filter-button:focus-visible {
  color: #fff;
  background: #111;
  border-color: #111;
}

.work-count {
  color: var(--muted);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.visual-grid {
  width: min(100%, 1500px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-flow: dense;
  grid-auto-rows: 250px;
  gap: .75rem;
}

.visual-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  padding: 0;
  color: white;
  background: #111;
  border: 0;
  border-radius: 8px;
  text-align: left;
}

.visual-card--wide { grid-column: span 2; }
.visual-card--tall { grid-row: span 2; }

.visual-card[hidden] { display: none; }

.visual-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 420ms cubic-bezier(.2,.65,.3,1), filter 220ms ease;
}

.visual-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,.78), rgba(0,0,0,0) 58%);
}

.visual-card > span:not(.visual-card-play) {
  position: absolute;
  z-index: 2;
  left: 1rem;
  right: 1rem;
  bottom: .9rem;
  display: flex;
  flex-direction: column;
  gap: .2rem;
}

.visual-card strong {
  font-size: .92rem;
}

.visual-card small {
  color: rgba(255,255,255,.76);
  font-size: .68rem;
}

.visual-card:hover img,
.visual-card:focus-visible img {
  transform: scale(1.035);
  filter: brightness(1.08);
}

.collections-section,
.visuals-about {
  padding: 7rem var(--page-pad);
  border-top: 1px solid var(--line);
}

.collections-section {
  background: #eeeae5;
}

.collections-section > *,
.visuals-about > * {
  width: min(100%, 1280px);
  margin-left: auto;
  margin-right: auto;
}

.section-kicker {
  margin-bottom: 1rem;
  color: var(--purple);
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .2em;
  text-transform: uppercase;
}

.collections-section h2,
.visuals-about h2 {
  margin-top: 0;
  margin-bottom: 4rem;
  max-width: 950px;
  font-size: clamp(3rem, 7vw, 6.5rem);
  line-height: .9;
  letter-spacing: -.07em;
  font-weight: 500;
}

.collection-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.collection-grid article {
  min-height: 260px;
  padding: 2rem;
  border-right: 1px solid var(--line);
}

.collection-grid article:last-child {
  border-right: 0;
}

.collection-grid span {
  color: var(--purple);
  font-size: .7rem;
  font-weight: 900;
  letter-spacing: .14em;
}

.collection-grid h3 {
  margin: 3.5rem 0 .8rem;
  font-size: 1.35rem;
}

.collection-grid p,
.visuals-about > p:last-child {
  max-width: 620px;
  color: var(--muted);
  line-height: 1.7;
}

.visuals-about {
  background: #f8f6f2;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  grid-template-columns: minmax(250px, 330px) minmax(0, 1fr);
  gap: 2rem;
  padding: 2rem;
  color: #fff;
  background: rgba(8,8,10,.97);
}

.lightbox.open { display: grid; }

.lightbox-close {
  position: absolute;
  top: 1.25rem;
  right: 1.5rem;
  z-index: 3;
  width: 44px;
  height: 44px;
  color: #fff;
  background: transparent;
  border: 0;
  font-size: 2rem;
}

.lightbox-meta {
  min-width: 0;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.lightbox-meta > p:first-child {
  margin: 0;
  color: #aaa;
  font-size: .75rem;
}

.lightbox-meta h2 {
  margin-bottom: 1rem;
  font-size: 2rem;
}

.lightbox-meta p {
  color: #c9c9c9;
  line-height: 1.6;
}

.lightbox-meta span {
  color: #888;
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.lightbox-image {
  margin: 0;
  min-width: 0;
  display: grid;
  place-items: center;
}

.lightbox-image img {
  max-width: 100%;
  max-height: calc(100vh - 4rem);
  object-fit: contain;
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  width: 48px;
  height: 72px;
  color: #fff;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.1);
  font-size: 2rem;
  transform: translateY(-50%);
}

.lightbox-prev { left: 350px; }
.lightbox-next { right: 1.5rem; }

body.lightbox-open { overflow: hidden; }

@media (max-width: 1000px) {
  .visual-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .collection-grid {
    grid-template-columns: 1fr;
  }

  .collection-grid article {
    min-height: 210px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .collection-grid article:last-child {
    border-bottom: 0;
  }
}

@media (max-width: 680px) {
  .shell-project-title--visuals {
    width: 104px;
    height: 36px;
  }

  .visuals-hero {
    min-height: 350px;
    padding-top: 4rem;
    padding-bottom: 3.5rem;
  }

  .gallery-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .visual-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: 260px;
  }

  .visual-card--wide,
  .visual-card--tall {
    grid-column: auto;
    grid-row: auto;
  }

  .collections-section,
  .visuals-about {
    padding-top: 5rem;
    padding-bottom: 5rem;
  }

  .collections-section h2,
  .visuals-about h2 {
    margin-bottom: 3rem;
  }

  .lightbox {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
    padding: 1rem;
  }

  .lightbox-meta {
    padding: 0 3rem 0 0;
    gap: 1rem;
  }

  .lightbox-meta > div:last-child {
    display: none;
  }

  .lightbox-meta h2 {
    margin: 0;
    font-size: 1.3rem;
  }

  .lightbox-meta p {
    margin: .2rem 0;
  }

  .lightbox-image img {
    max-height: 65vh;
  }

  .lightbox-prev {
    left: 1rem;
  }

  .lightbox-next {
    right: 1rem;
  }
}


.visual-grid:empty::before {
  content: "No work has been added yet.";
  grid-column: 1 / -1;
  padding: 4rem 1rem;
  color: var(--muted);
  text-align: center;
  border: 1px solid var(--line);
  border-radius: 8px;
}

/* Custom video player */
.lightbox-media {
  position: relative;
  margin: 0;
  min-width: 0;
  min-height: 0;
  display: grid;
  place-items: center;
}

.lightbox-media > img {
  max-width: 100%;
  max-height: calc(100vh - 4rem);
  object-fit: contain;
}

.lightbox-media > img[hidden] {
  display: none;
}

.video-player {
  --player-purple: #7c3cff;
  position: relative;
  width: min(100%, 1500px);
  max-height: calc(100vh - 4rem);
  overflow: hidden;
  background: #050506;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 10px;
  box-shadow: 0 24px 80px rgba(0,0,0,.38);
  isolation: isolate;
}

.video-player[hidden] { display: none; }

.video-player video {
  display: block;
  width: 100%;
  max-height: calc(100vh - 4rem);
  aspect-ratio: 16 / 9;
  object-fit: contain;
  background: #050506;
}

.video-player::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: auto 0 0;
  height: 34%;
  pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,.78));
  opacity: 1;
  transition: opacity 220ms ease;
}

.video-controls {
  position: absolute;
  z-index: 3;
  left: clamp(.8rem, 2vw, 1.5rem);
  right: clamp(.8rem, 2vw, 1.5rem);
  bottom: clamp(.7rem, 1.8vw, 1.25rem);
  display: grid;
  grid-template-columns: auto minmax(80px, 1fr) auto auto auto;
  align-items: center;
  gap: clamp(.55rem, 1.2vw, 1rem);
  opacity: 1;
  transform: translateY(0);
  transition: opacity 180ms ease, transform 180ms ease;
}

.video-control,
.video-center-button {
  padding: 0;
  color: #fff;
  background: transparent;
  border: 0;
}

.video-control {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  opacity: .94;
  transition: color 160ms ease, opacity 160ms ease, transform 160ms ease;
}

.video-control:hover,
.video-control:focus-visible {
  color: var(--player-purple);
  opacity: 1;
  transform: scale(1.06);
}

.video-control svg,
.video-center-button svg,
.visual-card-play svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.video-play svg { width: 24px; height: 24px; }
.video-mute svg,
.video-fullscreen svg { width: 22px; height: 22px; }

.icon-pause,
.icon-replay,
.icon-muted,
.icon-compress { display: none; }

.video-player.is-playing .video-play .icon-play { display: none; }
.video-player.is-playing .video-play .icon-pause { display: block; }
.video-player.is-muted .video-mute .icon-volume { display: none; }
.video-player.is-muted .video-mute .icon-muted { display: block; }
.video-player.is-fullscreen .video-fullscreen .icon-expand { display: none; }
.video-player.is-fullscreen .video-fullscreen .icon-compress { display: block; }
.video-player.is-ended .video-center-button .icon-play { display: none; }
.video-player.is-ended .video-center-button .icon-replay { display: block; }

.video-center-button {
  position: absolute;
  z-index: 4;
  top: 50%;
  left: 50%;
  width: clamp(58px, 7vw, 76px);
  height: clamp(58px, 7vw, 76px);
  display: grid;
  place-items: center;
  color: #fff;
  background: rgba(7,7,9,.66);
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 50%;
  backdrop-filter: blur(10px);
  transform: translate(-50%, -50%);
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease, opacity 180ms ease, transform 180ms ease;
}

.video-center-button svg { width: 42%; height: 42%; }
.video-center-button:hover,
.video-center-button:focus-visible {
  color: var(--player-purple);
  background: rgba(7,7,9,.82);
  border-color: color-mix(in srgb, var(--player-purple) 70%, white 30%);
  transform: translate(-50%, -50%) scale(1.04);
}
.video-player.is-playing .video-center-button { opacity: 0; pointer-events: none; }

.video-timeline-wrap { display: grid; align-items: center; min-width: 0; }
.video-timeline {
  --progress: 0%;
  width: 100%;
  height: 20px;
  margin: 0;
  appearance: none;
  background: transparent;
  cursor: pointer;
}

.video-timeline::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(to right, var(--player-purple) 0 var(--progress), rgba(255,255,255,.34) var(--progress) 100%);
}
.video-timeline::-moz-range-track {
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(to right, var(--player-purple) 0 var(--progress), rgba(255,255,255,.34) var(--progress) 100%);
}
.video-timeline::-webkit-slider-thumb {
  width: 12px;
  height: 12px;
  margin-top: -4px;
  appearance: none;
  background: #fff;
  border: 0;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(124,60,255,.35);
  transition: box-shadow 160ms ease, transform 160ms ease;
}
.video-timeline::-moz-range-thumb {
  width: 12px;
  height: 12px;
  background: #fff;
  border: 0;
  border-radius: 50%;
}
.video-timeline:hover::-webkit-slider-thumb,
.video-timeline:focus-visible::-webkit-slider-thumb {
  box-shadow: 0 0 0 5px rgba(124,60,255,.25);
  transform: scale(1.06);
}

.video-time {
  min-width: 92px;
  color: rgba(255,255,255,.92);
  font-size: clamp(.68rem, 1vw, .82rem);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.video-player.controls-hidden::after,
.video-player.controls-hidden .video-controls {
  opacity: 0;
}
.video-player.controls-hidden .video-controls {
  pointer-events: none;
  transform: translateY(8px);
}
.video-player.controls-hidden { cursor: none; }

.visual-card-play {
  position: absolute;
  z-index: 3;
  top: 1rem;
  left: 1rem;
  right: auto;
  bottom: auto;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #fff;
  background: rgba(10,10,12,.62);
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 50%;
  backdrop-filter: blur(8px);
  transition: color 180ms ease, background 180ms ease, transform 180ms ease;
}

.visual-card-play svg {
  width: 20px;
  height: 20px;
  display: block;
  margin: 0;
  transform: translate(0px, 0);
}
.visual-card:hover .visual-card-play,
.visual-card:focus-visible .visual-card-play {
  color: #a775ff;
  background: rgba(10,10,12,.82);
}

.video-player:fullscreen {
  width: 100vw;
  height: 100vh;
  max-height: none;
  border: 0;
  border-radius: 0;
  background: #000;
}
.video-player:fullscreen video { width: 100%; height: 100%; max-height: none; aspect-ratio: auto; }

@media (max-width: 680px) {
  .lightbox-media > img { max-height: 65vh; }
  .video-player,
  .video-player video { max-height: 65vh; }
  .video-controls {
    grid-template-columns: auto minmax(60px, 1fr) auto auto;
    gap: .45rem;
  }
  .video-time { min-width: 0; font-size: .66rem; }
  .video-mute { display: none; }
  .video-control { width: 30px; height: 30px; }
}

@media (prefers-reduced-motion: reduce) {
  .video-controls,
  .video-center-button,
  .video-control,
  .visual-card-play { transition: none; }
}


/* Floating project media strip */
.lightbox-thumbnails {
  position: absolute;
  z-index: 6;
  left: 50%;
  bottom: clamp(1rem, 2.6vh, 1.75rem);
  max-width: calc(100% - 3rem);
  padding: .55rem;
  display: flex;
  align-items: center;
  gap: .5rem;
  overflow-x: auto;
  color: #fff;
  background: rgba(8, 8, 10, .68);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 10px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, .34);
  backdrop-filter: blur(12px);
  scrollbar-width: none;
  opacity: 1;
  transform: translate(-50%, 0);
  transition: opacity 180ms ease, transform 180ms ease;
}

.lightbox-thumbnails::-webkit-scrollbar {
  display: none;
}

.lightbox-thumbnails[hidden] {
  display: none;
}

.lightbox-thumbnails.is-hidden {
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, 8px);
}

.lightbox-thumbnail {
  position: relative;
  flex: 0 0 auto;
  width: clamp(54px, 5vw, 72px);
  height: clamp(42px, 4vw, 56px);
  overflow: hidden;
  padding: 0;
  background: #111;
  border: 2px solid transparent;
  border-radius: 5px;
  opacity: .62;
  transition: opacity 160ms ease, border-color 160ms ease;
}

.lightbox-thumbnail:hover,
.lightbox-thumbnail:focus-visible {
  opacity: .9;
}

.lightbox-thumbnail.active {
  border-color: #7c3cff;
  opacity: 1;
}

.lightbox-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lightbox-thumbnail-play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  background: rgba(0, 0, 0, .18);
}

.lightbox-thumbnail-play::before {
  content: "";
  width: 23px;
  height: 23px;
  background: rgba(5, 5, 7, .66);
  border: 1px solid rgba(255, 255, 255, .34);
  border-radius: 50%;
}

.lightbox-thumbnail-play svg {
  position: absolute;
  width: 11px;
  height: 11px;
  fill: currentColor;
  transform: translateX(1px);
}

@media (hover: none), (pointer: coarse) {
  .lightbox-thumbnails {
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: translate(-50%, 0) !important;
  }
}

@media (max-width: 680px) {
  .lightbox-thumbnails {
    bottom: .75rem;
    max-width: calc(100% - 1.5rem);
    padding: .45rem;
    gap: .4rem;
  }

  .lightbox-thumbnail {
    width: 52px;
    height: 42px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lightbox-thumbnails,
  .lightbox-thumbnail {
    transition: none;
  }
}


.lightbox-description-block[hidden] {
  display: none;
}
