@font-face {
  font-family: "Panorama video icons";
  src: url("panorama-video-icons.woff2") format("woff2");
  font-display: block;
}
* { box-sizing: border-box }
[hidden] { display: none !important }
html,body { width: 100%; height: 100%; margin: 0; overflow: hidden; background: #000; color: #fff; font: 14px/1.5 Arial,"Microsoft YaHei",sans-serif }
button,input { font: inherit }
button { cursor: pointer }
button:focus-visible,input:focus-visible { outline: 2px solid #58a6ff; outline-offset: 2px }
#pano,.video-poster { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none }
.video-poster { object-fit: cover }
.video-brand { position: absolute; z-index: 2; top: 15px; left: 16px; display: flex; align-items: center; gap: 6px; color: #fff; font-size: 16px; font-weight: 700; text-shadow: 0 1px 4px #0009; text-decoration: none }
.video-brand img { width: 28px; height: 28px; border-radius: 5px }
.video-controls { position: absolute; left: 50%; bottom: max(40px,env(safe-area-inset-bottom)); z-index: 3; transform: translateX(-50%) }
.video-tools { display: flex; align-items: center; padding: 0 10px; width: max-content; background: rgb(0 0 0 / 55%); border-radius: 10px }
.video-tools button { position: relative; display: grid; place-items: center; width: 34px; height: 56px; padding: 0; border: 0; background: none; color: #fff }
.video-tools button:disabled { opacity: .55; cursor: default }
.video-tools span { font: 24px/1 "Panorama video icons" }
.video-tools button:is(:hover,:focus-visible)::after { content: attr(data-hint); position: absolute; bottom: calc(100% + 3px); padding: 7px 6px; border-radius: 5px; background: rgb(0 0 0 / 62%); color: #fff; white-space: nowrap; font: 12px/1.5 Arial,"Microsoft YaHei",sans-serif; pointer-events: none }
.video-message { position: absolute; z-index: 2; top: 50%; left: 50%; margin: 0; padding: 9px 14px; max-width: calc(100% - 32px); transform: translate(-50%,-50%); border: 0; border-radius: 6px; background: #000b; color: #fff; text-align: center; pointer-events: none }
.video-dialog { width: min(580px,calc(100% - 32px)); height: min(380px,calc(100% - 32px)); padding: 0; overflow: auto; border: 0; border-radius: 5px; background: #fff; color: #222 }
.video-dialog::backdrop { background: #0008 }
.video-dialog header { display: flex; align-items: center; justify-content: space-between; height: 50px; padding: 0 15px; border-bottom: 1px solid #eee }
.video-dialog h1 { margin: 0; font-size: 14px; font-weight: 600 }
.video-dialog form button { width: 30px; height: 30px; padding: 0; border: 0; background: none; color: #999; font-size: 24px; line-height: 1 }
.video-description { margin: 0; padding: 17px 15px; white-space: pre-line; overflow-wrap: anywhere }
.video-share-panel { display: grid; justify-items: center; gap: 12px; padding: 20px 15px; text-align: center }
#video-share-code { padding: 6px; background: #fff }
.video-copy { width: min(440px,100%); display: flex; align-items: center; gap: 8px }
.video-copy input { flex: 1; min-width: 0; padding: 7px; border: 1px solid #ddd; border-radius: 4px }
.video-copy button { padding: 7px 10px; border: 0; border-radius: 4px; background: #252525; color: #fff; white-space: nowrap }
#video-share-status { min-height: 21px }
@media (max-height: 520px) {
  .video-controls { bottom: max(18px,env(safe-area-inset-bottom)) }
}
.video-legacy-controls { display: none !important }

/* Sharing fits its content; long introductions keep their own scrolling. */
.video-dialog.video-sharing {height:max-content;max-height:calc(100% - 32px);overflow:hidden}
.video-sharing .video-share-panel {padding:12px 15px;gap:8px;min-width:0}
.video-sharing #video-share-code :is(img,canvas) {width:min(192px,calc(100dvh - 200px)) !important;height:auto !important;max-width:100%}
.video-sharing .video-copy {max-width:100%}
