@font-face {
  font-family: "Google Sans";
  src: url("./fonts/GoogleSans-Variable.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  color: #4a4a5c;
  background: #fff;
  font-family: "Google Sans", Arial, sans-serif;
  font-optical-sizing: auto;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;
  --color: #4a4a5c;
  --accent-color: #2d0000;
  --link-color: #3a57ff;
  --gutter: clamp(20px, 4vw, 60px);
  --content: 980px;
  --section-space: clamp(44px, 6vw, 80px);
}

* { box-sizing: border-box; }
html { scrollbar-width: none; }
body, h1, h2, h3, h4, p { margin: 0; }
button { font: inherit; color: inherit; }
strong { font-weight: var(--weight-bold); }
img, video { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: .3em; }
a:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

.site-header {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 30px var(--gutter);
  background: #fff;
}

.site-header a { text-decoration: none; }
.site-header a:hover, .site-header a[aria-current] { text-decoration: underline; }
.site-name {
  font-size: clamp(1.375rem, 1.15rem + 1vw, 2rem);
  font-weight: var(--weight-medium);
  line-height: 1.15;
}
.site-header nav {
  display: flex;
  gap: 10px;
  font-size: clamp(1rem, .9rem + .4vw, 1.125rem);
  line-height: 1.25;
  white-space: nowrap;
}
.site-header nav a:not([aria-current]) { font-variation-settings: "GRAD" -50; }
.site-header nav a[aria-current] { font-weight: var(--weight-semibold); }

.content-width {
  width: min(var(--content), calc(100% - 2 * var(--gutter)));
  margin-inline: auto;
}

.home-intro {
  padding-block: clamp(48px, 6vw, 80px);
  text-align: center;
}
.home-intro h1 {
  max-inline-size: 20em;
  margin-inline: auto;
  font-size: clamp(1.75rem, 1.1rem + 2.6vw, 3.125rem);
  font-weight: var(--weight-regular);
  font-variation-settings: "GRAD" -50;
  line-height: 1.12;
  letter-spacing: -.025em;
  text-wrap: balance;
}
.home-intro h1 strong {
  font-weight: var(--weight-semibold);
  font-variation-settings: normal;
}
.home-intro-role {
  margin-block-start: clamp(20px, 3vw, 30px);
  font-size: 1rem;
  font-weight: var(--weight-medium);
  line-height: 1.4;
  color: #656573;
  text-wrap: balance;
}
.home-intro::after { content: ""; display: block; width: 140px; height: 1px; margin: 20px auto 0; background: #4a4a5c; }

@media (min-width: 58rem) {
  .home-intro h1 > span { display: block; }
}

.case-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding-top: 3px; }
.case-card {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 1;
  color: #fff;
  background: #4a4a5c;
  text-decoration: none;
}
.case-card:focus-visible { outline-offset: -4px; }
.case-card img, .case-card video { width: 100%; height: 100%; object-fit: cover; }
.case-card-caption {
  position: absolute;
  inset: auto 0 0;
  display: grid;
  gap: 6px;
  padding: clamp(72px, 11vw, 128px) clamp(22px, 4vw, 56px) clamp(24px, 4vw, 48px);
  background: linear-gradient(to bottom, transparent, rgb(17 17 24 / 68%) 63%, rgb(17 17 24 / 80%));
}
.case-card-title {
  font-size: clamp(1.5rem, 3.4vw, 2.75rem);
  font-weight: var(--weight-semibold);
  line-height: 1.1;
  text-wrap: balance;
}
.case-card-subtitle {
  font-size: clamp(.9375rem, 1.6vw, 1.25rem);
  line-height: 1.35;
  color: #f2f1f5;
}
.case-card:hover .case-card-title, .case-card:focus-visible .case-card-title {
  text-decoration: underline;
  text-decoration-thickness: 1px;
}

.case-cover {
  position: relative;
  display: flex;
  align-items: end;
  min-height: clamp(280px, 48svh, 540px);
  padding: clamp(32px, 4vw, 60px) var(--gutter);
  overflow: hidden;
}
.case-cover-image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.case-cover-copy { position: relative; width: min(100%, var(--content)); margin-inline: auto; }
.case-cover h1 { font-size: clamp(36px, 6.8vw, 92px); font-weight: var(--weight-regular); line-height: 1.02; overflow-wrap: anywhere; }
.case-cover h2 { margin-top: 6px; font-size: clamp(19px, 2.6vw, 32px); font-weight: var(--weight-regular); line-height: 1.25; }

.case-overview { padding-block: clamp(24px, 3.2vw, 40px); border-bottom: 1px solid #dedee6; }
.case-overview dl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 3vw, 40px); margin: 0; }
.case-overview dt { margin-bottom: 6px; font-size: 16px; font-weight: var(--weight-semibold); }
.case-overview dd { max-width: 37ch; margin: 0; font-size: 16px; line-height: 1.45; }
.case-overview-action {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  margin-top: 12px;
  color: var(--link-color);
  font-weight: var(--weight-medium);
  text-underline-offset: .25em;
}

