
/* v19.1.5 — public portal runtime and width recovery */
:root{
  --portal-repair-gutter:clamp(12px,1.6vw,30px);
}

html,
body,
.tg-public-shell,
.site-main{
  width:100% !important;
  max-width:none !important;
  min-width:0 !important;
  box-sizing:border-box !important;
}

.site-main{
  margin:0 !important;
  padding:0 !important;
}

.portal-shell-bar,
.portal-shell-bar .wrap,
.portal-shell-bar-inner{
  width:100% !important;
  max-width:none !important;
  margin-left:0 !important;
  margin-right:0 !important;
  box-sizing:border-box !important;
}

.portal-shell-bar .wrap,
.portal-shell-bar-inner{
  padding-left:var(--portal-repair-gutter) !important;
  padding-right:var(--portal-repair-gutter) !important;
}

body[class*="route-game-"] .site-main > .wrap,
body[class*="route-tife-"] .site-main > .wrap,
.site-main > .portal-page,
.portal-page,
.unified-library,
.unified-library-full,
.tg17-my-library,
.tg17-game-portal,
.tg17-tife-portal{
  width:100% !important;
  max-width:none !important;
  min-width:0 !important;
  margin-left:0 !important;
  margin-right:0 !important;
  padding-left:var(--portal-repair-gutter) !important;
  padding-right:var(--portal-repair-gutter) !important;
  box-sizing:border-box !important;
}

.unified-library-grid,
.portal-card-grid,
.portal-game-grid,
.library-card-grid{
  width:100% !important;
  max-width:none !important;
  grid-template-columns:repeat(auto-fill,minmax(220px,1fr)) !important;
}

.unified-site-header .site-header-inner{
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding-left:var(--portal-repair-gutter) !important;
  padding-right:var(--portal-repair-gutter) !important;
}

