/* Base theme is loaded before this file by index-app.html so each refresh can version it. */

/* Desktop home final fit 20260906 */
@media(min-width:901px){
  html body.home-signed-in{height:100dvh!important;min-height:0!important;overflow:hidden!important;grid-template-rows:64px 34px minmax(0,1fr)!important}
  html body.home-signed-in .home-header{grid-row:1!important}
  html body.home-signed-in .welcome-ticker{grid-row:2!important}
  html body.home-signed-in .home-hero{grid-row:3!important;min-height:0!important;overflow:hidden!important;padding:12px 0 8px!important}
  html body.home-signed-in #ranking{grid-row:3!important;height:100%!important;min-height:0!important;overflow:hidden!important;align-self:stretch!important;padding:12px 0 8px!important}
  html body.home-signed-in #ranking>.wrap{height:100%!important;min-height:0!important;display:flex!important;flex-direction:column!important}
  html body.home-signed-in #ranking .table-card{flex:0 0 auto!important;min-height:0!important}
  html body.home-signed-in #ranking .table-wrap{height:auto!important;overflow:hidden!important}
  html body.home-signed-in .home-features,html body.home-signed-in #register,html body.home-signed-in footer{display:none!important}
  html body.home-signed-in .home-hero .home-board-actions{width:100%!important;max-width:760px!important;height:154px!important;min-height:154px!important;max-height:154px!important;margin:0 auto!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-template-rows:72px 72px!important;grid-auto-rows:72px!important;row-gap:10px!important;column-gap:10px!important;align-content:start!important;align-items:stretch!important;justify-content:stretch!important;direction:rtl!important}
  html body.home-signed-in .home-hero .hero-play-btn{grid-column:1!important;grid-row:1!important}
  html body.home-signed-in .home-hero .home-invite-wrap{grid-column:2!important;grid-row:1!important}
  html body.home-signed-in .home-hero .hero-computer-btn{grid-column:1!important;grid-row:2!important}
  html body.home-signed-in .home-hero .hero-tournaments-btn{grid-column:2!important;grid-row:2!important}
  html body.home-signed-in .home-hero .home-board-actions>.btn,html body.home-signed-in .home-hero .home-invite-wrap,html body.home-signed-in .home-hero .home-invite-wrap>.btn,html body.home-signed-in .home-hero #homeInviteToggle{width:100%!important;min-width:0!important;height:72px!important;min-height:72px!important;max-height:72px!important;margin:0!important}
}
@media(min-width:901px) and (max-height:760px){
  html body.home-signed-in .home-hero{padding:6px 0 4px!important}
  html body.home-signed-in #ranking{padding:6px 0 4px!important}
  html body.home-signed-in .home-hero h1{margin:5px 0 3px!important;font-size:clamp(32px,3.8vw,44px)!important}
  html body.home-signed-in .home-hero p{margin-bottom:7px!important;font-size:16px!important}
  html body.home-signed-in .hero-live-stats{margin-bottom:7px!important;gap:7px!important}
  html body.home-signed-in .hero-stat{min-height:60px!important;padding:6px 8px!important}
  html body.home-signed-in .home-hero .home-board-actions{height:126px!important;min-height:126px!important;max-height:126px!important;grid-template-rows:58px 58px!important;grid-auto-rows:58px!important;row-gap:10px!important}
  html body.home-signed-in .home-hero .home-board-actions>.btn,html body.home-signed-in .home-hero .home-invite-wrap,html body.home-signed-in .home-hero .home-invite-wrap>.btn,html body.home-signed-in .home-hero #homeInviteToggle{height:58px!important;min-height:58px!important;max-height:58px!important}
}

/* Unified hero stat frames 20260908 */
html body .home-hero .hero-stat{
  border:1px solid rgba(216,182,101,.42)!important;
  border-radius:17px!important;
  background:linear-gradient(145deg,rgba(216,182,101,.11),rgba(7,52,54,.92))!important;
}

/* Mobile live stats vertical spacing 20260907 */
@media(max-width:700px){
  html body .home-hero .hero-stat{
    height:auto!important;
    min-height:0!important;
    padding:3px 5px!important;
  }
}

/* Hero kicker emphasis 20260907 */
.hero-kicker{
  font-size:16px!important;
}
@media(max-width:700px){
  .hero-kicker{
    font-size:14px!important;
  }
}

