/* Music Coast — Full Build v14 hotfix (20260114v14)
   Goal: MOBILE hero b-roll should look like desktop:
   - Background fills the ENTIRE hero (including behind the title)
   - B-roll is clearly visible (not crushed to black) while still keeping text readable
   - No YouTube hover UI

   This stylesheet must load AFTER /assets/css/styles.css
*/

/* ---------------- About cards (unchanged) ---------------- */
#about .grid.about-split{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(18px, 3vw, 44px);
  align-items: start;
  margin-top: clamp(18px, 3vw, 34px);
}

#about .grid.about-split > article{
  min-width: 0;
  margin: 0;
  position: relative;
}

#about .grid.about-split > article:first-child{
  justify-self: end;
  width: min(560px, 100%);
}

#about .grid.about-split > article:last-child{
  justify-self: start;
  width: min(560px, 100%);
}

@media (max-width: 900px){
  #about .grid.about-split{ grid-template-columns: 1fr; }
  #about .grid.about-split > article:first-child,
  #about .grid.about-split > article:last-child{
    justify-self: stretch;
    width: 100%;
  }
}


/* Space between About cards and Leadership block (prevents overlap/shadow collision) */
#about .grid.about-split{
  margin-bottom: clamp(28px, 5vw, 84px);
}

#about .card.leadership-card{
  margin-top: clamp(28px, 5vw, 84px);
  margin-bottom: clamp(28px, 5vw, 84px);
}

/* Extra buffer so hover lift never collides */
#about .grid:not(.about-split){
  margin-top: 0;
}


/* LinkedIn icon button in leader cards */
.leader-top .leader-linkedin{
  margin-left: auto;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color-strong);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: all var(--duration-fast) var(--ease-out);
}

.leader-top .leader-linkedin:hover{
  background: var(--bg-tertiary);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.leader-top .leader-linkedin svg{
  width: 18px;
  height: 18px;
  display: block;
  fill: currentColor;
}

/* ---------------- HERO: force true full-bleed cover ---------------- */
.hero{
  position: relative !important;
  overflow: hidden !important;
}

.hero .hero-video-bg{
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 100% !important;
  overflow: hidden !important;
  display: block !important;
  opacity: 1 !important;
  z-index: 0 !important;
  background: radial-gradient(80% 90% at 30% 20%, rgba(var(--accent-rgb),0.18) 0%, rgba(0,0,0,0.86) 70%),
              linear-gradient(180deg, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.55) 55%, rgba(0,0,0,0.90) 100%) !important; /* fallback when video is blocked */
}

/* Keep hero content above background */
.hero > *:not(.hero-video-bg){ position: relative; z-index: 2; }

/* Ensure fade layer never clips (some mobile CSS can) */
.hero .hero-video-bg .hero-video-fade{
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  pointer-events: none !important;
}

/* Default (desktop/tablet): centered cover */
.hero .hero-video-bg iframe,
.hero .hero-video-bg video{
  pointer-events: none !important;
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;

  width: 120vw !important;
  height: 67.5vw !important;         /* 120 * 9/16 */
  min-width: 100% !important;
  min-height: 100% !important;

  transform: translate(-50%, -50%) scale(1.14) !important;
  filter: blur(2px) !important;
  opacity: 0.60 !important;          /* a touch brighter than v7 */
}

/* Mobile: anchor and fill 100% of hero height, then scale for edge coverage */
@media (max-width: 900px){
  .hero{ min-height: 100vh !important; }
  .hero .hero-video-bg{ height: 100% !important; }

  /* IMPORTANT: keep the iframe itself in a 16:9 ratio so YouTube doesn't add black bars on tall mobile heroes */
  @supports (aspect-ratio: 16 / 9) {
    .hero .hero-video-bg iframe,
    .hero .hero-video-bg video{
      top: 50% !important;
      left: 50% !important;

      width: auto !important;
      height: 100% !important;
      aspect-ratio: 16 / 9;

      min-width: 100% !important;
      min-height: 100% !important;
      max-width: none !important;
      max-height: none !important;

      transform: translate(-50%, -50%) scale(1.04) !important;
      transform-origin: center !important;

      filter: blur(1.5px) !important;
      opacity: 0.72 !important;
    }
  }

  /* Fallback for very old browsers */
  @supports not (aspect-ratio: 16 / 9) {
    .hero .hero-video-bg iframe,
    .hero .hero-video-bg video{
      top: 50% !important;
      left: 50% !important;

      width: 100vw !important;
      height: 56.25vw !important;          /* 16:9 */
      min-width: 177.78vh !important;      /* 16:9 */
      min-height: 100% !important;

      transform: translate(-50%, -50%) scale(1.04) !important;
      transform-origin: center !important;

      filter: blur(1.5px) !important;
      opacity: 0.72 !important;
    }
  }
}


/* If embedded media is blocked (GDPR/cookies), the iframe src stays empty — hide it so the fallback background shows */
#hero-bg-iframe:not([src]),
#hero-bg-iframe[src=""]{
  display: none !important;
}
/* Wash: keep readability, but DO NOT crush the top to black on mobile */
.hero .hero-video-bg::after{
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(60% 70% at 30% 35%, rgba(0,0,0,0.45) 0%, rgba(0,0,0,0.70) 55%, rgba(0,0,0,0.86) 100%);
}

@media (max-width: 900px){
  .hero .hero-video-bg::after{
    background: linear-gradient(to bottom,
      rgba(0,0,0,0.18) 0%,
      rgba(0,0,0,0.50) 55%,
      rgba(0,0,0,0.74) 100%);
  }
}

