@charset "UTF-8";

:root {
  --paper: #f3f0e9;
  --ink: #11110f;
  --line: rgba(17, 17, 15, .22);
  --gap: clamp(12px, 1.7vw, 28px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  color: var(--ink);
  background: var(--paper);
  font-family: Arial, Helvetica, "PingFang SC", "Microsoft YaHei", sans-serif;
  text-rendering: optimizeLegibility;
}
body.lightbox-open { overflow: hidden; }
button, a { font: inherit; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

.topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  height: 56px;
  padding: 0 clamp(16px, 2.6vw, 42px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  background: rgba(243, 240, 233, .88);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
}

main { padding: var(--gap); }

.opening {
  min-height: calc(100svh - 80px);
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(260px, .72fr);
  gap: var(--gap);
}
.opening-stack {
  min-width: 0;
  display: grid;
  grid-template-rows: .82fr 1.18fr;
  gap: var(--gap);
}

.photo {
  position: relative;
  display: block;
  width: 100%;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: #d9d5cc;
  cursor: zoom-in;
}
.photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .8s cubic-bezier(.2, .7, .2, 1), filter .35s ease;
}
.photo:hover img { transform: scale(1.018); }
.photo:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.hero img { object-position: 50% 45%; }
.square img { object-position: 50% 36%; }
.portrait img { object-position: 50% 38%; }

.index {
  position: absolute;
  left: 10px;
  bottom: 10px;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--ink);
  background: rgba(243, 240, 233, .9);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .08em;
}

.breath {
  height: clamp(180px, 31vw, 450px);
  display: grid;
  place-items: center;
  font-size: clamp(13px, 1.25vw, 18px);
  letter-spacing: .32em;
}

.sequence {
  display: grid;
  grid-template-columns: minmax(250px, .72fr) minmax(0, 1.5fr);
  align-items: end;
  gap: var(--gap);
}
.tall { aspect-ratio: 832 / 1800; }
.wide { aspect-ratio: 1 / 1; }
.wide img { object-position: center 48%; }

footer {
  height: 100px;
  padding: 0 2px 4px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .18em;
}
footer a { font-size: 18px; line-height: 1; }

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .75s ease, transform .75s cubic-bezier(.2, .7, .2, 1);
}
.reveal.visible { opacity: 1; transform: none; }

.lightbox {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 28px clamp(14px, 4vw, 60px);
  overflow: hidden;
  border: 0;
  color: #fff;
  background: rgba(10, 10, 9, .96);
}
.lightbox::backdrop { background: rgba(10, 10, 9, .84); }
.lightbox[open] {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) 52px;
  align-items: center;
}
.lightbox figure {
  width: 100%;
  height: 100%;
  margin: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  place-items: center;
  gap: 14px;
}
.lightbox figure img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
}
.lightbox figcaption {
  font-size: 10px;
  letter-spacing: .2em;
  color: rgba(255, 255, 255, .72);
}
.lightbox-close,
.lightbox-nav {
  padding: 0;
  border: 0;
  color: #fff;
  background: transparent;
  cursor: pointer;
}
.lightbox-close {
  position: fixed;
  z-index: 3;
  top: max(12px, env(safe-area-inset-top));
  right: max(16px, env(safe-area-inset-right));
  width: 42px;
  height: 42px;
  font-size: 30px;
  font-weight: 300;
}
.lightbox-nav {
  width: 48px;
  height: 48px;
  font-size: 24px;
  opacity: .72;
  transition: opacity .2s ease;
}
.lightbox-nav:hover { opacity: 1; }

@media (max-width: 760px) {
  :root { --gap: 10px; }
  .topbar {
    height: 48px;
    padding: 0 12px;
    font-size: 9px;
  }
  main { padding: 10px; }
  .opening {
    min-height: auto;
    grid-template-columns: 1fr;
  }
  .hero { aspect-ratio: 4 / 3; }
  .opening-stack {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: none;
  }
  .square,
  .portrait { aspect-ratio: 1 / 1.22; }
  .breath { height: 170px; font-size: 10px; }
  .sequence {
    grid-template-columns: .8fr 1.2fr;
    align-items: start;
  }
  .wide { margin-top: 72px; }
  .index {
    left: 7px;
    bottom: 7px;
    width: 26px;
    height: 26px;
    font-size: 9px;
  }
  .lightbox { padding: 48px 10px 18px; }
  .lightbox[open] {
    grid-template-columns: 36px minmax(0, 1fr) 36px;
  }
  .lightbox-nav { width: 34px; font-size: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .photo img,
  .reveal { transition: none; }
  .reveal { opacity: 1; transform: none; }
}
