html.intro-pending::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 10000;
  pointer-events: none;
  background: #61798b url("/obrazy/intro-cirrus-v3.webp") center / contain no-repeat;
}

.studio-intro[open] {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  color: #fff;
  background: #566d80;
  overscroll-behavior: contain;
}

.studio-intro::backdrop { background: #566d80; }
html:has(.studio-intro[open]) { overflow: hidden; }

.studio-intro::before {
  content: "";
  position: absolute;
  inset: -5%;
  background: url("/obrazy/intro-cirrus-v3.webp") center / cover no-repeat;
  filter: blur(26px) brightness(.66);
}

.studio-intro video {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  object-fit: contain;
  pointer-events: none;
}

.intro-actions {
  position: absolute;
  inset-inline: max(1.25rem, env(safe-area-inset-left)) max(1.25rem, env(safe-area-inset-right));
  bottom: max(1.25rem, env(safe-area-inset-bottom));
  display: flex;
  justify-content: space-between;
  gap: .75rem;
}

.intro-actions button {
  min-height: 44px;
  padding: .6rem 1.15rem;
  border: 1px solid rgb(255 255 255 / 62%);
  border-radius: 2rem;
  background: #283e4ce8;
  color: #fff;
  font: 600 .95rem/1.35 Barlow, "Segoe UI", sans-serif;
  cursor: pointer;
}
.intro-actions button:hover { background: #1d3341; }
.intro-actions button:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }

@media (max-aspect-ratio: 1/1) {
  html.intro-pending::before { background-size: 125% auto; }
  .studio-intro video {
    width: 125%;
    height: auto;
    max-width: none;
    aspect-ratio: 16/9;
    grid-area: 1/1;
    justify-self: center;
    mask-image: linear-gradient(transparent, black 14%, black 86%, transparent);
  }
}

@media print {
  html.intro-pending::before, .studio-intro[open], [data-replay-intro] { display: none; }
}