/* ---------------- Leadership avatars (unchanged) ---------------- */
.leader-avatar img{
  width: 64px;
  height: 64px;
  border-radius: 9999px;
  object-fit: cover;
  display: block;
}


/* ---------------- Hero (Light Mode) readability ----------------
   When the hero background video is enabled, we deliberately use a dark
   cinematic wash behind the headline. In LIGHT theme, base button/text colors
   are dark — which makes hero copy + CTA buttons hard to read.

   Fix: only in light theme, when .hero-video-on is active, force the left-side
   hero copy and outline buttons to use high-contrast light styling. We scope
   to the first column (div:not(.card)) so the white "Welcome" card remains
   unchanged.
*/

html[data-theme="light"] .hero.hero-video-on .hero-grid > div:not(.card){
  color: rgba(255,255,255,0.92);
}

html[data-theme="light"] .hero.hero-video-on .hero-grid > div:not(.card) .lead{
  color: rgba(255,255,255,0.84);
  text-shadow: 0 2px 14px rgba(0,0,0,0.55);
}

html[data-theme="light"] .hero.hero-video-on .hero-grid > div:not(.card) .kpi-lbl{
  color: rgba(255,255,255,0.70);
}

/* Outline hero CTA buttons (all non-primary) */
html[data-theme="light"] .hero.hero-video-on .hero-grid > div:not(.card) .btn:not(.btn-primary){
  color: rgba(255,255,255,0.92);
  border-color: rgba(255,255,255,0.30);
  background: rgba(0,0,0,0.14);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

html[data-theme="light"] .hero.hero-video-on .hero-grid > div:not(.card) .btn:not(.btn-primary):hover,
html[data-theme="light"] .hero.hero-video-on .hero-grid > div:not(.card) .btn:not(.btn-primary):focus-visible{
  background: rgba(255,255,255,0.10);
  border-color: rgba(255,255,255,0.48);
  color: rgba(255,255,255,0.98);
}


/* --- About + App teaser refinement (2026-03-07) --- */
#about .about-card,
#about .app-teaser{
  padding: clamp(24px, 3vw, 34px);
}

#about .about-lead{
  font-size: clamp(1.04rem, 1vw + 0.92rem, 1.16rem);
  line-height: 1.8;
  color: var(--text-primary);
  max-width: 46ch;
}

#about .about-card p,
#about .app-teaser p{
  max-width: 54ch;
}

#about .about-highlights{
  margin-top: var(--space-lg);
  gap: 10px;
}

#about .app-note{
  margin-top: clamp(20px, 2vw, 28px);
  padding: 16px 18px;
  border: 1px solid var(--border-color-strong);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.01));
}

#about .app-note-text{
  color: var(--text-primary);
  font-weight: 600;
  line-height: 1.5;
}

#about .app-note-stores{
  margin-top: 10px;
  align-items: center;
  gap: 14px;
}

#about .app-note-stores .pill{
  padding-inline: 18px;
  min-height: 42px;
}

#about .app-note-and{
  font-size: 0.84rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

#about .app-features{
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

#about .app-feature-pill{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(0,0,0,0.18);
  color: rgba(255,255,255,0.92);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1;
}

html:not([data-theme="dark"]) #about .app-note{
  background: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(255,255,255,0.86));
}
html:not([data-theme="dark"]) #about .app-feature-pill{
  background: rgba(255,255,255,0.7);
  color: var(--text-primary);
  border-color: rgba(0,0,0,0.08);
}
html[data-theme="dark"] #about .app-teaser .about-lead,
html[data-theme="dark"] #about .app-teaser p,
html[data-theme="dark"] #about .app-note-text,
html[data-theme="dark"] #about .app-note-and{
  color: rgba(255,255,255,0.92);
}

@media (max-width: 720px){
  #about .app-note{
    padding: 14px 14px;
  }
  #about .app-note-stores{
    gap: 10px;
  }
  #about .app-note-stores .pill{
    width: 100%;
    justify-content: center;
  }
  #about .app-note-and{
    width: 100%;
    text-align: center;
  }
  #about .app-features{
    gap: 10px;
  }
}


/* --- About pair refinement: cleaner spacing + stronger separation (2026-03-07b) --- */
#about .grid.about-split > article{
  display: flex;
  flex-direction: column;
  gap: clamp(14px, 1.4vw, 18px);
}

#about .about-card,
#about .app-teaser{
  min-height: 100%;
}

#about .about-card h3,
#about .app-teaser h3{
  margin-bottom: 2px;
}

#about .about-highlights{
  margin-top: auto;
  padding-top: 10px;
}

#about .app-note{
  margin-top: clamp(24px, 2.6vw, 34px);
  padding: 18px 20px;
  border-radius: 22px;
}

#about .app-note-text{
  font-size: 0.98rem;
}

#about .app-note-stores{
  margin-top: 14px;
  justify-content: flex-start;
  row-gap: 12px;
}

#about .app-note-stores .pill{
  padding-inline: 18px;
  min-height: 44px;
}

#about .app-features{
  margin-top: 26px;
  padding-top: 22px;
  gap: 10px 10px;
}

#about .app-feature-pill{
  min-height: 36px;
  padding: 0 13px;
  font-size: 0.88rem;
}

@media (max-width: 900px){
  #about .about-highlights{
    margin-top: 6px;
    padding-top: 0;
  }
}

@media (max-width: 720px){
  #about .app-note{
    margin-top: 20px;
    padding: 15px 16px;
  }

  #about .app-note-text{
    font-size: 0.96rem;
  }

  #about .app-note-stores{
    margin-top: 12px;
    justify-content: center;
  }

  #about .app-features{
    margin-top: 20px;
    padding-top: 18px;
    justify-content: center;
  }
}