.case-block { padding: var(--block-padding, var(--section-space) 0); }
.copy-text { line-height: 1.5; overflow-wrap: anywhere; }
.copy-text p, .copy-text li { white-space: pre-line; }
.copy-text p:empty { min-height: 1.5em; }
:where(.copy-text) :is(h1, h2, h3) { font-size: inherit; font-weight: inherit; }
.copy-text a { color: var(--link-color); font-weight: var(--weight-medium); }
.block-intro .block-content { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 3fr); align-items: start; }
.block-intro .copy-text:not(.section-label) { font-size: var(--block-font-size, 18px); line-height: 1.45; }
.section-label { padding-right: 20px; color: var(--accent-color); font-size: clamp(26px, 3.4vw, 40px); line-height: 1.38; }
.section-label strong, .block-header strong { font-weight: var(--weight-semibold); }
.block-columns .block-content { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px; align-items: start; }
.block-standard :is(img, video), .block-columns :is(img, video), .block-gallery :is(img, video) {
  width: 100%;
  height: auto;
}
.block-standard .image-zoom { width: min(100%, var(--media-width, 100%)); margin-inline: auto; }
.block-standard .caption { margin-top: 22px; font-size: 18px; line-height: 1.22; text-align: center; }
.block-text .copy-text { font-size: var(--block-font-size, 17px); line-height: 1.41; }
.block-header { text-align: center; }
.block-header .copy-text { font-size: var(--block-font-size, 28px); line-height: 1; padding-block: 10.5px; }
.block-gallery .block-content { display: grid; }
.image-zoom { display: block; width: 100%; padding: 0; border: 0; background: transparent; cursor: zoom-in; }
.image-zoom:focus-visible, .carousel button:focus-visible, .carousel-track:focus-visible, .dialog-close:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: -3px;
}

