:root {
  --ink: #161616;
  --line: #d6d6d6;
  --footer: #e8e8e1;
  --muted: #626262;
  --page: 80px;
  --body-leading: 1.85;
  --paper-texture: url("/assets/paper-noise.svg?v=1af0a8915df4");
  font-family:
    "Noto Sans CJK JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.65;
  font-weight: 400;
  letter-spacing: 0.01em;
  background: #fff var(--paper-texture) top left/250px 250px;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
a {
  color: inherit;
  text-underline-offset: 5px;
}
button,
input,
select {
  font: inherit;
  color: inherit;
}
button,
a,
input,
select {
  touch-action: manipulation;
}
button {
  cursor: pointer;
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #416582;
  outline-offset: 4px;
}
button:disabled {
  cursor: default;
}
p,
h1,
h2 {
  margin: 0;
}
a:hover {
  text-decoration-thickness: 2px;
}
.skip {
  position: absolute;
  left: 20px;
  top: -80px;
  background: #fff;
  padding: 10px;
  z-index: 10;
}
.skip:focus {
  top: 10px;
}
.brand {
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-decoration: none;
  white-space: nowrap;
}
nav {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: center;
}
.external {
  vertical-align: middle;
  margin-left: 6px;
}
main {
  max-width: none;
  min-height: 60vh;
  margin: auto;
  padding: 32px var(--page) 64px;
}
.breadcrumb {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  font-size: 14px;
  margin-bottom: 48px;
  color: var(--muted);
}
.breadcrumb span:last-child {
  color: var(--ink);
}
h1.page-title {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 40px;
}
.filters {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 24px 0;
  margin-bottom: 28px;
}
.search-row {
  display: flex;
  gap: 12px;
  align-items: end;
  max-width: 700px;
  margin-bottom: 20px;
}
.search-row label {
  flex: 1;
}
.field-label {
  display: block;
  font-size: 14px;
  margin-bottom: 8px;
}
input[type="search"] {
  width: 100%;
  background: #fff;
  border: 1px solid #767676;
  padding: 11px 14px;
  border-radius: 0;
  min-height: 48px;
}
.button {
  border-radius: 999px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  border: 1px solid var(--ink);
  background: #fff;
  color: var(--ink);
  padding: 11px 24px;
  text-decoration: none;
  min-height: 48px;
}
.button:hover {
  background: #f1f1ee;
}
.button.dark {
  background: var(--ink);
  color: #fff;
}
.filter-row {
  display: flex;
  align-items: end;
  gap: 24px;
  flex-wrap: wrap;
}
select {
  border: 1px solid #767676;
  background: #fff;
  border-radius: 0;
  padding: 10px 34px 10px 12px;
  max-width: 100%;
  min-height: 46px;
}
.check {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
}
input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--ink);
}
.reset {
  border: 0;
  border-bottom: 1px solid;
  background: transparent;
  padding: 8px 0;
  min-height: 44px;
  margin-left: auto;
}
.results-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin: 28px 0 24px;
}
.results-top select {
  font-size: 14px;
}
.result-count {
  font-size: 16px;
}
.result-count strong {
  font-size: 22px;
  font-weight: 500;
}
.active-filters {
  font-size: 14px;
  color: var(--muted);
  margin: -12px 0 24px;
  overflow-wrap: anywhere;
}
.grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 40px 24px;
  padding: 8px 0;
}
.card {
  min-width: 0;
}
.card a {
  display: block;
  text-decoration: none;
}
.cover {
  background: #fff;
  border: 1px solid var(--line);
  padding: 16px 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cover-inner {
  width: 100%;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.cover img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.card a:hover .cover {
  border-color: #666;
}
.card h2 {
  font-size: 16px;
  line-height: 1.5;
  font-weight: 500;
  margin: 12px 0 6px;
  overflow-wrap: anywhere;
}
.card a:hover h2 {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.meta {
  font-size: 14px;
  color: var(--muted);
}
.cover-missing {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
  gap: 10px;
  color: #626262;
  background: #f7f7f5;
  font-size: 14px;
}
.cover-missing span:first-child {
  font-size: 18px;
  letter-spacing: 0.12em;
  color: #626262;
}
.more {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 48px 0 0;
}
.more button {
  width: 240px;
}
.progress {
  font-size: 14px;
  color: var(--muted);
}
.empty {
  padding: 70px 24px;
  text-align: center;
  border: 1px solid var(--line);
  background: #fff;
}
.empty h2 {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 12px;
}
.empty .button {
  margin-top: 24px;
}
.detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: start;
  margin-top: 40px;
}
.detail h1 {
  font-size: 24px;
  line-height: 1.5;
  font-weight: 500;
  margin: 8px 0 24px;
  overflow-wrap: anywhere;
}
.category-label {
  font-size: 14px;
  color: var(--muted);
}
dl {
  margin: 28px 0;
}
dl > div {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 20px;
  border-top: 1px solid var(--line);
  padding: 14px 0;
}
dt {
  color: var(--muted);
  font-size: 14px;
}
dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.back-row {
  display: flex;
  justify-content: center;
  padding-top: 64px;
}
.back-row a {
  min-width: 240px;
}
.detail-note {
  font-size: 14px;
  color: var(--muted);
}
footer {
  background: var(--footer) var(--paper-texture) top left/250px 250px repeat;
  padding: 64px var(--page);
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.office {
  font-size: 16px;
  font-weight: 500;
}
.copyright {
  font-size: 14px;
}
.noscript {
  padding: 40px;
}
@media (max-width: 1100px) {
  :root {
    --page: 40px;
  }
  .grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 40px 24px;
  }
  .detail {
    gap: 40px;
  }
}
@media (max-width: 700px) {
  :root {
    --page: 20px;
  }
  .brand {
    font-size: 20px;
  }
  .breadcrumb {
    margin-bottom: 32px;
  }
  main {
    padding-top: 24px;
  }
  .page-title {
    margin-bottom: 28px !important;
  }
  .search-row {
    gap: 8px;
  }
  .search-row .button {
    padding-left: 18px;
    padding-right: 18px;
  }
  .filter-row {
    gap: 16px;
  }
  .filter-row > label:not(.check) {
    flex: 1;
    min-width: 130px;
  }
  .filter-row select {
    width: 100%;
  }
  .reset {
    margin-left: 0;
  }
  .results-top {
    align-items: center;
  }
  .results-top select {
    max-width: 155px;
  }
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px 16px;
  }
  .card h2 {
    font-size: 16px;
  }
  .cover {
    padding: 12px 6px;
  }
  .detail {
    grid-template-columns: 1fr;
    gap: 32px;
    margin-top: 32px;
  }
  .detail .cover {
    max-width: 420px;
    width: 100%;
    margin: auto;
  }
  .detail h1 {
    font-size: 22px;
    margin-top: 8px;
  }
  .back-row {
    padding-top: 40px;
  }
  footer {
    padding-top: 64px;
    padding-bottom: 64px;
  }
  .copyright {
    font-size: 12px;
  }
  .result-count strong {
    font-size: 20px;
  }
  .search-row input {
    min-width: 0;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .cover {
    transition: border-color 0.15s;
  }
  .button {
    transition: background 0.15s;
  }
}
/* Figma layout, with the user-requested compact typography and spacing. */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
footer nav {
  gap: 24px;
}
.button {
  gap: 8px;
}
.prose {
  line-height: var(--body-leading);
}
.prose p + p {
  margin-top: 16px;
}
.home-main {
  max-width: none;
  padding: 0;
  min-height: 0;
}
.hero {
  --photo-gap: 16px;
  padding: 24px 0 0;
  overflow: hidden;
}
.hero-window {
  overflow: hidden;
}
.hero-track {
  display: flex;
  width: max-content;
  animation: photo-loop 60s linear infinite;
  will-change: transform;
}
.hero-group {
  display: flex;
  gap: var(--photo-gap);
  padding-right: var(--photo-gap);
  flex-shrink: 0;
}
.hero-group:first-child {
  margin-left: var(--photo-gap);
}
.hero-group:last-child {
  margin-right: calc(-1 * var(--photo-gap));
}
.hero-slide {
  width: min(38vw, 576px);
  aspect-ratio: 636/756;
  position: relative;
  flex-shrink: 0;
  overflow: hidden;
}
.hero-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-tree img {
  object-position: 55% center;
}
.hero.paused .hero-track {
  animation-play-state: paused;
}
.home-sections {
  max-width: none;
  margin: auto;
  padding: 0 var(--page);
}
.home-section {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 80px;
  border-top: 1px solid var(--line);
  padding: 120px 0;
}
.home-section > h2 {
  font-size: 20px;
  font-weight: 500;
}
.home-grid h2 {
  font-size: 16px;
}
.home-grid .cover {
  aspect-ratio: 1;
}
.home-grid .cover-inner {
  height: 100%;
  aspect-ratio: auto;
}
.archive-thumb {
  border: 1px solid var(--line);
  background: #fff;
  padding: 16px;
  aspect-ratio: 1;
}
.archive-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.archive-card a:hover .archive-thumb {
  border-color: #666;
}
.home-grid .card {
  min-width: 0;
}
.profile-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 454px);
  gap: 56px;
  margin-top: 56px;
}
.profile-layout h2 {
  font-size: 20px;
  font-weight: 500;
}
.reading {
  margin-top: 4px;
}
.profile-bio {
  margin: 40px 0;
}
.profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
.profile-photo {
  width: 100%;
  aspect-ratio: 454/540;
  position: relative;
  overflow: hidden;
}
.profile-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 55% center;
}
.history-intro {
  margin-top: -24px;
}
.decade-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  margin: 32px 0 64px;
  font-size: 14px;
}
.history section {
  margin: 0 0 64px;
  scroll-margin-top: 24px;
}
.history h2 {
  font-size: 24px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 16px;
  margin-bottom: 28px;
}
.history-row {
  display: grid;
  grid-template-columns: 180px 60px minmax(0, 1fr);
  gap: 24px;
  margin-bottom: 28px;
  line-height: var(--body-leading);
}
.history-age {
  white-space: nowrap;
}
.copyright-body {
  display: grid;
  gap: 40px;
  padding-top: 40px;
}
.info-box {
  background: #fff;
  border: 1px solid var(--line);
  padding: 24px;
}
.external-links {
  display: grid;
  gap: 20px;
}
.external-links a {
  color: #0b5b8c;
  overflow-wrap: anywhere;
}
.external-links p {
  font-weight: 600;
}
.info-box .button {
  margin-top: 16px;
}
.section-divider {
  width: 100%;
  height: 1px;
  margin: 80px 0;
  overflow: hidden;
}
.section-divider img {
  display: block;
}
.faq h2 {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 40px;
}
.faq .info-box {
  margin-bottom: 32px;
  padding: 20px;
}
.faq h3 {
  font-size: 16px;
  line-height: 1.8;
  margin: 0 0 12px;
}
.faq p {
  line-height: var(--body-leading);
}
.archive-intro {
  margin-top: -16px;
  margin-bottom: 40px;
}
.archive-types {
  display: flex;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}
