/*
 * ALFARI Theme 6.38.114
 * Android homepage contrast and Platform trainer header docking.
 * Presentation only: the Platform remains the sole owner of trainer markup,
 * state, actions, labels, destinations and business decisions.
 */

/* The runtime contrast guard measures background-color, not gradient pixels.
 * Give the gradient hero an explicit dark base so it cannot be misclassified
 * as a light surface while the image layer is being evaluated. */
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-hero{
  background-color:#111814!important;
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}

/* Stable author colors also close the short interval before/while the runtime
 * classifier replaces an obsolete alfari-auto-light-surface marker. */
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-hero :is(#alfari-home-title,.alfari-sales-hero__copy>h1){
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
  opacity:1!important;
  filter:none!important;
  text-shadow:none!important;
}
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-hero .alfari-sales-lead{
  color:#e5ebe7!important;
  -webkit-text-fill-color:#e5ebe7!important;
  opacity:1!important;
}
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-hero .alfari-sales-textlink--light{
  color:#d8f247!important;
  -webkit-text-fill-color:#d8f247!important;
  opacity:1!important;
}
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-hero .alfari-sales-trustline{
  color:#d5ddd8!important;
  -webkit-text-fill-color:#d5ddd8!important;
  opacity:1!important;
}

/* The proof card is a light surface nested in the dark hero. Keep every direct
 * Platform/demo text node on the card's own contrast authority. */
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-proof .alfari-home-product-demo{
  background-color:#fff!important;
  color:#1b211e!important;
  -webkit-text-fill-color:#1b211e!important;
  opacity:1!important;
}
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-proof .alfari-home-product-demo :is(h2,h3,p,span,strong,small,summary){
  color:#1b211e!important;
  -webkit-text-fill-color:#1b211e!important;
  opacity:1!important;
  filter:none!important;
  mix-blend-mode:normal!important;
  text-shadow:none!important;
}
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-proof .alfari-home-product-demo .alfari-home-product-demo__example-note{
  color:#3f4b44!important;
  -webkit-text-fill-color:#3f4b44!important;
  opacity:1!important;
}
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-proof .alfari-home-product-demo .alfari-home-product-demo__bar span{
  color:#525e57!important;
  -webkit-text-fill-color:#525e57!important;
}
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-proof .alfari-home-product-demo .alfari-home-product-demo__bar strong{
  color:#385f12!important;
  -webkit-text-fill-color:#385f12!important;
}
body.home:not(.alfari-app-mode) main.alfari-home-638114 .alfari-sales-proof .alfari-home-product-demo .alfari-home-product-demo__why p{
  color:#263029!important;
  -webkit-text-fill-color:#263029!important;
}

@media(max-width:759px){
  body.home:not(.alfari-app-mode) [data-alfari-duplicate-trainer-hidden="true"]{display:none!important}
  body.home:not(.alfari-app-mode) .site-header,
  body.home:not(.alfari-app-mode) .site-header .header-row{
    height:72px!important;
    min-height:72px!important;
    max-height:72px!important;
  }
  body.home:not(.alfari-app-mode) .site-header .header-row{
    display:flex!important;
    align-items:center!important;
    gap:6px!important;
    width:calc(100% - 20px)!important;
    padding:0!important;
  }
  body.home:not(.alfari-app-mode) .site-header .brand{
    order:1!important;
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
    flex:1 1 auto!important;
  }
  body.home:not(.alfari-app-mode) .site-header .brand-link{
    width:min(142px,100%)!important;
    min-width:0!important;
  }
  body.home:not(.alfari-app-mode) .site-header .alfari-logo-horizontal-header{
    width:min(142px,100%)!important;
    max-height:42px!important;
  }
  body.home:not(.alfari-app-mode) .site-header .menu-toggle{
    order:3!important;
    width:48px!important;
    min-width:48px!important;
    height:48px!important;
    min-height:48px!important;
    padding:0!important;
  }
  body.home:not(.alfari-app-mode) .site-header .header-actions{
    order:4!important;
    flex:0 0 48px!important;
  }
  body.home:not(.alfari-app-mode) .site-header .search-toggle{
    width:48px!important;
    min-width:48px!important;
    height:48px!important;
    min-height:48px!important;
    padding:0!important;
  }

  /* The node is supplied by Platform and moved by the theme only on the
   * homepage at mobile widths. No duplicate/fallback trainer is generated. */
  body.home:not(.alfari-app-mode) .site-header .header-row>[data-alfari-speaking-avatar][data-alfari-home-header-docked="true"]{
    order:2!important;
    position:relative!important;
    inset:auto!important;
    z-index:4!important;
    display:block!important;
    visibility:visible!important;
    width:44px!important;
    min-width:44px!important;
    max-width:44px!important;
    height:44px!important;
    min-height:44px!important;
    margin:0!important;
    opacity:1!important;
    pointer-events:auto!important;
    transform:none!important;
  }
  body.home:not(.alfari-app-mode) .site-header .header-row>[data-alfari-speaking-avatar][data-alfari-home-header-docked="true"]>.alfari-avatar-toggle{
    display:flex!important;
    width:44px!important;
    min-width:44px!important;
    max-width:44px!important;
    height:44px!important;
    min-height:44px!important;
    padding:2px!important;
    overflow:hidden!important;
    border:2px solid #8fbd31!important;
    border-radius:14px!important;
    background:#fff!important;
    box-shadow:none!important;
  }
  body.home:not(.alfari-app-mode) .site-header .header-row>[data-alfari-speaking-avatar][data-alfari-home-header-docked="true"]>.alfari-avatar-toggle img{
    width:38px!important;
    min-width:38px!important;
    height:38px!important;
    flex:0 0 38px!important;
    object-fit:cover!important;
  }
  body.home:not(.alfari-app-mode) .site-header .header-row>[data-alfari-speaking-avatar][data-alfari-home-header-docked="true"]>.alfari-avatar-toggle>span{
    position:absolute!important;
    width:1px!important;
    height:1px!important;
    padding:0!important;
    margin:-1px!important;
    overflow:hidden!important;
    clip:rect(0,0,0,0)!important;
    white-space:nowrap!important;
    border:0!important;
  }
  body.home:not(.alfari-app-mode) .site-header .header-row>[data-alfari-speaking-avatar][data-alfari-home-header-docked="true"]>.alfari-avatar-toggle:after{
    left:auto!important;
    right:1px!important;
    bottom:1px!important;
    width:11px!important;
    height:11px!important;
    border-width:2px!important;
  }
  body.home:not(.alfari-app-mode) [data-alfari-speaking-avatar][data-alfari-home-header-docked="true"] .alfari-avatar-panel{
    position:fixed!important;
    top:calc(78px + env(safe-area-inset-top))!important;
    right:8px!important;
    bottom:auto!important;
    left:auto!important;
    width:min(390px,calc(100vw - 16px))!important;
    max-width:calc(100vw - 16px)!important;
    max-height:calc(100dvh - 88px - env(safe-area-inset-top))!important;
    overflow:auto!important;
    z-index:100000!important;
  }
}

@media(max-width:374px){
  body.home:not(.alfari-app-mode) .site-header .brand-link,
  body.home:not(.alfari-app-mode) .site-header .alfari-logo-horizontal-header{width:118px!important}
  body.home:not(.alfari-app-mode) .site-header .menu-toggle,
  body.home:not(.alfari-app-mode) .site-header .search-toggle{width:44px!important;min-width:44px!important;height:44px!important;min-height:44px!important}
  body.home:not(.alfari-app-mode) .site-header .header-actions{flex-basis:44px!important}
}