/* Reliable orange-cyan hero title pulse 20260908 */
.home-hero h1,
.home-hero h1 span{
  color:#ffad4d!important;
  -webkit-text-fill-color:#ffad4d!important;
}
.home-hero h1{
  animation:heroTitleOrangeCyanPulse 3s ease-in-out infinite!important;
  will-change:filter;
}
@keyframes heroTitleOrangeCyanPulse{
  0%,100%{
    filter:hue-rotate(0deg);
    -webkit-filter:hue-rotate(0deg);
    text-shadow:0 0 5px rgba(255,173,77,.18);
  }
  50%{
    filter:hue-rotate(151deg);
    -webkit-filter:hue-rotate(151deg);
    text-shadow:0 0 7px rgba(114,227,241,.24);
  }
}

/* Trial badge beside platform kicker 20260908 */
.hero-kicker .trial-badge{
  display:inline-block;
  margin-inline-start:6px;
  color:#ff4d4f!important;
  font-size:12px!important;
  font-weight:900!important;
  white-space:nowrap;
}
@media(max-width:700px){
  .hero-kicker .trial-badge{
    font-size:10px!important;
  }
}

/* Header / latest-members ticker junction 20260909 */
.home-header{
  border-bottom:0!important;
  box-shadow:none!important;
}
html body .welcome-ticker{
  border-top:0!important;
  margin-top:0!important;
}

/* Keep both stacked ticker titles matched and tight to their text */
#welcomeTicker .welcome-ticker-label,
#tournamentResultsTicker .welcome-ticker-label{
  flex:0 0 auto!important;
  width:auto!important;
  min-width:0!important;
  max-width:none!important;
  justify-content:center!important;
  padding:0 4px!important;
  box-sizing:border-box!important;
  font-size:12px!important;
}
@media(max-width:800px){
  #welcomeTicker .welcome-ticker-label,
  #tournamentResultsTicker .welcome-ticker-label{
    font-size:10px!important;
  }
}
@media(max-width:430px){
  #welcomeTicker .welcome-ticker-label,
  #tournamentResultsTicker .welcome-ticker-label{
    font-size:9px!important;
  }
}

/* Mobile page flow: natural page scrolling, no horizontal overflow */
@media(max-width:900px){
  html{
    height:auto!important;
    min-height:0!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    overscroll-behavior-y:auto!important;
  }
  html body{
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    margin-bottom:0!important;
    padding-bottom:0!important;
    overflow-x:hidden!important;
    overflow-y:visible!important;
    overscroll-behavior-y:auto!important;
  }
}

/* Mobile ranking: fixed frame, ten players via internal scroll */
@media(max-width:800px){
  #ranking{
    flex:0 0 auto!important;
    overflow:visible!important;
  }
  #ranking .table-card{
    position:relative!important;
    height:210px!important;
    min-height:210px!important;
    max-height:210px!important;
    overflow:hidden!important;
  }
  #ranking .table-wrap{
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    -webkit-overflow-scrolling:touch;
    overscroll-behavior:contain!important;
  }
  #ranking table{
    height:auto!important;
    min-height:0!important;
  }
  #ranking thead th{
    position:sticky!important;
    top:0!important;
    z-index:5!important;
    background:#0b4143!important;
  }
}

/* Final mobile recovery: beats an older cached loader that disabled native pull-to-refresh. */
@media(max-width:900px){
  html:has(body.home-signed-in):root{overscroll-behavior-y:auto!important}
  html body.home-signed-in.home-signed-in{overscroll-behavior-y:auto!important}
}
@media(max-width:600px){
  html body footer{margin-top:0!important}
}

/* Signed-in mobile: outer ranking fills the viewport; the table itself stays fixed and scrolls internally. */
@media(max-width:900px){
  html body.home-signed-in.home-signed-in{
    height:auto!important;
    min-height:100dvh!important;
    max-height:none!important;
    margin-bottom:0!important;
    padding-bottom:0!important;
    overflow-x:hidden!important;
    overflow-y:visible!important;
    overscroll-behavior-y:auto!important;
  }
  html body.home-signed-in #ranking{
    flex:1 0 auto!important;
    display:flex!important;
    flex-direction:column!important;
    overflow:visible!important;
  }
  html body.home-signed-in #ranking>.wrap{
    flex:1 0 auto!important;
    min-height:0!important;
    display:flex!important;
    flex-direction:column!important;
  }
}
@media(max-width:800px){
  html body.home-signed-in #ranking .table-card{
    position:relative!important;
    flex:0 0 210px!important;
    height:210px!important;
    min-height:210px!important;
    max-height:210px!important;
    overflow:hidden!important;
  }
  html body.home-signed-in #ranking .table-wrap{
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    -webkit-overflow-scrolling:touch;
    overscroll-behavior:contain!important;
  }
}

/* Compact ranking head only: preserve the approved horizontal layout */
@media(min-width:901px){
  html body.home-signed-in #ranking .head{
    min-height:44px!important;
    flex:0 0 44px!important;
    padding:4px 10px!important;
  }
}