.archive-types a {
  padding: 12px 4px;
  text-decoration: none;
  display: flex;
  gap: 12px;
  align-items: baseline;
}
.archive-types a[aria-current] {
  border-bottom: 2px solid #111;
  font-weight: 600;
}
.archive-types a span {
  font-size: 12px;
  color: var(--muted);
}
.archive-count {
  margin: 24px 0;
}
.archive-wall {
  columns: 3;
  column-gap: 32px;
}
.archive-entry {
  break-inside: avoid;
  margin: 0 0 40px;
  scroll-margin-top: 140px;
}
.archive-entry > img,
.archive-entry > video {
  display: block;
  width: 100%;
  height: auto;
}
.archive-entry figcaption {
  margin-top: 12px;
}
.archive-entry h2 {
  margin: 0;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.75;
}
.archive-entry figcaption p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
}
@media (min-width: 701px) and (max-width: 1100px) {
  .archive-wall {
    columns: 2;
  }
}
@media (max-width: 700px) {
  .archive-wall {
    columns: 1;
  }
}
.category-label + h1 {
  margin-top: 12px;
}
@keyframes photo-loop {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(var(--hero-loop-offset, -50%));
  }
}
@media (max-width: 1250px) {
  .site-header nav {
    width: 100%;
    gap: 12px;
    font-size: 14px;
    justify-content: space-between;
  }
  .home-section {
    grid-template-columns: 160px minmax(0, 1fr);
    gap: 40px;
    padding: 80px 0;
  }
  .profile-layout {
    gap: 40px;
    grid-template-columns: minmax(0, 1fr) minmax(240px, 35%);
  }
}
@media (max-width: 700px) {
  .site-header nav {
    justify-content: flex-start;
    gap: 4px 8px;
  }
  .hero {
    --photo-gap: 8px;
    padding-top: 8px;
  }
  .hero-slide {
    width: 68vw;
  }
  .home-section {
    display: block;
    padding: 64px 0;
  }
  .home-section > h2 {
    font-size: 20px;
    margin-bottom: 24px;
  }
  .home-grid h2 {
    font-size: 16px;
  }
  .profile-layout {
    display: flex;
    flex-direction: column-reverse;
    gap: 32px;
    margin-top: 32px;
  }
  .profile-photo {
    max-width: 360px;
    margin: auto;
  }
  .profile-bio {
    margin: 28px 0;
  }
  .history h2 {
    font-size: 22px;
  }
  .history-row {
    grid-template-columns: 1fr auto;
    gap: 8px 16px;
    margin-bottom: 28px;
  }
  .history-row p:last-child {
    grid-column: 1/-1;
  }
  .history-age {
    color: var(--muted);
  }
  .decade-nav {
    margin-bottom: 40px;
    gap: 12px 20px;
  }
  .history section {
    margin-bottom: 48px;
  }
  .archive-thumb {
    padding: 10px;
  }
  .archive-types {
    gap: 20px;
  }
  .archive-intro {
    line-height: var(--body-leading);
  }
  .copyright-body {
    padding-top: 16px;
    gap: 24px;
  }
  .info-box {
    padding: 20px;
  }
  .section-divider {
    margin: 48px 0;
  }
  .faq h2 {
    margin-bottom: 24px;
  }
  .faq .info-box {
    margin-bottom: 24px;
  }
  footer nav {
    gap: 16px;
    font-size: 14px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .hero-track {
    animation: none;
    will-change: auto;
  }
  .hero-group[aria-hidden] {
    display: none;
  }
  .hero-window {
    overflow-x: auto;
  }
  .motion-toggle {
    display: none;
  }
}

@media (max-width: 700px) {
  .site-header nav a {
    padding: 10px 8px;
  }
}

.brand {
  display: block;
  line-height: 0;
}
.brand img {
  display: block;
  width: 180px;
  height: auto;
}

/* Contact draft: local confirmation only, with no submission endpoint. */
.contact-page {
  max-width: 880px;
}
.contact-section {
  border-top: 1px solid var(--line);
  padding: 32px 0 40px;
}
.contact-section h2 {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 20px;
}
.contact-section h3 {
  font-size: 16px;
  font-weight: 500;
  margin: 32px 0 16px;
}
.contact-links {
  margin-top: 20px;
}
.contact-related {
  font-size: 14px;
  margin-top: 24px;
}
.contact-preview {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 24px;
}
.contact-page form {
  display: grid;
  gap: 10px;
}
.contact-page form[hidden],
.contact-page section[hidden] {
  display: none;
}
.contact-page label {
  margin-top: 16px;
}
.required-label,
.optional-label {
  font-size: 12px;
  font-weight: 400;
  margin-left: 10px;
  color: var(--muted);
}
.contact-page input:not([type="checkbox"]),
.contact-page textarea {
  font: inherit;
  color: inherit;
  width: 100%;
  min-width: 0;
  border: 1px solid #767676;
  border-radius: 0;
  background: #fff;
  padding: 12px;
  min-height: 48px;
}
.contact-page textarea {
  resize: vertical;
  line-height: 1.7;
}
.contact-page textarea:focus-visible {
  outline: 3px solid #416582;
  outline-offset: 4px;
}
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 24px;
}
.contact-actions button:disabled {
  color: #777;
  background: #e8e8e1;
  border-color: #ccc;
}
.contact-page dl > div {
  grid-template-columns: 160px minmax(0, 1fr);
}
.contact-page dd {
  white-space: pre-wrap;
}
@media (max-width: 700px) {
  .contact-section {
    padding: 24px 0 32px;
  }
  .contact-page dl > div {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .contact-actions .button {
    width: 100%;
  }
}

/* Updated Figma navigation: all links share the same treatment. */
/* Swipeable home cards; the next card peeks into view. */
.home-section > div {
  min-width: 0;
}
.home-carousel {
  min-width: 0;
  margin-bottom: 40px;
}
.home-grid.carousel-track {
  display: flex;
  gap: 32px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 4px;
  padding: 8px 4px 12px;
  margin: 0;
  scrollbar-width: thin;
  scrollbar-color: #bbb transparent;
}
.carousel-track > .card {
  flex: 0 0 clamp(240px, 21.56vw, 326px);
  scroll-snap-align: start;
}
.carousel-track:focus-visible {
  outline: 2px solid #416582;
  outline-offset: -2px;
}
.carousel-controls {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin-top: 12px;
}
.carousel-buttons {
  display: flex;
  gap: 8px;
}
.carousel-buttons button {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  background: transparent;
  border: 1px solid #767676;
  border-radius: 50%;
  font-size: 18px;
}
.carousel-buttons button[aria-disabled="true"] {
  opacity: 0.3;
}
.carousel-buttons button:not([aria-disabled="true"]):hover {
  background: #e8e8e1;
}
.archive-placeholder .archive-thumb {
  display: grid;
  place-items: center;
  background: transparent;
  border: 1px dashed #c6c6c0;
  color: var(--muted);
  font-size: 14px;
}
.archive-placeholder h2 {
  color: var(--muted);
}
@media (max-width: 1250px) {
  .carousel-track > .card {
    flex-basis: 280px;
  }
}
@media (max-width: 700px) {
  .home-grid.carousel-track {
    gap: 16px;
  }
  .carousel-track > .card {
    flex-basis: calc((100% - 16px) / 1.6);
  }
  .home-carousel {
    margin-bottom: 24px;
  }
}

/* Figma 164:59: the underline belongs to the inner label, outside the 8px side padding. */

/* Active navigation is emphasized; footer links remain unadorned. */
footer nav a {
  text-decoration: none;
}
.home-section > .prose {
  line-height: var(--body-leading);
}

/* Let only the home card viewport reach the browser’s right edge. */
.home-grid.carousel-track {
  width: calc(100% + var(--page));
  margin-right: calc(-1 * var(--page));
}

/* Figma 166:285: pill control over the lower-right corner of the photos. */
.hero {
  position: relative;
  padding-bottom: 40px;
}
.hero-controls {
  position: absolute;
  right: var(--page);
  bottom: 64px;
  padding: 0;
  margin: 0;
  z-index: 1;
}
.motion-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  padding: 8px 16px;
  border: 1px solid #000;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-size: 14px;
  font-weight: 400;
  line-height: 22px;
  white-space: nowrap;
  min-height: 44px;
}
.motion-toggle img {
  display: block;
  flex-shrink: 0;
}
.motion-toggle:hover {
  background: #f7f7f5;
}
@media (max-width: 700px) {
  .hero {
    padding-bottom: 24px;
  }
  .hero-controls {
    bottom: 40px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .hero-controls {
    display: none;
  }
}

footer nav a.current {
  font-weight: 700;
}
/* Switch on measured navigation width; keep the desktop labels on one row. */
.site-header {
  position: relative;
  flex-wrap: nowrap;
  gap: 32px;
  align-items: center;
}
.site-header #main-nav {
  display: flex;
  width: max-content;
  flex: 0 0 auto;
  flex-wrap: nowrap;
  gap: 0;
  padding: 0;
}
.site-header #main-nav .nav-links {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  width: auto;
  gap: clamp(8px, calc(4vw - 40px), 24px);
}
.site-header #main-nav .nav-links a {
  padding: 0 8px;
  font-size: 16px;
}
.site-header #main-nav .nav-label {
  padding: 16px 0;
}
.site-header .menu-toggle {
  display: none;
}
.site-header.compact #main-nav {
  position: absolute;
  top: 0;
  right: 0;
  visibility: hidden;
  pointer-events: none;
}
.site-header.compact .menu-toggle {
  display: inline-flex;
}
.menu-toggle {
  align-items: center;
  gap: 14px;
  padding: 10px 0 10px 12px;
  border: 0;
  background: none;
  min-width: 44px;
  min-height: 44px;
}
.menu-toggle-label {
  font-size: 13px;
  letter-spacing: 0.06em;
}
.menu-lines {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
  width: 24px;
  height: 24px;
}
.menu-lines i {
  display: block;
  height: 1px;
  width: 24px;
  background: currentColor;
}
.menu-is-open {
  overflow: hidden;
}
.menu-panel {
  position: fixed;
  inset: 0 0 0 auto;
  margin: 0;
  width: min(440px, 100%);
  max-width: 100%;
  height: 100dvh;
  max-height: 100dvh;
  padding: 32px 40px max(32px, env(safe-area-inset-bottom));
  border: 0;
  background: #fff var(--paper-texture) top left/250px 250px;
  color: var(--ink);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.menu-panel[open] {
  display: flex;
  flex-direction: column;
  animation: menu-enter 0.25s ease-out;
}
.menu-panel::backdrop {
  background: rgba(25, 23, 20, 0.32);
  backdrop-filter: blur(4px);
}
.menu-panel-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 32px;
}
.menu-panel-top h2 {
  font-size: 14px;
  font-weight: 400;
  color: var(--muted);
  letter-spacing: 0.08em;
}
.menu-close {
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  font-size: 28px;
  line-height: 1;
  display: grid;
  place-items: center;
}
.panel-nav {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
}
.panel-nav a {
  display: block;
  padding: 19px 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.6;
}
.panel-nav .nav-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.panel-nav .external {
  margin: 0;
}
.panel-nav a.current {
  font-weight: 700;
}
.panel-nav .nav-label {
  position: relative;
}
.panel-nav .nav-label::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  right: 0;
  height: 1px;
  background: currentColor;
}
.menu-panel-office {
  font-size: 12px;
  color: var(--muted);
  margin-top: auto;
  padding-top: 48px;
}
.menu-close:hover {
  background: #e8e8e1;
}
@keyframes menu-enter {
  from {
    transform: translateX(100%);
    opacity: 0.6;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}
@media (max-width: 480px) {
  .menu-panel {
    padding: 24px 24px max(24px, env(safe-area-inset-bottom));
  }
  .menu-panel-top {
    margin-bottom: 20px;
  }
  .panel-nav a {
    padding: 16px 0;
    font-size: 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .menu-panel[open] {
    animation: none;
  }
  .menu-panel::backdrop {
    backdrop-filter: none;
  }
}

.hero-window:focus-visible {
  outline: 3px solid #416582;
  outline-offset: -3px;
}
main:focus {
  outline: none;
}
.search-row label {
  min-width: 0;
}
footer nav a {
  display: inline-block;
  min-height: 24px;
}
.carousel-buttons button[aria-disabled="true"] {
  cursor: default;
}

/* Consolidated header styling; the dialog handles narrow layouts. */
.site-header {
  margin: auto;
  padding: 28px var(--page) 20px;
  display: flex;
  justify-content: space-between;
}
.site-header .brand {
  flex-shrink: 0;
}
.site-header nav a {
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}
.site-header nav a.current {
  font-weight: 700;
}
.site-header .nav-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  line-height: 1.5;
  position: relative;
}
.site-header .nav-label .external {
  margin: 0;
}
.site-header .nav-label::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
}
@media (max-width: 700px) {
  .site-header {
    padding-top: 24px;
    padding-bottom: 16px;
  }
}

