/* Floating player has no modal backdrop and never captures outside clicks. */
.youtube-modal.gd-video-float{display:block;position:fixed;inset:0;z-index:10000;padding:0;pointer-events:none;background:none;backdrop-filter:none;}
.youtube-modal.gd-video-float[hidden]{display:none;}
.gd-video-float .youtube-modal-backdrop{display:none!important;}
.gd-video-float .youtube-modal-shell.gd-video-float-shell{position:absolute;max-width:none;min-width:0;aspect-ratio:auto;padding:28px 0 4px;box-sizing:border-box;background:#111;border:1px solid rgba(255,255,255,.12);border-radius:12px;overflow:hidden;pointer-events:auto;box-shadow:0 10px 36px rgba(0,0,0,.34);transform:none;}
.gd-video-float-shell iframe{width:100%;height:100%;display:block;border:0;background:#000;pointer-events:auto;}
.gd-video-float-rail{position:absolute;top:0;left:0;right:0;height:28px;display:flex;align-items:center;justify-content:center;cursor:grab;touch-action:none;user-select:none;-webkit-user-select:none;}
.gd-video-float-grip{width:34px;height:4px;border-radius:6px;background:rgba(255,255,255,.42);}
.gd-video-float-close{position:absolute;right:3px;top:1px;width:28px;height:26px;display:flex;align-items:center;justify-content:center;padding:0;border:0;border-radius:50%;background:transparent;color:#fff;font:22px/1 Arial,sans-serif;cursor:pointer;opacity:0;transition:opacity .15s;pointer-events:none;}
.gd-video-controls-visible .gd-video-float-close,.gd-video-float-close:focus-visible{opacity:1;pointer-events:auto;}
.gd-video-float-close:hover{background:rgba(255,255,255,.15);}
.gd-video-float-resize{position:absolute;right:0;bottom:0;width:28px;height:22px;border:0;cursor:nwse-resize;touch-action:none;user-select:none;background:linear-gradient(135deg,transparent 58%,rgba(255,255,255,.55) 59%,rgba(255,255,255,.55) 63%,transparent 64%,transparent 71%,rgba(255,255,255,.55) 72%,rgba(255,255,255,.55) 76%,transparent 77%);}
.gd-video-manipulating .gd-video-float-rail{cursor:grabbing;}
.gd-video-float-rail:focus-visible,.gd-video-float-resize:focus-visible,.gd-video-float-close:focus-visible{outline:2px solid #a5b4fc;outline-offset:-2px;}
body.youtube-modal-open{overflow:auto;}
@media(prefers-reduced-motion:reduce){.gd-video-float-close{transition:none;}}

.gd-video-float-grip,.gd-video-float-resize{opacity:0;transition:opacity .15s}
.gd-video-controls-visible .gd-video-float-grip,.gd-video-controls-visible .gd-video-float-resize,.gd-video-float-rail:focus-visible .gd-video-float-grip,.gd-video-float-resize:focus-visible{opacity:1}
.gd-video-float-rail{background:transparent}

/* Explicit user toggle; hidden chrome leaves only the unobstructed player. */
.gd-video-float .youtube-modal-shell.gd-video-float-shell{padding:0;background:transparent;border:0;border-radius:0;box-shadow:none}
.gd-video-float .gd-video-controls-visible.youtube-modal-shell{padding:28px 0 4px;background:#111;border-radius:10px;box-shadow:0 10px 36px rgba(0,0,0,.34)}
.gd-video-float-shell:not(.gd-video-controls-visible) .gd-video-float-rail,.gd-video-float-shell:not(.gd-video-controls-visible) .gd-video-float-resize,.gd-video-float-shell:not(.gd-video-controls-visible) .gd-video-float-close{display:none}
.gd-video-float-toggle{position:absolute;left:0;right:0;top:0;height:20px;width:100%;padding:0;border:0;background:transparent;z-index:2;cursor:pointer;touch-action:manipulation}
.gd-video-controls-visible .gd-video-float-toggle{top:28px}
.gd-video-float-toggle:focus-visible{outline:2px solid #a5b4fc;outline-offset:-2px;background:rgba(0,0,0,.15)}

:root{--gd-safe-left:env(safe-area-inset-left,0px);--gd-safe-right:env(safe-area-inset-right,0px);--gd-safe-top:env(safe-area-inset-top,0px);--gd-safe-bottom:env(safe-area-inset-bottom,0px)}

.gd-video-float-gesture{display:none;position:absolute;left:0;right:0;top:28px;bottom:4px;z-index:1;touch-action:none;user-select:none;cursor:grab}
.gd-video-controls-visible .gd-video-float-gesture{display:block}
.gd-video-float-gesture:focus-visible{outline:2px solid #a5b4fc;outline-offset:-2px}
