/* The gallery stays white; only the opened artwork has a dark backdrop. */
body.page-key-questions:has(.is-artwork-open) .series-nav-back { display: none; }
html:has(.page-key-questions .is-artwork-open) { background: #101116; color-scheme: dark; }
body.page-key-questions:has(.is-artwork-open),
body.page-key-questions .kq-room.is-artwork-open,
body.page-key-questions:has(.is-artwork-open) .site-header,
body.page-key-questions:has(.is-artwork-open) .site-footer { background: #101116; color: #d8dce3; }
body.page-key-questions:has(.is-artwork-open) .site-footer {
  background: #101116 !important; color: #a9b4c2;
  border-top-color: #ffffff14;
}
body.page-key-questions:has(.is-artwork-open) .site-header .nav a,
body.page-key-questions:has(.is-artwork-open) .series-nav-back { color: #aeb9c7; }
body.page-key-questions:has(.is-artwork-open) .site-header .nav a:hover,
body.page-key-questions:has(.is-artwork-open) .site-header .nav a.active,
body.page-key-questions:has(.is-artwork-open) .series-nav-back:hover { color: #f1f4f8; }
body.page-key-questions:has(.is-artwork-open) .site-header .nav a.active::before { background: #aeb9c7; }
body.page-key-questions:has(.is-artwork-open) .site-header .logo-anim .ltr { color: #d8dce3; }

.page-key-questions button.kq-frame-photo {
  display: block; width: 100%; padding: 0; border: 0;
  background: transparent; cursor: pointer; font: inherit;
}
.page-key-questions button.kq-frame-photo:focus-visible {
  outline: 2px solid #66869b; outline-offset: 8px;
}
.page-key-questions .kq-room.is-artwork-open {
  align-items: flex-start; padding: 48px 4vw 60px;
}
.kq-room.is-artwork-open > .kq-piece { display: none; }
.kq-artwork-detail[hidden] { display: none; }
.kq-artwork-detail {
  position: relative; display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  align-items: center; gap: clamp(24px, 4vw, 64px);
  width: 100%; max-width: 1280px; margin: 0 auto; padding: 0;
}
.kq-detail-image { align-self: start; min-width: 0; animation: kq-artwork-appear 900ms ease both; }
.kq-detail-image img {
  display: block; width: auto; height: auto; max-width: 100%;
  max-height: calc(100svh - 220px); margin: 0 auto; object-fit: contain;
}
.kq-detail-info {
  align-self: start; padding-top: 8px;
  animation: kq-info-appear 850ms 180ms ease both;
}
/* Title and technical caption typography live in artwork-caption.css. */
.kq-artwork-size { white-space: nowrap; }
.kq-audio-play {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; margin: 12px 0 0; padding: 8px;
  border: 1px solid #a9b4c23d; border-radius: 50%; background: transparent;
  color: #c3ccd6; cursor: pointer; transition: color .2s, border-color .2s;
}
.kq-audio-play[hidden] { display: none; }
.kq-audio-play svg { width: 22px; height: 22px; fill: currentColor; }
.kq-audio-icon-pause, .kq-audio-play[aria-pressed="true"] .kq-audio-icon-play { display: none; }
.kq-audio-play[aria-pressed="true"] .kq-audio-icon-pause { display: block; }
.kq-audio-play:hover { color: #fff; border-color: #c3ccd6; }
.kq-audio-play:focus-visible { outline: 2px solid #66869b; outline-offset: 4px; }
.kq-detail-description { margin-top: 26px; max-width: 560px; }
.kq-detail-description p {
  margin: 0 0 16px; color: #c3ccd6;
  font-family: var(--sans-2); font-size: 14px; line-height: 1.85;
}
.kq-detail-description p:last-child { margin-bottom: 0; }
.kq-detail-poem p { line-height: 1.75; margin-bottom: 20px; }
.kq-artwork-detail:has(.kq-detail-poem) .kq-detail-image { align-self: start; }
.kq-artwork-detail:has(.kq-detail-poem) .kq-detail-info { padding-top: 8px; }
.kq-detail-close {
  position: absolute; right: 0; top: -12px; z-index: 2;
  border: 0; padding: 8px; background: transparent;
  color: #a9b4c2; font-size: 30px; line-height: 1; cursor: pointer;
}
.kq-detail-close:hover { color: #f1f4f8; }
.kq-detail-close:focus-visible { outline: 2px solid #66869b; outline-offset: 4px; }
@keyframes kq-artwork-appear {
  from { opacity: 0; transform: translateX(24px); }
  to { opacity: 1; transform: none; }
}
@keyframes kq-info-appear {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}
@media (max-width: 800px) {
  .page-key-questions .kq-room.is-artwork-open { padding: 60px 6vw 60px; }
  .kq-artwork-detail { grid-template-columns: 1fr; gap: 28px; }
  .kq-detail-image img { max-height: 65svh; }
  .kq-detail-info { padding-top: 0; }
  .kq-detail-close { top: -36px; }
}
@media (prefers-reduced-motion: reduce) {
  .kq-detail-image, .kq-detail-info { animation: none; }
}
