/* Shared layout for the two interactive project pages. */
.model-frame { position: relative; width: 100%; aspect-ratio: 2 / 1; max-height: 76vh; max-height: 76svh; }
.model-frame canvas, .model-frame .model-poster { position: absolute; inset: 0; width: 100%; height: 100%; }
.model-frame .model-poster { display: block; object-fit: contain; background: #252a25; }
.viewer-ready .model-poster, .viewer-ready .model-fallback { display: none; }
.viewer:not(.viewer-ready) :is(.controls, details, .note, .hint) { display: none; }
.model-fallback { margin: 0; padding: 12px 16px; color: #d0d6cd; }
.viewer .controls { align-items: center; }
.viewer .controls :is(button, label), .viewer summary { min-height: 44px; }
.viewer .controls input[type=range] { min-height: 44px; margin-block: 0; }
.viewer [hidden] { display: none !important; }
header { align-items: center; }
header a { display: inline-flex; align-items: center; min-height: 44px; }
header a:last-child { flex-shrink: 0; }
@media (max-width: 1024px) {
  .model-frame { aspect-ratio: 1.65; }
}
@media (max-width: 650px) {
  header { padding-block: 10px; }
  .model-frame { aspect-ratio: 1.26; }
  .viewer .controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 14px; padding: 10px 12px; }
  .viewer .controls label { min-width: 0; display: flex; gap: 6px; }
  .viewer .controls input[type=range] { flex: 1; width: 0; min-width: 0; max-width: none; }
  .viewer .controls button { white-space: normal; padding: 7px 9px; line-height: 1.25; }
  .viewer .controls input[type=checkbox] { width: 18px; height: 18px; flex-shrink: 0; }
  .viewer :is(.hint,.note) { padding-inline: 12px; }
}
@media (max-height: 520px) and (orientation: landscape) {
  .model-frame { aspect-ratio: 2.3; max-height: 75vh; max-height: 75svh; }
}