.carousel { position: relative; width: min(1615px, calc(100% - 2 * var(--gutter) - 70px)); margin-inline: auto; }
.carousel-track { display: flex; gap: 50px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; cursor: grab; }
.carousel-track.is-dragging { scroll-snap-type: none; cursor: grabbing; }
.carousel-slide { flex: 0 0 100%; height: min(800px, 55vw); scroll-snap-align: start; display: flex; justify-content: center; }
.carousel-slide img { width: auto; height: 100%; object-fit: contain; user-select: none; pointer-events: none; }
.carousel-arrow { position: absolute; top: 50%; width: 35px; height: 44px; padding: 0; transform: translateY(-50%); border: 0; background: #fff; font-size: 34px; cursor: pointer; }
.carousel-arrow:disabled { opacity: .35; cursor: auto; }
.carousel-previous { right: 100%; }
.carousel-next { left: 100%; }

.dialog-open { overflow: hidden; }
.media-dialog { width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 48px; border: 0; background: transparent; color: #fff; }
.media-dialog[open] { display: grid; place-items: center; }
.media-dialog::backdrop { background: rgb(0 0 0 / 92%); }
.dialog-media { display: contents; }
.dialog-media :is(img, video) { max-width: 100%; max-height: calc(100svh - 96px); object-fit: contain; }
.dialog-close { position: absolute; top: 8px; right: 10px; width: 44px; height: 44px; padding: 0; border: 0; background: transparent; color: inherit; font-size: 34px; line-height: 1; cursor: pointer; }

[data-reveal] > :first-child { transition: opacity 500ms ease, transform 500ms ease; }
[data-reveal].is-waiting > :first-child { opacity: 0; transform: translateY(50px); }

.about-arrow { height: 150px; font-size: 50px; text-align: center; line-height: 150px; }
.about-profile { --about-name-size: clamp(30px, 4vw, 40px); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding-block: var(--section-space); }
.portrait { align-self: start; margin-block-start: calc(var(--about-name-size) * .33); padding-right: clamp(25px, 5vw, 100px); }
.portrait img { width: min(100%, 390px); aspect-ratio: 1; object-fit: cover; }
.about-name { font-size: var(--about-name-size); }
.about-role { font-size: clamp(19px, 2.4vw, 25px); line-height: 1.4; }
.about-tagline { max-width: 36ch; margin-top: 12px; font-size: clamp(18px, 2vw, 21px); line-height: 1.4; }
.about-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px clamp(14px, 2vw, 22px);
  margin-top: 20px;
  font-weight: var(--weight-medium);
}
.about-actions a { display: inline-flex; align-items: center; min-height: 44px; }
.about-resume { padding-inline: 16px; border-radius: 6px; color: #fff; background: var(--color); text-decoration: none; }
.about-resume:hover { background: #353546; }
.about-bio { margin-top: 32px; font-size: 16px; }
.about-bio p + p { margin-top: .75em; }
.about-bio-section { margin-top: 24px; }
.about-bio :is(h2, h3) { margin-bottom: 8px; font-size: 18px; font-weight: var(--weight-semibold); }
.about-bio-section ul { margin: 0; padding-inline-start: 20px; }
.about-bio-section li + li { margin-top: 4px; }
.about-bio-note { margin-top: 20px; font-size: 15px; color: #656573; }
.about-english { margin-top: 32px; padding-top: 24px; border-top: 1px solid #dedee6; }
.block-contact { padding-block: 120px; text-align: center; font-size: clamp(18px, 2.5vw, 24px); }

.site-footer { padding: 20px 0 30px; font-size: 10px; }
.footer-content { display: flex; align-items: center; justify-content: space-between; min-height: 24px; }
.site-footer a { display: block; width: 24px; height: 24px; color: var(--color); }
.site-footer a::after { content: ""; display: block; margin: 2px; width: 20px; height: 20px; background: currentColor; mask: url("./icons/linkedin.svg") center / contain no-repeat; }

.visually-hidden { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; white-space: nowrap; }

@media (max-width: 680px) {
  .site-header { flex-wrap: wrap; column-gap: 12px; row-gap: 14px; padding-block: 20px; }
  .case-grid, .block-intro .block-content, .block-columns .block-content, .about-profile { grid-template-columns: minmax(0, 1fr); }
  .case-cover { min-height: clamp(228px, 40svh, 325px); padding-block: 28px; }
  .case-overview dl { grid-template-columns: minmax(0, 1fr); }
  .case-overview dd { max-width: 54ch; }
  .block-intro .block-content { gap: 14px; }
  .about-profile { gap: 30px; }
  .portrait { margin-block-start: 0; padding: 0; }
  .portrait img { width: min(100%, clamp(180px, 58vw, 250px)); height: auto; }
  .about-arrow { height: 56px; font-size: 36px; line-height: 56px; }
  .case-block { padding: var(--section-space) 0; }
  .media-dialog { padding-inline: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal] > :first-child { transition: none; }
  [data-reveal].is-waiting > :first-child { opacity: 1; transform: none; }
}
