@font-face {
  font-family: 'Avenir LT Std';
  src: url('fonts/AvenirLTStd-Roman.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: 'Avenir LT Std';
  src: url('fonts/AvenirLTStd-Medium.woff2') format('woff2');
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: 'Avenir LT Std';
  src: url('fonts/AvenirLTStd-Heavy.woff2') format('woff2');
  font-weight: 800;
  font-display: swap;
}

@font-face {
  font-family: 'Inter';
  src: url('fonts/Inter-400.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: 'Inter';
  src: url('fonts/Inter-600.woff2') format('woff2');
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: 'Inter';
  src: url('fonts/Inter-700.woff2') format('woff2');
  font-weight: 700;
  font-display: swap;
}

:root {
  --bg: #171717;
  --bg-band: #1d1d1d;
  --card-border: #1f1f1f;
  --fg: #fff;
  --fg-muted: rgba(255, 255, 255, 0.5);
  --gutter: 120px;
  --content: 960px;
}

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: 'Avenir LT Std', Avenir, 'Avenir Next', 'Helvetica Neue', Arial, sans-serif;
  font-weight: 400;
  line-height: normal;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

.arrow {
  width: 18px;
  height: 18px;
  flex: none;
}

/* ---------- Top bar ---------- */

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  transition: transform 0.3s ease, background-color 0.3s ease;
  height: 51px;
  padding: 0 var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar.is-hidden {
  transform: translateY(-100%);
}

.topbar.is-solid {
  background-color: rgba(0, 0, 0, 0.15);
}

@media (prefers-reduced-motion: reduce) {
  .topbar {
    transition: none;
  }
}

.topbar .logo svg {
  display: block;
  width: 25px;
  height: 25px;
}

.topbar nav {
  display: flex;
  gap: 30px;
  font-weight: 800;
  font-size: 18px;
}

.topbar nav a,
.profile-links a,
.btn,
.pager a {
  transition: opacity 0.2s ease;
}

.topbar nav a:hover,
.profile-links a:hover,
.pager a:hover {
  opacity: 0.7;
}

/* ---------- Hero / profile ---------- */

.hero {
  position: relative;
  height: 524px;
  background: var(--bg) url('assets/hero-bg.jpg') center top / cover no-repeat;
}

.profile {
  position: absolute;
  top: 149px;
  left: 50%;
  transform: translateX(-50%);
  width: 574px;
  display: flex;
  gap: 20px;
}

.portrait {
  flex: none;
  width: 226px;
  height: 226px;
  padding: 7px;
  border: 2px solid #fff;
}

.portrait img {
  width: 208px;
  height: 208px;
  object-fit: cover;
}

.profile-text {
  padding-top: 23px;
}

.profile-name {
  font-weight: 800;
  font-size: 46px;
  white-space: nowrap;
}

.profile-role {
  font-weight: 800;
  font-size: 18px;
}

.profile-bio {
  font-weight: 500;
  font-size: 18px;
  width: 328px;
  margin-top: 14px;
}

.profile-links {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 14px;
}

/* ---------- Project cards (Work page) ---------- */

.cards {
  width: 1200px;
  max-width: calc(100% - 2 * var(--gutter));
  margin: 56px auto 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.card {
  position: relative;
  height: 400px;
  display: grid;
  grid-template-columns: 480px 1fr;
}

.card::after {
  content: '';
  position: absolute;
  inset: 0;
  border: 5px solid var(--card-border);
  pointer-events: none;
}

.card-body {
  padding: 0 50px 0 120px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 10px;
}

.card-media {
  position: relative;
  overflow: hidden;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Videos sit over their still and fade in once playing (vault.js adds .is-playing). */
.media-video {
  position: absolute;
  top: 0;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.media-video.is-playing {
  opacity: 1;
}

/* Figma crops the 932px banner inside the 720px frame, offset -212px. */
.card-video {
  left: -29.444%;
  width: 129.444%;
}

.band-media {
  position: relative;
}

.panel-video {
  width: 33.343%;
}

.panel-left {
  left: 0;
}

.panel-right {
  left: 66.657%;
}

.card-title {
  font-weight: 800;
  font-size: 28px;
}

.card-desc {
  font-size: 14px;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 15px;
  border: 1px solid #fff;
  border-radius: 28px;
  font-weight: 800;
  font-size: 12px;
  line-height: 1;
  padding-top: 2px;
}

.tag-design { color: #ff2d70; border-color: #ff2d70; background: rgba(255, 45, 112, 0.31); }
.tag-direction { color: #ffc862; border-color: #ffc862; background: rgba(255, 200, 98, 0.31); }
.tag-uiux { color: #ff5900; border-color: #ff5900; background: rgba(255, 89, 0, 0.31); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 37px;
  width: 97px;
  background: #fff;
  border: 1px solid #fff;
  color: #000;
  font: inherit;
  font-weight: 500;
  font-size: 18px;
  cursor: pointer;
}

.btn:hover {
  opacity: 0.85;
}

/* ---------- Footer ---------- */

.site-footer {
  margin-top: auto;
  padding: 56px 0 0;
  height: 99px;
  text-align: center;
  font-size: 12px;
  color: var(--fg-muted);
}

.divider {
  width: 1200px;
  max-width: calc(100% - 2 * var(--gutter));
  margin: 0 auto;
  border: 0;
  border-top: 2px solid var(--card-border);
}

/* ---------- Project page ---------- */

.project {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 50px;
}

.project-hero {
  width: 100%;
  display: flex;
  justify-content: center;
  padding-top: 51px;
  height: 524px;
  background: var(--bg) url('assets/project-hero-bg.jpg') center top / cover no-repeat;
}

.project-hero .card-body {
  width: 480px;
  padding: 0 50px 0 0;
}

.project-hero .card-body > * {
  max-width: 310px;
}

.project-hero-media {
  width: 480px;
  margin-top: 30.67px;
}

.project-hero-media img {
  width: 480px;
  height: auto;
}

.section-title {
  width: var(--content);
  max-width: calc(100% - 48px);
  font-weight: 800;
  font-size: 24px;
}

.row {
  width: var(--content);
  max-width: calc(100% - 48px);
}

.caption {
  font-size: 14px;
  margin-top: 10px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.grid-4.gapped {
  gap: 14px;
}

.grid-4 img {
  width: 100%;
  height: auto;
}

.split {
  display: grid;
  grid-template-columns: 480px 1fr;
  align-items: start;
}

.split.narrow {
  grid-template-columns: 360px 1fr;
}

.split.center {
  align-items: center;
}

.text-block {
  padding: 50px 50px 0 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.split.final {
  height: 507px;
  align-items: center;
}

.split.final .text-block {
  padding-top: 0;
}

.text-block h2 {
  font-weight: 800;
  font-size: 24px;
}

.text-block p {
  font-size: 14px;
}

.pair {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.pair img {
  min-width: 0;
  height: auto;
}

.band {
  width: 100%;
}

.band img {
  width: 100%;
  height: auto;
}

.bands {
  width: 100%;
}

.assets-band {
  background: var(--bg-band);
  padding: 65px 0 43px;
}

.assets-band .inner {
  width: var(--content);
  max-width: calc(100% - 48px);
  margin: 0 auto;
}

.tiles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 13px;
}

.tiles img {
  width: 100%;
  height: auto;
}

.band-caption {
  width: var(--content);
  max-width: calc(100% - 48px);
  margin: 10px auto 0;
  font-size: 14px;
}

.pager {
  width: 720px;
  max-width: 100%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  font-weight: 500;
  font-size: 18px;
}

.pager a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 31px;
}

.pager .prev .arrow {
  transform: scaleX(-1);
}

.pager-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 50px;
  margin-top: 50px;
}

.pager-wrap + .site-footer {
  padding-top: 50px;
  height: auto;
  padding-bottom: 28px;
}

.coming-soon {
  padding: 200px 24px 120px;
  text-align: center;
}

.coming-soon h1 {
  font-weight: 800;
  font-size: 28px;
  margin-bottom: 8px;
}

.coming-soon p {
  font-size: 14px;
  color: var(--fg-muted);
  margin-bottom: 40px;
}

.vault-status {
  min-height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--fg-muted);
}

/* ---------- Project 2 ---------- */

/* Hero variant: 360px text column + 600px media, both centred in the 524px band. */
.project-hero.hero-wide {
  padding-top: 0;
  align-items: center;
  background-image: url('assets/project-2-hero-bg.jpg');
}

.project-hero.hero-wide .card-body {
  width: 360px;
  gap: 6px;
}

.hero-video {
  position: relative;
  width: 600px;
  margin-top: 0;
  overflow: hidden;
}

.hero-video img {
  width: 600px;
  height: auto;
}

.media-video.fill {
  left: 0;
  width: 100%;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: start;
}

.shot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.shot-label {
  font-weight: 800;
  font-size: 14px;
  text-align: center;
}

.shot img {
  width: 100%;
  height: auto;
}

/* The sticker art overhangs its 600x265 frame by a few px (shadows, rotation). */
.categories {
  position: relative;
  height: 265px;
}

.categories img {
  position: absolute;
  top: 0;
  left: -2px;
  width: 604px;
  max-width: none;
  height: auto;
}

.wcag {
  background: var(--bg-band);
  padding: 20px 40px;
  overflow: hidden;
}

.wcag-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 15.83px;
  font-family: 'Inter', Arial, sans-serif;
  font-size: 9.6px;
  line-height: normal;
}

.wcag-group {
  display: flex;
  flex-direction: column;
  gap: 6.4px;
}

.wcag-hex {
  font-weight: 600;
  line-height: 12px;
}

.wcag-swatch,
.wcag-on {
  position: relative;
  width: 96.02px;
  overflow: hidden;
}

.wcag-swatch {
  height: 96.02px;
}

.wcag-on {
  height: 40.01px;
}

.wcag-on.on-white {
  background: #fff;
  border: 0.8px solid #e6e6e6;
}

.wcag-on.on-black {
  background: #000;
}

.wcag-text,
.wcag-mark {
  position: absolute;
  white-space: nowrap;
}

.wcag-mark {
  font-weight: 700;
  font-size: 11.2px;
}

.wcag-mark.lt.pass { color: #008000; }
.wcag-mark.lt.fail { color: #c00; }
.wcag-mark.dk.pass { color: #80ff80; }
.wcag-mark.dk.fail { color: #f66; }

.on-swatch-black { left: 7.2px; top: 11.2px; color: #000; }
.on-swatch-white { left: 7.2px; top: 28.01px; color: #fff; }
.m-black { left: 76.01px; top: 9.6px; }
.m-white { left: 76.01px; top: 26.4px; }
.on-white .wcag-text { left: 6.4px; top: 12.8px; }
.on-white .wcag-mark { left: 79.22px; top: 12px; }
.on-black .wcag-text { left: 7.2px; top: 13.6px; }
.on-black .wcag-mark { left: 80.02px; top: 12.8px; }

.wcag-caption {
  font-size: 14px;
  margin-top: 10px;
}

.device-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.device-panel {
  position: relative;
  background: var(--panel);
}

.device-panel img {
  width: 100%;
  height: auto;
}

.device-panel figcaption {
  position: absolute;
  left: 0;
  right: 0;
  top: 93.95%;
  text-align: center;
  font-size: 14px;
}

.device-panel.phones figcaption {
  top: 93.04%;
}

/* ---------- Responsive ---------- */

@media (max-width: 1100px) {
  .split,
  .split.narrow {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .text-block,
  .split.final .text-block {
    padding: 0;
  }

  .split.final {
    height: auto;
  }

  .project-hero {
    height: auto;
    flex-direction: column;
    align-items: center;
    padding: 96px 24px 0;
    gap: 32px;
  }

  .project-hero .card-body {
    width: 100%;
    max-width: 480px;
    padding: 0;
  }

  .project-hero .card-body > * {
    max-width: none;
  }

  .project-hero-media {
    width: 100%;
    max-width: 480px;
    margin: 0;
  }

  .project-hero-media img {
    width: 100%;
  }

  .project-hero.hero-wide {
    align-items: center;
    padding-top: 96px;
  }

  .project-hero.hero-wide .card-body {
    max-width: 480px;
  }

  .hero-video {
    max-width: 600px;
  }
}

@media (max-width: 900px) {
  :root {
    --gutter: 15px;
  }

  .grid-3,
  .device-pair {
    grid-template-columns: 1fr;
  }

  .grid-3 {
    gap: 24px;
  }

  .categories {
    height: auto;
  }

  .categories img {
    position: static;
    width: 100%;
  }

  .wcag {
    padding: 20px 16px;
  }

  .wcag-grid {
    grid-template-columns: repeat(auto-fill, 96.02px);
    justify-content: center;
  }

  .device-panel figcaption {
    position: static;
    padding: 0 16px 14px;
  }

  .hero {
    height: auto;
    padding: 85px 0 20px;
  }

  .profile {
    position: static;
    transform: none;
    width: auto;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
    padding: 0 16px;
  }

  .profile-text {
    padding-top: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .profile-name {
    white-space: normal;
  }

  .profile-bio {
    width: auto;
    max-width: 328px;
  }

  .cards {
    width: auto;
    max-width: none;
    margin: 55px 16px 0;
  }

  .card {
    height: auto;
    display: flex;
    flex-direction: column-reverse;
    padding: 5px;
  }

  .card-media {
    aspect-ratio: 361 / 200;
  }

  .card-body {
    padding: 20px 15px;
  }

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

  .site-footer {
    padding-top: 40px;
    font-size: 11px;
  }

  .pager {
    grid-template-columns: auto 1fr auto;
    padding: 0 16px;
    font-size: 16px;
  }

  .pager a {
    white-space: nowrap;
  }
}
