:root {
  --background: #fff;
  --text: #1f1f1f;
  --muted: #8c8c8c;
  --faint: #d2d2d2;
  --header-height: 108px;
  --page-x: clamp(22px, 4.45vw, 64px);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--background);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 14px;
  letter-spacing: 0;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--background);
}

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

button {
  font: inherit;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  min-height: var(--header-height);
  padding: 44px var(--page-x) 24px;
  pointer-events: none;
}

.brand,
.site-menu,
.menu-toggle {
  pointer-events: auto;
}

.brand {
  font-size: 14px;
  line-height: 1;
}

.site-menu {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(18px, 2.4vw, 36px);
  color: var(--muted);
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
}

.site-menu a {
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
  transition: color 180ms ease, opacity 180ms ease;
}

.site-menu a:hover,
.site-menu a[aria-current] {
  color: var(--text);
}

.site-menu a[aria-current] {
  border-bottom-color: currentColor;
}

.instagram-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
}

.instagram-link svg {
  display: block;
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.35;
}

.menu-toggle {
  display: none;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--muted);
}

#app {
  min-height: 100vh;
  outline: none;
}

.gallery-page {
  padding: calc(var(--header-height) + 12px) var(--page-x) 72px;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: clamp(22px, 2.7vw, 38px);
  align-items: start;
  width: min(100%, 1180px);
  margin-inline: auto;
}

.photo-thumb {
  display: block;
  aspect-ratio: 367 / 300;
  overflow: hidden;
  background: #f7f7f7;
}

.photo-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 180ms ease;
}

.photo-thumb:hover img {
  opacity: 0.82;
}

.slideshow-page {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 112px var(--page-x) 96px;
}

.slide-figure {
  display: grid;
  place-items: center;
  width: min(70.8vw, 1020px);
  margin: 0;
}

.slide-image {
  display: block;
  max-width: 100%;
  max-height: min(72vh, 650px);
  width: auto;
  height: auto;
}

.index-link,
.slide-count {
  position: fixed;
  z-index: 12;
  bottom: 64px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1;
}

.index-link {
  left: var(--page-x);
}

.slide-count {
  left: 50%;
  transform: translateX(-50%);
}

.slide-zone {
  position: fixed;
  z-index: 10;
  top: var(--header-height);
  bottom: 0;
  width: 27vw;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
}

.slide-zone::after {
  position: absolute;
  top: 50%;
  color: var(--faint);
  font-size: 52px;
  font-weight: 200;
  line-height: 1;
  opacity: 0;
  transform: translateY(-50%);
  transition: opacity 180ms ease;
}

.slide-zone:hover::after,
.slide-zone:focus-visible::after {
  opacity: 1;
}

.slide-zone-prev {
  left: 0;
}

.slide-zone-prev::after {
  left: var(--page-x);
  content: "\2039";
}

.slide-zone-next {
  right: 0;
}

.slide-zone-next::after {
  right: var(--page-x);
  content: "\203A";
}

.profile-page {
  padding: calc(var(--header-height) + 18px) var(--page-x) 92px;
}

.profile-inner {
  width: min(770px, 100%);
  margin-inline: auto;
  color: #2a2a2a;
}

.profile-page h1 {
  margin: 0 0 26px;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.4;
}

.profile-text h2 {
  margin: 42px 0 13px;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.6;
}

.profile-text p {
  margin: 0 0 18px;
  color: #505050;
  font-size: 13px;
  line-height: 1.95;
}

.profile-text h2 + p {
  margin-top: 0;
}

.profile-text a {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

@media (min-width: 1180px) {
  .photo-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 860px) {
  :root {
    --header-height: 82px;
    --page-x: 22px;
  }

  .site-header {
    min-height: var(--header-height);
    padding-top: 26px;
  }

  .menu-toggle {
    display: block;
    font-size: 12px;
  }

  .site-menu {
    position: fixed;
    top: 58px;
    left: var(--page-x);
    right: var(--page-x);
    display: none;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 18px 24px;
    padding: 18px 0 22px;
    background: rgba(255, 255, 255, 0.94);
    white-space: normal;
  }

  .menu-open .site-menu {
    display: flex;
  }

  .gallery-page {
    padding-top: calc(var(--header-height) + 8px);
  }

  .photo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .slideshow-page {
    padding: 86px 22px 82px;
  }

  .slide-figure {
    width: 100%;
  }

  .slide-image {
    max-height: 62vh;
  }

  .slide-zone {
    top: var(--header-height);
    width: 50vw;
  }

  .slide-zone::after {
    display: none;
  }

  .index-link,
  .slide-count {
    bottom: 34px;
  }

  .profile-page {
    padding-top: calc(var(--header-height) + 18px);
  }

  .profile-inner {
    margin-left: 0;
  }
}

@media (max-width: 480px) {
  html {
    font-size: 13px;
  }

  .brand {
    font-size: 13px;
  }

  .photo-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .profile-text p {
    font-size: 12px;
    line-height: 1.9;
  }
}
