/* Keep perspective on the viewport plane without extending a 3D context
   through the sticky offset. The film still animates in depth inside it. */
#hero-dashboard-section > .sticky { transform-style: flat !important; }
.sumit-story-dock {
  position: fixed;
  right: max(28px, env(safe-area-inset-right));
  bottom: max(28px, env(safe-area-inset-bottom));
  z-index: 900;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 14px;
  pointer-events: none;
  isolation: isolate;
}
.sumit-story-portrait {
  position: relative;
  width: 208px;
  max-height: min(54vh, 390px);
  aspect-ratio: var(--portrait-aspect, 9 / 16);
  overflow: hidden;
  border: 1px solid rgba(218, 202, 255, .23);
  border-radius: 20px;
  background: #101015;
  box-shadow: 0 18px 56px #0009, 0 0 24px #b19fff12;
  backdrop-filter: blur(14px);
  opacity: 0;
  transform: translateY(12px) scale(.92);
  transform-origin: bottom right;
  visibility: hidden;
  transition: opacity 380ms ease, transform 380ms cubic-bezier(.22,1,.36,1), visibility 380ms;
}
.sumit-story-dock[data-portrait-visible="true"] .sumit-story-portrait {
  opacity: 1;
  transform: translateY(0) scale(1);
  visibility: visible;
  pointer-events: auto;
}
.sumit-story-portrait video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}
.sumit-story-portrait img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center 15%;
}
.sumit-story-dock[data-portrait-video="true"] .sumit-story-portrait img { visibility: hidden; }
.sumit-story-dock[data-portrait-video="false"] .sumit-story-portrait video { visibility: hidden; }
.sumit-story-portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 1px 0 #ffffff26;
  pointer-events: none;
}
.sumit-story-portrait-label {
  position: absolute;
  inset: auto 0 0;
  padding: 24px 14px 12px;
  background: linear-gradient(transparent, #000b);
  color: #fff;
  font-family: var(--font-geist-mono, monospace);
  font-size: 12px;
  letter-spacing: .16em;
  z-index: 1;
}
.sumit-story-controls { display: flex; align-items: center; gap: 10px; pointer-events: auto; }
.sumit-story-controls button, .sumit-film-fullscreen {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  border: 1px solid #ffffff26;
  background: rgba(13, 13, 18, .85);
  box-shadow: inset 0 1px 0 #ffffff14, 0 6px 24px #0007;
  backdrop-filter: blur(18px);
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, transform 180ms ease;
}
.sumit-story-controls button:hover, .sumit-film-fullscreen:hover { border-color: #b19fff9c; background: #24212eeb; }
.sumit-story-controls button:active, .sumit-film-fullscreen:active { transform: scale(.95); }
.sumit-story-controls button:focus-visible, .sumit-film-fullscreen:focus-visible { outline: 2px solid #d5bfff; outline-offset: 4px; }
.sumit-story-play { width: 56px; height: 56px; border-radius: 50%; }
.sumit-story-play svg { width: 20px; height: 20px; }
.sumit-story-play[aria-busy="true"] svg { animation: sumit-story-buffering 900ms linear infinite; }
@keyframes sumit-story-buffering { to { transform: rotate(360deg); } }
.sumit-story-sound { min-height: 44px; min-width: 44px; border-radius: 24px; padding: 0 13px; gap: 8px; }
.sumit-story-sound svg { width: 18px; height: 18px; flex-shrink: 0; }
.sumit-story-sound span { font: 12px var(--font-geist-mono, monospace); white-space: nowrap; }
.sumit-story-dock[data-started="false"] .sumit-story-sound { display: none; }
.sumit-film-fullscreen {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 30;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  opacity: 0;
}
.sumit-film-fullscreen svg { width: 17px; height: 17px; }
video[data-story-cinematic]:focus-visible { outline: 2px solid #ceb1fa; outline-offset: -4px; }
video[data-story-cinematic]:hover ~ .sumit-film-fullscreen,
.sumit-film-fullscreen:hover, .sumit-film-fullscreen:focus-visible { opacity: 1; }
@media (max-width: 767px) {
  .sumit-story-dock { right: max(16px, env(safe-area-inset-right)); bottom: calc(16px + env(safe-area-inset-bottom)); gap: 10px; }
  .sumit-story-portrait { width: 136px; max-height: 32vh; border-radius: 16px; }
  .sumit-story-play { width: 48px; height: 48px; }
  .sumit-film-fullscreen { opacity: 1; }
}
@media (max-height: 550px) { .sumit-story-portrait { width: 120px; max-height: 42vh; } }
@media (prefers-reduced-motion: reduce) {
  .sumit-story-portrait, .sumit-story-dock[data-portrait-visible="true"] .sumit-story-portrait { transform: none; transition: opacity 150ms ease, visibility 150ms; }
  .sumit-story-controls button, .sumit-film-fullscreen { transition: none; }
  .sumit-story-play[aria-busy="true"] svg { animation: none; }
}
