/* CIELO V64: home hero video background and two click-to-play film panels. */
.cielo-home-video-hero {isolation:isolate;}
.cielo-home-video-hero > img {z-index:0;}
.cielo-home-video-hero .cielo-hero-video {position:absolute;inset:0;overflow:hidden;z-index:1;pointer-events:none;}
.cielo-home-video-hero .cielo-hero-video iframe {position:absolute;left:50%;top:50%;width:max(100%,177.77778vh);height:max(100%,56.25vw);min-width:100%;min-height:100%;border:0;transform:translate(-50%,-50%);pointer-events:none;}
.cielo-home-video-hero .hero-shade {z-index:2;pointer-events:none;}
.cielo-home-video-hero .hero-copy,.cielo-home-video-hero .hero-location {z-index:3;}
.cielo-film-section {padding:clamp(64px,8vw,120px) 0;}
.cielo-film-layout {display:grid;grid-template-columns:minmax(0,.7fr) minmax(0,1.3fr);align-items:center;gap:clamp(28px,5vw,86px);}
.cielo-film-copy {max-width:520px;}
.cielo-film-copy h2 {font-size:clamp(30px,4vw,62px);line-height:1.12;margin:18px 0 20px;}
.cielo-film-copy p {font-size:clamp(14px,1.15vw,17px);line-height:1.7;color:var(--muted,#58675d);}
.cielo-film-frame {position:relative;overflow:hidden;border-radius:20px;aspect-ratio:16/9;background:#10291f;box-shadow:0 20px 55px rgba(20,42,30,.16);isolation:isolate;}
.cielo-film-poster {position:absolute;inset:0;width:100%;height:100%;object-fit:cover;}
.cielo-film-frame::after {content:"";position:absolute;inset:0;background:linear-gradient(0deg,rgba(8,25,20,.38),rgba(8,25,20,.08));pointer-events:none;}
.cielo-film-play {position:absolute;z-index:2;top:50%;left:50%;transform:translate(-50%,-50%);display:flex;flex-direction:column;align-items:center;gap:10px;white-space:nowrap;color:white;font-size:11px;font-weight:700;letter-spacing:.07em;background:none;border:0;cursor:pointer;text-shadow:0 2px 14px rgba(0,0,0,.4);padding:10px;max-width:90%;}
.cielo-film-play-symbol {display:grid;place-items:center;width:clamp(66px,7vw,92px);height:clamp(66px,7vw,92px);border-radius:50%;background:rgba(255,255,255,.94);color:#1c3e30;font-size:27px;text-shadow:none;box-shadow:0 8px 32px rgba(0,0,0,.25);transition:transform .18s;}
.cielo-film-play:hover .cielo-film-play-symbol,.cielo-film-play:focus-visible .cielo-film-play-symbol {transform:scale(1.07);}
.cielo-film-play:focus-visible {outline:2px solid #fff;outline-offset:7px;}
.cielo-film-youtube {position:absolute;z-index:2;bottom:13px;right:16px;color:#fff;font-size:11px;text-decoration:underline;text-shadow:0 1px 8px rgba(0,0,0,.6);}
.cielo-film-frame.is-playing::after,.cielo-film-frame.is-playing .cielo-film-poster,.cielo-film-frame.is-playing .cielo-film-play {display:none;}
.cielo-film-frame iframe {position:absolute;inset:0;border:0;width:100%;height:100%;z-index:2;}
html[dir="rtl"] .cielo-film-copy {direction:rtl;text-align:right;}
@media (max-width:850px){.cielo-film-layout{grid-template-columns:1fr;gap:26px}.cielo-film-copy{max-width:700px}.cielo-film-section{padding:64px 0}.cielo-film-frame{border-radius:14px;}}
@media (max-width:480px){.cielo-film-frame{aspect-ratio:16/9}.cielo-film-youtube{font-size:10px;bottom:10px;right:12px}.cielo-film-play{font-size:10px}.cielo-home-video-hero .cielo-hero-video iframe{width:max(100%,177.77778vh);height:max(100%,56.25vw);}}
@media (prefers-reduced-motion: reduce){.cielo-film-play-symbol{transition:none}}

/* V65: The original home-hero image remains fully visible until YouTube reports PLAYING.
   The frame is never offered for clicks and has no visible autoplay controls. */
.cielo-home-video-hero > img {opacity:1 !important;visibility:visible !important;}
.cielo-home-video-hero .cielo-hero-video iframe {opacity:0;visibility:visible;transition:opacity .45s ease;}
.cielo-home-video-hero .cielo-hero-video.is-playing iframe {opacity:1;visibility:visible;}
/* Crop the YouTube title/avatar strip on the two foreground films. YouTube iframe branding
   cannot be disabled by an official player parameter; this confines it outside the frame.
   Keep the original poster and click-to-play button before playback. */


/* V66: YouTube API replaces the mount div with its iframe. Never visibility:hidden. */
.cielo-home-video-hero .cielo-hero-video .cielo-hero-video-mount {position:absolute;inset:0;pointer-events:none;}
.cielo-home-video-hero .cielo-hero-video iframe {display:block!important;visibility:visible!important;opacity:0;pointer-events:none!important;}
.cielo-home-video-hero .cielo-hero-video.is-playing iframe {opacity:1;}

/* V67: forced full-hero video cover. The image is an uninterrupted 100%-size fallback;
   the transparent player is present behind the fade until playback starts. */
.cielo-home-video-hero{position:relative;overflow:hidden;isolation:isolate;}
.cielo-home-video-hero > img{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;object-fit:cover!important;opacity:1!important;visibility:visible!important;z-index:0!important;}
.cielo-home-video-hero > .cielo-hero-video{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;overflow:hidden!important;z-index:1!important;pointer-events:none!important;}
.cielo-home-video-hero .cielo-hero-video iframe{position:absolute!important;left:50%!important;top:50%!important;right:auto!important;bottom:auto!important;max-width:none!important;max-height:none!important;transform:translate(-50%,-50%)!important;visibility:visible!important;display:block!important;pointer-events:none!important;opacity:0;transition:opacity .35s ease;}
.cielo-home-video-hero .cielo-hero-video.is-playing iframe{opacity:1;}
.cielo-home-video-hero > .hero-shade{z-index:2!important;}
.cielo-home-video-hero > .hero-copy,.cielo-home-video-hero > .hero-location{z-index:3!important;}

/* V70: preserve the complete 16:9 film, including the original captions.
   No zoom/crop at any viewport and no faux YouTube-player masking. */
.cielo-film-frame,.cielo-film-frame.is-playing {aspect-ratio:16/9!important;}
.cielo-film-frame .cielo-film-player-mount,
.cielo-film-frame .cielo-film-player-mount iframe,
.cielo-film-frame > iframe {position:absolute!important;inset:0!important;display:block!important;width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;transform:none!important;aspect-ratio:16/9;border:0!important;}
.cielo-film-frame .cielo-film-player-mount {z-index:1;}
.cielo-film-frame .cielo-film-poster {z-index:2;}
.cielo-film-frame .cielo-film-play {z-index:4;}
.cielo-film-frame .cielo-film-youtube {z-index:4;}
.cielo-film-frame::after {z-index:3;}
.cielo-film-frame.is-playing .cielo-film-player-mount,
.cielo-film-frame.is-player-visible .cielo-film-player-mount {z-index:5;}
.cielo-film-frame.is-playing .cielo-film-poster,
.cielo-film-frame.is-playing .cielo-film-play,
.cielo-film-frame.is-playing::after,
.cielo-film-frame.is-player-visible .cielo-film-poster,
.cielo-film-frame.is-player-visible .cielo-film-play,
.cielo-film-frame.is-player-visible::after {display:none;}
.cielo-film-frame.is-loading .cielo-film-play-symbol {opacity:.83;}
.cielo-film-play {border:0!important;background:none!important;text-decoration:none!important;}
.cielo-film-play-symbol {
  display:grid;place-items:center;width:clamp(58px,6vw,78px);height:clamp(58px,6vw,78px);
  background:#faf9f4;color:#153b30;box-shadow:0 9px 32px rgba(0,0,0,.25);
  border:1px solid rgba(255,255,255,.65);border-radius:50%;transition:transform .18s ease;
}
.cielo-film-play-symbol svg {width:29px;height:29px;display:block;transform:translateX(2px);}
.cielo-film-play:hover .cielo-film-play-symbol,.cielo-film-play:focus-visible .cielo-film-play-symbol {transform:scale(1.045);}
@media(max-width:850px){
  .cielo-film-frame {width:100%;aspect-ratio:16/9!important;border-radius:12px;}
  .cielo-film-play-symbol {width:62px;height:62px;}
  .cielo-film-play-symbol svg {width:25px;height:25px;}
}
/* Poster must remain above the preloaded iframe until actual playback begins. */
.cielo-film-frame > iframe {z-index:1!important;}
.cielo-film-frame.is-playing > iframe,
.cielo-film-frame.is-player-visible > iframe {z-index:5!important;}

/* V73: preserve V72 placement inside the existing gallery and About founder area. */
.visual-slider .visual-slide-video {aspect-ratio:16/9;flex-basis:min(80vw,880px);background:#10291f;isolation:isolate;align-self:flex-start;}
.visual-slider .visual-slide-video::after {display:none!important;content:none!important;}
.visual-slider .visual-slide-video>.cielo-film-frame {position:absolute;inset:0;width:100%;height:100%;aspect-ratio:16/9;border-radius:inherit;box-shadow:none;}
.visual-slider .visual-slide-video .cielo-film-poster {object-fit:contain;}
.about-founder-copy .about-founder-film {width:100%;max-width:100%;min-width:0;margin:26px 0;}
.about-founder-film .cielo-film-frame {width:100%;max-width:100%;aspect-ratio:16/9;border-radius:14px;box-shadow:0 14px 36px rgba(20,42,30,.12);}
.about-founder-film .cielo-film-poster {object-fit:contain;}
/* Native 16:9 YouTube player is not zoomed/cropped: keep all original content/subtitles. */
.cielo-film-frame .cielo-film-player-mount {position:absolute;inset:0;z-index:3;width:100%;height:100%;}
.cielo-film-frame .cielo-film-player-mount iframe,.cielo-film-frame>iframe {display:block!important;position:absolute;inset:0;width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;border:0;transform:none!important;}
/* Preloaded iframe must stay behind the poster until the user actually starts it. */
.cielo-film-frame:not(.is-playing):not(.is-player-visible) .cielo-film-player-mount {z-index:0;pointer-events:none;}
.cielo-film-frame.is-loading .cielo-film-play {opacity:.78;}
.cielo-film-frame.is-playing .cielo-film-player-mount,.cielo-film-frame.is-player-visible .cielo-film-player-mount {z-index:5;pointer-events:auto;}
.cielo-film-frame.is-player-visible .cielo-film-poster,.cielo-film-frame.is-player-visible .cielo-film-play,.cielo-film-frame.is-player-visible::after {display:none;}
@media(max-width:850px){.visual-slider .visual-slide-video{flex-basis:min(92vw,880px);}}
@media(max-width:480px){.visual-slider .visual-slide-video{flex-basis:min(92vw,880px);border-radius:12px;}}

/* V74: Gallery film must match sibling cards' 16:10 canvas and flex width.
   Letterbox the 16:9 film inside it to preserve the full picture and captions. */
.visual-slider .visual-slide.visual-slide-video{
  flex:0 0 min(68vw,880px)!important;
  aspect-ratio:16/10!important;
  align-self:stretch!important;
  background:#0b1714;
}
.visual-slider .visual-slide-video>.cielo-film-frame,
.visual-slider .visual-slide-video>.cielo-film-frame.is-playing{
  position:absolute!important;inset:0!important;width:100%!important;height:100%!important;
  aspect-ratio:auto!important;box-shadow:none!important;
}
.visual-slider .visual-slide-video .cielo-film-poster{
  object-fit:contain!important;transform:none!important;
}
.visual-slider .visual-slide-video .cielo-film-player-mount,
.visual-slider .visual-slide-video .cielo-film-player-mount iframe{
  position:absolute!important;left:0!important;right:0!important;top:50%!important;bottom:auto!important;
  width:100%!important;height:auto!important;aspect-ratio:16/9!important;
  transform:translateY(-50%)!important;max-width:none!important;max-height:none!important;
}
/* Keep YouTube's hover-only UI out of view; users use the branded CIELO play button. */
.cielo-film-frame.is-playing .cielo-film-player-mount iframe{pointer-events:none!important;}
@media(max-width:850px){.visual-slider .visual-slide.visual-slide-video{flex-basis:88vw!important;}}
@media(max-width:480px){.visual-slider .visual-slide.visual-slide-video{flex-basis:88vw!important;}}

.cielo-film-frame .cielo-film-toggle{display:none;position:absolute;bottom:13px;right:13px;z-index:10;
 border:1px solid rgba(255,255,255,.6);border-radius:50%;background:rgba(14,35,28,.66);color:white;
 width:36px;height:36px;padding:0;cursor:pointer;font:700 18px/1 sans-serif;align-items:center;justify-content:center;}
.cielo-film-frame.is-playing .cielo-film-toggle{display:flex;}
.cielo-film-frame .cielo-film-toggle:focus-visible{outline:2px solid #fff;outline-offset:3px;}

/* V75: show YouTube foreground films only after initial provider overlays fade;
   the full 16:9 picture is retained without cropping subtitles. */
.cielo-film-frame .cielo-film-player-mount iframe{pointer-events:none!important;}
.cielo-film-frame.is-loading .cielo-film-player-mount{z-index:0!important;pointer-events:none!important;}
.cielo-film-frame.is-loading .cielo-film-poster,
.cielo-film-frame.is-loading .cielo-film-play{display:block;}
.cielo-film-frame.is-loading .cielo-film-play{display:flex;}
.cielo-film-frame.is-loading .cielo-film-play{pointer-events:none;}
/* Video moved from Shon's text column into the existing management section. */
.about-management-film{margin-top:38px;margin-bottom:24px;max-width:1100px;}
.about-management-film .cielo-film-frame{width:100%;max-width:100%;aspect-ratio:16/9!important;}
@media(max-width:760px){
  /* Slightly lift the existing home hero contrast overlay for a clearer video. */
  .home .hero-shade{
    background:
      linear-gradient(0deg,rgba(6,27,22,.84) 0%,rgba(6,27,22,.67) 34%,rgba(6,27,22,.25) 66%,rgba(6,27,22,.09) 100%),
      linear-gradient(90deg,rgba(6,27,22,.53) 0%,rgba(6,27,22,.24) 58%,rgba(6,27,22,.08) 100%)!important;
  }
  .about-management-film{margin-top:28px;margin-bottom:22px;}
}

/* V76: Reveal the foreground film as soon as the provider reports PLAYING.
   A stationary top matte conceals YouTube's provider title strip without
   zooming the 16:9 player or interfering with lower-third burned-in captions.
   This is a visual mask; YouTube controls/branding cannot be removed by API. */
.cielo-film-frame.is-playing::before{
  content:"";
  display:block;
  position:absolute;
  top:0;left:0;right:0;height:clamp(40px,5.2vw,62px);
  z-index:9;
  background:linear-gradient(to bottom,#0b1714 0%,#0b1714 76%,rgba(11,23,20,0) 100%);
  pointer-events:none;
}
@media(max-width:600px){
  .cielo-film-frame.is-playing::before{height:clamp(36px,10vw,48px);}
}

/* V79: The YouTube brand title is part of the cross-origin iframe. The only
   dependable CSS-only concealment is an opaque title-safe overlay. This affects
   only the foreground film, and preserves the lower in-video captions. */
.cielo-film-frame.is-playing::before{
 content:"";display:block;position:absolute;top:0;left:0;right:0;
 height:clamp(78px,8.5vw,105px);z-index:9;pointer-events:none;
 background:#0b1714;
}
@media(max-width:600px){
 .cielo-film-frame.is-playing::before{height:clamp(57px,13vw,80px);}
}

/* V81: Remove the inherited opaque YouTube-title masks (V76/V79).
   They concealed the actual top of the movie, creating the large black strip.
   Use the original still behind the 16:9 player to fill harmless letterbox space
   inside the 16:10 gallery card; do not crop or zoom the actual video. */
.cielo-film-frame.is-playing::before,
.cielo-film-frame.is-player-visible::before { content:none!important; display:none!important; }
.visual-slider .visual-slide.visual-slide-video,
.visual-slider .visual-slide.visual-slide-video > .cielo-film-frame {
  background-color:#10291f;
  background-image:url('../images/cielo-film-poster.webp');
  background-position:center center;
  background-repeat:no-repeat;
  background-size:cover;
}

/* V82: Fix the duplicate/offset film image without masking any video pixels.
   Match the gallery card height by making the 16:9 video card ~11.11% wider
   than 16:10 image cards. The embedded video remains a true uncropped 16:9.
   Do not display the old film poster as an underlay during playback. */
@media (min-width:851px){
  .visual-slider .visual-slide.visual-slide-video{
    flex:0 0 min(75.55556vw,977.7778px)!important;
    aspect-ratio:16/9!important;
    align-self:stretch!important;
  }
}
@media (max-width:850px){
  .visual-slider .visual-slide.visual-slide-video{
    flex:0 0 88vw!important;
    aspect-ratio:16/9!important;
    align-self:flex-start!important;
  }
}
.visual-slider .visual-slide.visual-slide-video,
.visual-slider .visual-slide.visual-slide-video > .cielo-film-frame{
  background-color:#10291f!important;
  background-image:none!important;
  background-size:auto!important;
}
.visual-slider .visual-slide.visual-slide-video > .cielo-film-frame{
  position:absolute!important;inset:0!important;width:100%!important;height:100%!important;
  aspect-ratio:16/9!important;
}
.visual-slider .visual-slide-video .cielo-film-player-mount,
.visual-slider .visual-slide-video .cielo-film-player-mount iframe{
  position:absolute!important;inset:0!important;left:0!important;top:0!important;
  right:0!important;bottom:0!important;
  width:100%!important;height:100%!important;aspect-ratio:16/9!important;
  transform:none!important;
}
