:root {
  --surface: #ffffff;
  --text: #111111;
  --muted: #757575;
  --line: oklch(92.42% 0.005 264.54 / 0.7);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Inter", sans-serif;
  color: var(--text);
  background: var(--surface);
  position: relative;
}

body::before,
body::after {
  content: "";
  position: fixed;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--line);
  pointer-events: none;
  z-index: 20;
}

body::before {
  left: max(calc((100vw - 820px) / 2), 36px);
}

body::after {
  right: max(calc((100vw - 820px) / 2), 36px);
}

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

.project-shell {
  --section-inline: 28px;
  width: min(100%, 820px);
  margin: 0 auto;
}

.project-shell > site-header,
.project-shell > section {
  padding-inline: var(--section-inline);
}

.project-shell > site-header {
  display: block;
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--surface);
}

.project-shell > site-header::before,
.project-shell > site-header::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--line);
  pointer-events: none;
}

.project-shell > site-header::before {
  left: 0;
}

.project-shell > site-header::after {
  right: 0;
}

.project-shell .topbar {
  position: relative;
  padding: 12px 0;
}

.project-shell .topbar::after {
  content: "";
  position: absolute;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  bottom: 0;
  height: 1px;
  background: var(--line);
}

.project-hero {
  position: relative;
  padding: 84px 28px 72px;
}

.project-hero::after {
  content: "";
  position: absolute;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  bottom: 0;
  height: 1px;
  background: var(--line);
}

.project-back-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 22px;
  color: #6f6f6f;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  transition: color 160ms ease, transform 160ms ease;
}

.project-back-link:hover {
  color: var(--text);
  transform: translateX(-2px);
}

.project-hero h1 {
  margin: 0;
  max-width: 12ch;
  font-size: clamp(2rem, 4.2vw, 3.8rem);
  font-weight: 400;
  line-height: 0.94;
  letter-spacing: -0.07em;
}

.project-lead {
  margin: 22px 0 0;
  max-width: 580px;
  color: var(--muted);
  font-size: clamp(1.15rem, 2vw, 1.42rem);
  line-height: 1.26;
  letter-spacing: -0.04em;
}

.project-overview {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 36px;
  padding-top: 44px;
}

.project-text-block h3 {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: -0.03em;
}

.project-text-block p {
  margin: 0;
  color: #5f5f5f;
  font-size: 0.98rem;
  line-height: 1.55;
  letter-spacing: -0.015em;
}

.project-gallery {
  display: grid;
  gap: 18px;
  padding-top: 52px;
  padding-bottom: 64px;
}

.project-visual {
  margin: 0;
}

.project-visual img {
  display: block;
  width: 100%;
  height: auto;
  background: #171717;
}

.project-visual-detail img {
  object-fit: cover;
}

@media (max-width: 960px) {
  body::before {
    left: 32px;
  }

  body::after {
    right: 32px;
  }

  .project-shell {
    --section-inline: 32px;
    width: 100%;
  }

  .project-overview {
    grid-template-columns: 1fr;
    gap: 26px;
  }
}

@media (max-width: 640px) {
  body::before {
    left: 24px;
  }

  body::after {
    right: 24px;
  }

  .project-shell {
    --section-inline: 24px;
  }

  .project-hero {
    padding-top: 54px;
    padding-bottom: 48px;
  }

  .project-hero h1 {
    font-size: 2.25rem;
  }

  .project-lead {
    max-width: 100%;
    font-size: 1rem;
    line-height: 1.32;
  }

  .project-overview {
    padding-top: 30px;
  }

  .project-gallery {
    gap: 12px;
    padding-top: 32px;
    padding-bottom: 42px;
  }
}