/* Keep the active underline; reveal other labels on hover or keyboard focus. */
.site-header nav a,
.panel-nav a,
footer nav a {
  transition: color 180ms ease;
}
.site-header .nav-label::after,
.panel-nav .nav-label::after {
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 220ms ease;
}
.site-header a.current .nav-label::after,
.panel-nav a.current .nav-label::after,
.site-header nav a:focus-visible .nav-label::after,
.panel-nav a:focus-visible .nav-label::after {
  transform: scaleX(1);
}
.site-header nav a:focus-visible,
.panel-nav a:focus-visible,
footer nav a:focus-visible {
  color: #626262;
}
@media (hover: hover) {
  .site-header nav a:hover,
  .panel-nav a:hover,
  footer nav a:hover {
    color: #626262;
  }
  .site-header nav a:hover .nav-label::after,
  .panel-nav a:hover .nav-label::after {
    transform: scaleX(1);
  }
}
@media (prefers-reduced-motion: reduce) {
  .site-header nav a,
  .panel-nav a,
  footer nav a,
  .site-header .nav-label::after,
  .panel-nav .nav-label::after {
    transition: none;
  }
}

/* Lightweight vector arrows share the button text color. */
.arrow-icon {
  display: block;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}
.carousel-buttons .arrow-icon {
  width: 20px;
  height: 20px;
}
.carousel-prev .arrow-icon {
  transform: rotate(180deg);
}

