/**
 * Layout fixes for home carousels / speaker tabs.
 * Site.css assumes content-box and Cycle2; a few rules need tightening
 * so pagers aren't clipped and folder-tabs sit on the teal panel.
 */

/* Do not clip the absolute speaker pagers that sit under the cycle. */
#index-speakers .content-margin {
  overflow: visible;
}

/* Folder tabs should sit flush on #tab-pages (no white hairline/gap). */
#index-speakers #tab-header {
  height: auto;
  margin: 0;
  padding: 0;
}

#index-speakers #tab-header ul {
  height: auto;
  margin: 0;
  vertical-align: bottom;
}

#index-speakers #tab-header ul li {
  margin: 1px 1px 0;
}

#index-speakers #tab-pages {
  position: relative;
  /* cycle height + room for the absolute pager under the cycle */
  height: 552px;
}

/* Keep dots inside the teal panel, clear of the next section. */
#speakers-pager1,
#speakers-pager2 {
  top: auto !important;
  bottom: 12px;
  z-index: 5;
  display: flex !important;
  flex-wrap: nowrap !important;
  justify-content: center;
  align-items: center;
  width: auto !important;
  max-width: 100%;
  white-space: nowrap;
  left: 50% !important;
  right: auto;
  transform: translateX(-50%);
  margin-left: 0 !important;
}

#speakers-pager1 span,
#speakers-pager2 span {
  float: none !important;
  flex: 0 0 auto;
}

/* ≤900px: arrows replace dots; let 2-up speaker cards grow with content */
@media only screen and (max-width: 900px) {
  #speakers-pager1,
  #speakers-pager2 {
    display: none !important;
  }

  #index-speakers #tab-pages {
    height: auto !important;
    min-height: 0;
    overflow: visible;
  }
}

/* Intro: keep pager dots fully inside the hero, above slides */
#intro-pager {
  bottom: 28px;
  z-index: 999;
}

#intro-pager.cycle-pager span {
  font-size: 48px;
  height: 40px;
  line-height: 40px;
  margin: 0 2px;
  float: none;
  display: inline-block;
}

#intro-cycle {
 /* Legacy hero: ~568px tall at desktop width; scale proportionally */
 height: auto;
 min-height: 0;
 aspect-ratio: 1920 / 568;
}

/* Before CycleRoot hydrates, only show the first slide (avoid stacked headlines). */
#intro-cycle .intro-slide {
 opacity: 0;
}
#intro-cycle .intro-slide:first-child {
 opacity: 1;
}

/* Hold image-heavy pages until critical assets decode (see CriticalPaintGate). */
.conference-paint-gate {
  opacity: 0;
}
.conference-paint-gate-ready {
  opacity: 1;
}

/* Partners: uniform logo slots for 640×320 master assets (no per-image styles). */
body:has(#partners) footer {
  padding-top: 0;
}

/* Center grids; incomplete last rows center too (replaces float:left). */
#partners #platinum .content,
#partners #gold .content,
#partners #silver .content {
  margin-left: auto;
  margin-right: auto;
}

#partners #platinum ul,
#partners #gold ul,
#partners #silver ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  float: none;
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

#partners #platinum ul li,
#partners #gold ul li,
#partners #silver ul li {
  float: none;
}

#partners #platinum ul li a,
#partners #gold ul li a,
#partners #silver ul li a {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  box-sizing: border-box;
}

#partners #platinum ul li a img {
  width: 320px;
  height: 160px;
  object-fit: contain;
  display: block;
  margin: 0;
  padding: 0;
  vertical-align: middle;
}

#partners #gold ul li a img,
#partners #silver ul li a img {
  width: 220px;
  height: 110px;
  object-fit: contain;
  display: block;
  margin: 0;
  padding: 0;
  vertical-align: middle;
}

#partners #broadcast .center a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

#partners #broadcast .broadcast-partner-frame {
  width: 334px;
  height: 252px;
  margin: 0 auto;
  position: relative;
  background-image: url("/Content/partner_broadcast_frame.jpg");
  background-repeat: no-repeat;
  background-position: center center;
  background-size: contain;
  overflow: hidden;
}

#partners #broadcast .broadcast-partner-frame img {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: auto;
  height: auto;
  max-width: 80%;
  max-height: 80%;
  object-fit: contain;
  margin: 0;
  padding: 0;
}

/* Home partner carousels: 640×320 masters, centered in frames (drops legacy per-img nudges). */
#index-partners .index-partner-cycle img {
  width: auto !important;
  height: auto !important;
  max-width: 80% !important;
  max-height: 80% !important;
  object-fit: contain;
  padding: 0 !important;
}
