.model-page {
  width: 100%;
  max-width: none;
  margin: 0 auto;
  padding: 1.5rem 0 3rem;
}

.model-title {
  margin: 0 0 1rem;
  text-align: center;
}

.viewer-shell {
  position: relative;
  width: 100%;
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.viewer-loader {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(230, 230, 230, 0.95);
  z-index: 1;
  color: #333;
  font-size: 1.5rem;
  gap: 1rem;
  border-radius: 12px;
}

.spinner {
  width: 48px;
  height: 48px;
  border: 5px solid #bbb;
  border-top: 5px solid #333;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

model-viewer {
  width: 100%;
  height: 75vh;
  background: #f4f4f4;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  outline: none;
}

.model-description {
  max-width: 900px;
  margin: 2rem auto 0;
  line-height: 1.7;
}

.scene-gallery {
  max-width: 900px;
  margin: 2.5rem auto 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.scene-gallery__item {
  margin: 0;
}

.scene-gallery__image {
  display: block;
  width: 100%;
  border-radius: 10px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.13);
}

.scene-gallery__caption {
  margin-top: 0.6rem;
  display: grid;
  gap: 0.35rem;
  color: #5b6470;
  font-size: 0.95rem;
  line-height: 1.5;
}

.scene-gallery__caption a {
  color: #0b63ce;
}

@media (max-width: 700px) {
  .model-page {
    padding-left: 0;
    padding-right: 0;
  }

  .model-title {
    font-size: 1.5rem;
    padding: 0 1rem;
  }

  .viewer-shell {
    min-height: 60vh;
  }

  model-viewer {
    width: 100%;
    height: 60vh;
    border-radius: 0;
  }

  .scene-gallery {
    padding: 0 1rem;
  }
}