.purchase-link {
  margin-top: 24px;
}
.purchase-link .detail-note {
  margin-top: 12px;
}

/* Separate home proposal. The original homepage has none of these elements. */
.home-proposal-bar {
  margin: 0 var(--page) 24px;
  padding: 12px 0;
  border-block: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 12px 24px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--muted);
}
.home-proposal-bar > div {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.home-news-content {
  max-width: 550px;
  width: 100%;
}
.home-news-intro {
  margin-bottom: 24px;
  line-height: var(--body-leading);
}
.home-news-feed {
  min-height: 560px;
  width: 100%;
}
.home-news-feed > a {
  display: inline-block;
  margin-top: 24px;
}
.home-news-help {
  font-size: 13px;
  color: var(--muted);
  margin: 20px 0;
}
.home-news .button {
  margin-top: 0;
}
@media (max-width: 700px) {
  .home-news-feed {
    min-height: 460px;
  }
  .home-proposal-bar > div {
    gap: 16px;
  }
}

.home-news-feed[hidden],
.home-news-sample[hidden] {
  display: none;
}
.news-preview-toggle {
  border: 0;
  background: none;
  color: inherit;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.news-preview-toggle[aria-pressed="true"] {
  font-weight: 700;
}
.news-sample-label {
  color: var(--muted);
  font-size: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}
.news-sample-post {
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}
.news-sample-author {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 14px;
}
.news-sample-author small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.news-sample-avatar {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 50%;
}
.news-sample-lines span {
  display: block;
  height: 5px;
  background: #deded8;
  margin-top: 12px;
  width: 94%;
}
.news-sample-lines span:last-child {
  width: 65%;
}
.news-sample-photo {
  height: 120px;
  border: 1px dashed #bcbcb6;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 13px;
  margin-top: 20px;
  border-radius: 12px;
}

/* Match the profile page columns while preserving the study photo proportions. */
.guidance-layout {
  align-items: start;
}
.guidance-layout > :first-child {
  min-width: 0;
}
.guidance-photo {
  width: 100%;
  aspect-ratio: 454 / 540;
  overflow: hidden;
}
.guidance-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 65% center;
}
@media (max-width: 700px) {
  .guidance-photo {
    max-width: 360px;
    margin-inline: auto;
  }
}

.profile-museum-action {
  margin-top: 16px;
}
.profile-museum-action .button {
  max-width: 100%;
}

/* The copyright source contains white margins above and below the photo. */
.copyright-photo {
  position: relative;
}
.copyright-photo img {
  position: absolute;
  height: 144.4%;
  top: -18.3%;
  object-position: 60% center;
}
.contact-photo img {
  object-position: 48% center;
}

.hero-crop img {
  position: absolute;
  width: 156.07%;
  height: 131.3%;
  left: -28.04%;
  top: -19.58%;
  max-width: none;
  object-fit: fill;
}

/* Photo loading never blocks navigation or the page content. */
.hero-window {
  position: relative;
}
.hero.is-loading .hero-track {
  animation-play-state: paused;
}
.hero-slide {
  background: #e9e9e5;
}
.hero-slide img {
  opacity: 0;
  transition: opacity 450ms ease;
}
.hero-slide.is-ready img {
  opacity: 1;
}
.hero-slide.is-failed img {
  visibility: hidden;
}
.hero-loading {
  position: absolute;
  inset: auto 0 24px;
  display: flex;
  justify-content: center;
  pointer-events: none;
}
.hero-loading[hidden] {
  display: none;
}
.hero-loading-line {
  display: block;
  width: 80px;
  height: 2px;
  background: #c4c4bd;
  overflow: hidden;
}
.hero-loading-line::after {
  content: "";
  display: block;
  width: 40%;
  height: 100%;
  background: #62625d;
  animation: hero-loading 1.4s ease-in-out infinite;
}
@keyframes hero-loading {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(350%);
  }
}
.hero-photo-error {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  font-size: 14px;
  color: #62625d;
}
@media (prefers-reduced-motion: reduce) {
  .hero-slide img {
    transition: none;
  }
  .hero-loading-line::after {
    animation: none;
    margin: auto;
  }
}

/* Restrict casual saving on photos, never on copy, forms or book covers. */
.protected-photo {
  -webkit-touch-callout: none;
  -webkit-user-drag: none;
  user-select: none;
  -webkit-user-select: none;
}
.photo-use-notice {
  margin: 48px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
}
.photo-use-notice a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.home-main > .photo-use-notice {
  margin: 0 var(--page) 48px;
}

.contact-trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
#contact-form .contact-consent {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  cursor: pointer;
}
#contact-form input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 0;
  padding: 0;
  flex: 0 0 18px;
}
#contact-status {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.privacy-policy { max-width: 800px; }
.privacy-policy section { margin-top: 40px; }
.privacy-policy h2 { font-size: 20px; margin-bottom: 16px; }
.footer-policy { font-size: 13px; margin-top: 24px; }
.footer-policy a { display: inline-flex; align-items: center; min-height: 44px; }
