.scene {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  align-items: center;
  gap: .4rem;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: 1.1rem;
  color: #fff;
  font: inherit;
  background: transparent;
  -webkit-tap-highlight-color: transparent;
}

.scene:enabled { cursor: pointer; }
.scene:disabled .scene-label { display: none; }
.scene:focus-visible { outline: 3px solid #ffe24c; outline-offset: 4px; }

.dury-portrait {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 1 / 1.01;
}

.dury-portrait::before {
  content: "";
  position: absolute;
  width: 99%;
  aspect-ratio: 1;
  border: 1px solid #c6e3ff4a;
  border-radius: 50%;
  background: radial-gradient(circle, #a8dbff3b, #76b9ff15 68%, transparent 70%);
  box-shadow: 0 0 0 .65rem #bcddff13;
}

.dury-portrait img {
  position: absolute;
  width: 115%;
  height: 115%;
  object-fit: contain;
  filter: drop-shadow(.55rem .6rem .75rem #061b3e44);
}

.scene-label {
  z-index: 1;
  max-width: 100%;
  padding: .38rem .55rem;
  border: 1px solid #c7e5ff58;
  border-radius: 1rem;
  color: #fff;
  background: #092a55ac;
  font-size: .78rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
}

.scene-label span { color: #ffe55d; }
.scene:is(:hover, :focus-visible) .scene-label { border-color: #ffeb80; }

.dury-dialog {
  width: min(calc(100% - 1.25rem), 29rem);
  max-width: none;
  max-height: calc(100% - 1.25rem);
  padding: clamp(.8rem, 4vw, 1.3rem);
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid #d2e0f0;
  border-radius: 1.4rem;
  background: #fff;
  color: #102846;
  box-shadow: 0 1.2rem 3.5rem #061b3d50;
}

.dury-dialog::backdrop { background: #081c37b8; }
body:has(.dury-dialog[open]) { overflow: hidden; }

.dury-dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .7rem;
  margin: 0 0 .7rem;
}

.dury-dialog h2 { margin: 0; font-size: 1.3rem; line-height: 1.3; letter-spacing: -.045em; }

.dury-close, .dury-control-buttons button {
  min-width: 2.75rem;
  min-height: 2.75rem;
  padding: .24rem .65rem;
  border: 1px solid #d1e0f1;
  border-radius: .7rem;
  background: #f3f7fd;
  color: #133d6f;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.dury-close { font-size: 1.45rem; line-height: 1; }
.dury-dialog button:hover { background: #e6effa; }
.dury-dialog :is(button, model-viewer):focus-visible { outline: 3px solid #1765b5; outline-offset: 2px; }

.dury-stage {
  position: relative;
  display: grid;
  place-items: center;
  isolation: isolate;
  height: clamp(10rem, 52svh, 22rem);
  border: 1px solid #d9e8f9;
  border-radius: 1rem;
  background: radial-gradient(ellipse at 46% 35%, #fff 10%, #e2efff 67%, #cfdef0 100%);
}

.dury-poster {
  position: absolute;
  width: 96%;
  height: 91%;
  object-fit: contain;
  pointer-events: none;
}

.dury-stage model-viewer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  opacity: 0;
  --progress-bar-height: 0px;
}

.dury-stage model-viewer[data-ready] { opacity: 1; cursor: grab; }
.dury-stage model-viewer[data-ready]:active { cursor: grabbing; }

.dury-status, .dury-controls p {
  margin: .7rem 0 0;
  color: #375273;
  font-size: .88rem;
  line-height: 1.55;
  text-align: center;
  text-wrap: pretty;
}

.dury-control-buttons {
  display: grid;
  grid-template-columns: auto minmax(0, 7rem) auto;
  justify-content: center;
  gap: .45rem;
  margin-top: .55rem;
}

@media (max-height: 32rem) {
  .dury-stage { height: clamp(8.5rem, 49svh, 15rem); }
}