@media(max-width:760px){
  :root{
    --portal-repair-gutter:12px;
  }

  .unified-library-grid,
  .portal-card-grid,
  .portal-game-grid,
  .library-card-grid{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
}

@media(max-width:460px){
  .unified-library-grid,
  .portal-card-grid,
  .portal-game-grid,
  .library-card-grid{
    grid-template-columns:1fr !important;
  }
}


/* v19.2.1 — compact portal title panes */
.portal-hero,
.portal-hero-premium,
.tife-page-head,
.portal-page-head,
.unified-library-hero,
.library-hero,
.tg-game-hero,
.tife-hero-premium,
.creation-wishlist-hero{
  min-height:0 !important;
  padding-top:clamp(.9rem,1.5vw,1.35rem) !important;
  padding-bottom:clamp(.9rem,1.5vw,1.35rem) !important;
}

.portal-hero{
  grid-template-columns:minmax(0,1fr) minmax(150px,240px) !important;
  gap:clamp(1rem,2vw,2rem) !important;
}

.portal-hero-copy{
  padding:0 !important;
}

.portal-hero h1,
.portal-page-head h1,
.tife-page-head h1,
.unified-library-hero h1,
.library-hero h1,
.tg-game-hero h1,
.creation-wishlist-hero h1{
  margin-top:.15rem !important;
  margin-bottom:.35rem !important;
  font-size:clamp(1.65rem,3vw,2.6rem) !important;
  line-height:1.08 !important;
}

.portal-hero p,
.portal-page-head p,
.tife-page-head p,
.unified-library-hero p,
.library-hero p,
.tg-game-hero p,
.creation-wishlist-hero p{
  margin-top:.2rem !important;
  margin-bottom:.4rem !important;
  line-height:1.42 !important;
}

.portal-hero-mark,
.portal-hero-logo{
  width:min(220px,100%) !important;
  height:clamp(100px,11vw,155px) !important;
  min-height:0 !important;
  justify-self:end !important;
}

.portal-hero-logo img{
  padding:.2rem !important;
}

.hero-actions{
  margin-top:.75rem !important;
}

/* Compact dedicated portal title cards that use generic hero classes. */
.site-main > .wrap > .hero:first-child,
.site-main > .portal-page > .hero:first-child{
  min-height:0 !important;
  padding:1rem clamp(1rem,2vw,1.5rem) !important;
}



@media(max-width:760px){
  .portal-hero{
    grid-template-columns:1fr !important;
  }

  .portal-hero-mark,
  .portal-hero-logo{
    display:none !important;
  }
}


/* v19.2.2 — breadcrumb recovery */
.tg-breadcrumb{
  display:block !important;
  width:100% !important;
  max-width:none !important;
  margin:0 0 .85rem !important;
  padding:0 !important;
  background:none !important;
  border:0 !important;
  box-shadow:none !important;
}

.tg-breadcrumb ol{
  display:flex !important;
  align-items:center !important;
  flex-wrap:wrap !important;
  gap:.35rem !important;
  margin:0 !important;
  padding:0 !important;
  list-style:none !important;
}

.tg-breadcrumb li{
  display:inline-flex !important;
  align-items:center !important;
  gap:.35rem !important;
  margin:0 !important;
  padding:0 !important;
  font-size:.76rem !important;
  line-height:1.3 !important;
}

.tg-breadcrumb li:not(:last-child)::after{
  content:"›";
  color:#718399;
}

.tg-breadcrumb a{
  color:#8fd0ff !important;
  text-decoration:none !important;
  background:none !important;
  border:0 !important;
  border-radius:0 !important;
  padding:0 !important;
  box-shadow:none !important;
}

.tg-breadcrumb a:hover,
.tg-breadcrumb a:focus-visible{
  text-decoration:underline !important;
}

.tg-breadcrumb [aria-current="page"]{
  color:#aeb9c7 !important;
}



/* v19.2.4 — compact header version popup control */
.unified-site-header .site-version{
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  width:auto !important;
  min-width:0 !important;
  height:34px !important;
  min-height:34px !important;
  margin:0 !important;
  padding:0 .68rem !important;
  color:#8fd0ff !important;
  font-size:.76rem !important;
  font-weight:800 !important;
  line-height:1 !important;
  white-space:nowrap !important;
  background:rgba(66,165,255,.08) !important;
  border:1px solid rgba(66,165,255,.30) !important;
  border-radius:999px !important;
  box-shadow:none !important;
  cursor:pointer !important;
}

.unified-site-header .site-version:hover,
.unified-site-header .site-version:focus-visible{
  color:#e7f6ff !important;
  background:rgba(66,165,255,.16) !important;
  border-color:rgba(66,165,255,.58) !important;
  transform:none !important;
}

.whats-new-dialog[hidden]{
  display:none !important;
}

.whats-new-dialog{
  position:fixed !important;
  inset:0 !important;
  z-index:8000 !important;
  display:grid !important;
  place-items:center !important;
  padding:1rem !important;
}

.whats-new-backdrop{
  position:absolute !important;
  inset:0 !important;
  background:rgba(0,0,0,.72) !important;
  backdrop-filter:blur(5px) !important;
}

.whats-new-panel{
  position:relative !important;
  z-index:1 !important;
  width:min(680px,calc(100vw - 2rem)) !important;
  max-height:min(86vh,760px) !important;
  overflow:auto !important;
  padding:1.35rem !important;
  border:1px solid rgba(66,165,255,.40) !important;
  border-radius:16px !important;
  background:linear-gradient(180deg,#111b27,#071521) !important;
  box-shadow:0 28px 90px rgba(0,0,0,.52) !important;
}

.whats-new-close{
  position:absolute !important;
  top:.65rem !important;
  right:.65rem !important;
  width:38px !important;
  height:38px !important;
  min-height:38px !important;
  padding:0 !important;
  border-radius:50% !important;
}

.whats-new-release-title{
  margin:.75rem 0 .45rem !important;
  font-size:1.25rem !important;
  font-weight:850 !important;
}

.whats-new-meta{
  display:flex !important;
  flex-wrap:wrap !important;
  gap:.75rem !important;
  margin-bottom:.85rem !important;
  color:#aeb9c7 !important;
}

.whats-new-list{
  display:grid !important;
  gap:.5rem !important;
  margin:0 !important;
  padding-left:1.15rem !important;
}



body.has-whats-new-dialog{
  overflow:hidden !important;
}

/* Footer version removed in v19.2.4. */
.site-footer .footer-version,
.site-footer .footer-version-link{
  display:none !important;
}


/* v19.2.5 — release-news content inside version popup */
.whats-new-news-body{
  margin-top:.9rem !important;
  color:#d9e5ef !important;
  font-size:.94rem !important;
  line-height:1.58 !important;
}

.whats-new-news-body h1,
.whats-new-news-body h2,
.whats-new-news-body h3{
  margin:1rem 0 .45rem !important;
  color:#f2f8fc !important;
  line-height:1.2 !important;
}

.whats-new-news-body h1{
  font-size:1.45rem !important;
}

.whats-new-news-body h2{
  font-size:1.25rem !important;
}

.whats-new-news-body h3{
  font-size:1.08rem !important;
}

.whats-new-news-body p{
  margin:.55rem 0 !important;
}

.whats-new-news-body ul,
.whats-new-news-body ol{
  margin:.55rem 0 !important;
  padding-left:1.25rem !important;
}

.whats-new-news-body a{
  color:#8fd0ff !important;
  text-decoration:underline !important;
}

.whats-new-news-body img{
  max-width:100% !important;
  height:auto !important;
  border-radius:8px !important;
}


/* v19.2.6 — synchronized release-news popup */
.whats-new-featured-image{
  display:block !important;
  width:100% !important;
  max-height:260px !important;
  margin:.8rem 0 1rem !important;
  object-fit:cover !important;
  border-radius:10px !important;
}

.whats-new-news-body{
  max-width:none !important;
}

.whats-new-news-body > :first-child{
  margin-top:0 !important;
}

.whats-new-news-body > :last-child{
  margin-bottom:0 !important;
}


/* v19.2.7 — shared release-news renderer */
.release-news-content{
  color:#d9e5ef;
}

.release-news-content h2{
  margin:.1rem 0 .45rem;
  color:#f2f8fc;
  font-size:clamp(1.35rem,3vw,1.8rem);
  line-height:1.18;
}

.release-news-meta{
  display:flex;
  flex-wrap:wrap;
  gap:.75rem;
  margin-bottom:.9rem;
  color:#aeb9c7;
}

.release-news-image{
  display:block;
  width:100%;
  max-height:320px;
  margin:.75rem 0 1rem;
  object-fit:cover;
  border-radius:10px;
}

.release-news-body{
  font-size:.94rem;
  line-height:1.58;
}

.release-news-body h1,
.release-news-body h2,
.release-news-body h3{
  margin:1rem 0 .45rem;
  color:#f2f8fc;
  line-height:1.2;
}

.release-news-body p{
  margin:.55rem 0;
}

.release-news-body ul,
.release-news-body ol{
  margin:.55rem 0;
  padding-left:1.25rem;
}

.release-news-body img{
  max-width:100%;
  height:auto;
  border-radius:8px;
}

.release-news-body a{
  color:#8fd0ff;
  text-decoration:underline;
}

.release-news-page{
  padding-top:1.25rem;
  padding-bottom:3rem;
}

.release-news-full-page{
  max-width:980px;
  margin:0 auto;
  padding:1.25rem;
  border:1px solid rgba(148,163,184,.2);
  border-radius:14px;
  background:rgba(8,20,32,.72);
}


/* v19.2.9 — reliable release-information page */
.release-information-page{
  width:100%;
  max-width:none;
  padding:1.25rem clamp(14px,2vw,32px) 3rem;
  box-sizing:border-box;
}

.release-information{
  width:min(980px,100%);
  margin:0 auto;
  padding:1.25rem;
  border:1px solid rgba(148,163,184,.22);
  border-radius:14px;
  background:rgba(8,20,32,.76);
}

.release-information h1{
  margin:.1rem 0 .45rem;
}

.release-information-meta{
  display:flex;
  flex-wrap:wrap;
  gap:.75rem;
  margin-bottom:1rem;
  color:#aeb9c7;
}

.release-information-image{
  display:block;
  width:100%;
  max-height:360px;
  margin:.75rem 0 1rem;
  object-fit:cover;
  border-radius:10px;
}

.release-information-body{
  line-height:1.58;
}

.release-information-body img{
  max-width:100%;
  height:auto;
}


/* v19.2.14 — header, breadcrumb, submenu ordering */
.portal-chrome{
  position:relative !important;
  z-index:20 !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:0 !important;
  background:var(--tg-surface,#081420) !important;
  border-bottom:1px solid rgba(148,163,184,.18) !important;
  box-sizing:border-box !important;
}

.portal-breadcrumb-row{
  position:relative !important;
  z-index:2 !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:.55rem var(--portal-repair-gutter,clamp(12px,1.6vw,30px)) !important;
  background:rgba(5,15,24,.98) !important;
  border-bottom:1px solid rgba(148,163,184,.14) !important;
  box-sizing:border-box !important;
}

.portal-breadcrumb-row .tg-breadcrumb{
  margin:0 !important;
}

.portal-submenu-row{
  position:relative !important;
  z-index:1 !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:0 !important;
  background:rgba(8,20,32,.98) !important;
  box-sizing:border-box !important;
}

.portal-subnav-shell,
.portal-shell-bar{
  position:relative !important;
  top:auto !important;
  right:auto !important;
  bottom:auto !important;
  left:auto !important;
  z-index:auto !important;
  float:none !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  transform:none !important;
  box-shadow:none !important;
  border-radius:0 !important;
}

.portal-subnav-inner,
.portal-shell-bar-inner,
.portal-shell-bar .wrap{
  display:flex !important;
  align-items:center !important;
  gap:.75rem !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:.55rem var(--portal-repair-gutter,clamp(12px,1.6vw,30px)) !important;
  box-sizing:border-box !important;
}

.portal-subnav-title{
  flex:0 0 auto !important;
  color:#dbe8f2 !important;
  font-size:.72rem !important;
  font-weight:850 !important;
  text-transform:uppercase !important;
  letter-spacing:.05em !important;
}

.portal-subnav{
  display:flex !important;
  align-items:center !important;
  flex-wrap:wrap !important;
  gap:.35rem !important;
  min-width:0 !important;
}

.portal-subnav a,
.portal-shell-bar a{
  position:relative !important;
  top:auto !important;
  left:auto !important;
  display:inline-flex !important;
  align-items:center !important;
  min-height:32px !important;
  padding:.4rem .65rem !important;
  border-radius:7px !important;
  text-decoration:none !important;
  white-space:nowrap !important;
}

.portal-subnav a.active,
.portal-subnav a[aria-current="page"],
.portal-shell-bar a.active{
  background:rgba(66,165,255,.14) !important;
  color:#bfe5ff !important;
}

/* Prevent legacy sticky/floating portal menus. */
.site-main .portal-subnav-shell,
.site-main .portal-shell-bar,
.site-main .portal-submenu-row{
  position:relative !important;
  inset:auto !important;
}

.site-main > .portal-page,
.site-main > .wrap.portal-page,
.site-main > .unified-library{
  margin-top:0 !important;
}

@media(max-width:760px){
  .portal-subnav-inner,
  .portal-shell-bar-inner,
  .portal-shell-bar .wrap{
    align-items:flex-start !important;
    flex-direction:column !important;
    gap:.45rem !important;
  }

  .portal-subnav{
    width:100% !important;
    overflow-x:auto !important;
    flex-wrap:nowrap !important;
    padding-bottom:.15rem !important;
  }
}


/* v19.3.0 stabilization — server-rendered portal chrome */
.portal-chrome{
  position:relative !important;
  z-index:20 !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:0 !important;
  background:#081420 !important;
  border-bottom:1px solid rgba(148,163,184,.18) !important;
}

.portal-breadcrumb-row{
  position:relative !important;
  width:100% !important;
  margin:0 !important;
  padding:.55rem var(--portal-repair-gutter,clamp(12px,1.6vw,30px)) !important;
  background:rgba(5,15,24,.98) !important;
  border-bottom:1px solid rgba(148,163,184,.14) !important;
  box-sizing:border-box !important;
}

.portal-breadcrumb-row .tg-breadcrumb{
  margin:0 !important;
}

.portal-submenu-row,
.portal-subnav-shell{
  position:relative !important;
  inset:auto !important;
  float:none !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  transform:none !important;
  box-shadow:none !important;
}

.portal-subnav-inner{
  display:flex !important;
  align-items:center !important;
  gap:.75rem !important;
  width:100% !important;
  padding:.55rem var(--portal-repair-gutter,clamp(12px,1.6vw,30px)) !important;
  box-sizing:border-box !important;
}

.portal-subnav{
  display:flex !important;
  align-items:center !important;
  flex-wrap:wrap !important;
  gap:.35rem !important;
}

.portal-subnav a{
  display:inline-flex !important;
  align-items:center !important;
  min-height:32px !important;
  padding:.4rem .65rem !important;
  border-radius:7px !important;
  text-decoration:none !important;
}

.portal-subnav a.active,
.portal-subnav a[aria-current="page"]{
  background:rgba(66,165,255,.14) !important;
  color:#bfe5ff !important;
}

.release-information-page{
  width:100% !important;
  max-width:none !important;
  padding:1.25rem clamp(14px,2vw,32px) 3rem !important;
  box-sizing:border-box !important;
}

.release-content{
  width:min(980px,100%) !important;
  margin:0 auto !important;
  padding:1.25rem !important;
  border:1px solid rgba(148,163,184,.22) !important;
  border-radius:14px !important;
  background:rgba(8,20,32,.76) !important;
}

.release-content-meta{
  display:flex !important;
  flex-wrap:wrap !important;
  gap:.75rem !important;
  margin-bottom:1rem !important;
  color:#aeb9c7 !important;
}

.release-content-image{
  display:block !important;
  width:100% !important;
  max-height:360px !important;
  object-fit:cover !important;
  border-radius:10px !important;
}

.release-content-body{
  line-height:1.58 !important;
}

@media(max-width:760px){
  .portal-subnav-inner{
    align-items:flex-start !important;
    flex-direction:column !important;
  }

  .portal-subnav{
    width:100% !important;
    overflow-x:auto !important;
    flex-wrap:nowrap !important;
  }
}


/* v19.3.1 — eliminate duplicate legacy TIFE submenu */
body.route-tife-index .site-main > .portal-shell-bar,
body.route-tife-index .site-main > .tife-portal-nav,
body.route-tife-index .site-main > .tife-subnav,
body.route-tife-index .site-main > .portal-subnav-shell:not(.portal-chrome .portal-subnav-shell){
  display:none !important;
}

body.route-tife-index .portal-chrome{
  display:block !important;
}

body.route-tife-index .portal-chrome .portal-subnav-shell{
  display:block !important;
}

/* Keep exact visual order: header, breadcrumb, one submenu, content. */
body.route-tife-index .portal-breadcrumb-row{
  order:1 !important;
}

body.route-tife-index .portal-submenu-row{
  order:2 !important;
}

body.route-tife-index .portal-chrome{
  display:flex !important;
  flex-direction:column !important;
}


/* v19.4.0 — shared release dialog */
.release-dialog[hidden]{
  display:none !important;
}

.release-dialog{
  position:fixed !important;
  inset:0 !important;
  z-index:10000 !important;
  display:grid !important;
  place-items:center !important;
  padding:1rem !important;
}

.release-dialog-backdrop{
  position:absolute !important;
  inset:0 !important;
  background:rgba(0,0,0,.74) !important;
  backdrop-filter:blur(5px) !important;
}

.release-dialog-panel{
  position:relative !important;
  z-index:1 !important;
  width:min(720px,calc(100vw - 2rem)) !important;
  max-height:min(86vh,780px) !important;
  overflow:auto !important;
  padding:1.35rem !important;
  border:1px solid rgba(66,165,255,.40) !important;
  border-radius:16px !important;
  background:linear-gradient(180deg,#111b27,#071521) !important;
  box-shadow:0 28px 90px rgba(0,0,0,.55) !important;
}

.release-dialog-close{
  position:absolute !important;
  top:.65rem !important;
  right:.65rem !important;
  width:38px !important;
  height:38px !important;
  min-height:38px !important;
  padding:0 !important;
  border-radius:50% !important;
  cursor:pointer !important;
}

body.has-release-dialog{
  overflow:hidden !important;
}


/* v19.4.1 — Game Library belongs to Games, not Game Portal */
body.route-game-game-library .portal-submenu-row,
body.route-game-game-library .portal-subnav-shell,
body.route-game-game-library .portal-shell-bar{
  display:none !important;
}

body.route-game-game-library .portal-chrome{
  border-bottom:0 !important;
}

body.route-game-game-library .portal-breadcrumb-row{
  border-bottom:1px solid rgba(148,163,184,.14) !important;
}


/* v19.4.2 — one breadcrumb system only */
.portal-chrome .portal-breadcrumb-row{
  display:none !important;
}

.portal-chrome{
  border-top:0 !important;
}

.site-breadcrumb-bar{
  display:block !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:0 !important;
}

.site-breadcrumb-bar .tg-breadcrumb{
  margin:0 !important;
}


/* v19.4.3 — restored single header breadcrumb */
.site-breadcrumb-bar{
  display:block !important;
  position:relative !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:0 !important;
  background:rgba(5,15,24,.98) !important;
  border-bottom:1px solid rgba(148,163,184,.14) !important;
}

.site-breadcrumb-inner{
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:.55rem var(--portal-repair-gutter,clamp(12px,1.6vw,30px)) !important;
  box-sizing:border-box !important;
}

.site-breadcrumb-inner .tg-breadcrumb{
  display:block !important;
  margin:0 !important;
}

.site-breadcrumb-inner .tg-breadcrumb ol{
  display:flex !important;
}
