/* Match the reference homepage's fade and upward reveal. JS opts titles in. */
.rfl-home .rfl-title-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1);
}
.rfl-home .rfl-title-reveal.rfl-title-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .rfl-home .rfl-title-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
@media print {
  .rfl-home .rfl-title-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Keep podium medals in a stable column beside the rank numbers. */
#home-top10 .home-rank-position{display:inline-grid;grid-template-columns:20px 30px;gap:8px;align-items:center;text-align:center;vertical-align:middle;font-variant-numeric:tabular-nums}
#home-top10 .home-rank-position .rank-badge{margin:0;vertical-align:middle}

/* Keep the homepage rankings inside their cards at every screen width. */
.rfl-home #home-leader-cards{grid-template-columns:repeat(2,minmax(0,1fr))}
.rfl-home #home-leader-cards .card,.rfl-home #home-leader-cards .table-wrap,.rfl-home #home-leader-cards .person>div{min-width:0;max-width:100%}
.rfl-home #home-leader-cards table{table-layout:fixed;white-space:normal;margin-bottom:0}
.rfl-home #home-leader-cards th:first-child{width:82px}
.rfl-home #home-leader-cards th:last-child{width:96px}
.rfl-home #home-leader-cards td,.rfl-home #home-leader-cards th{padding:16px 8px}
.rfl-home #home-leader-cards .person{min-width:0}
.rfl-home #home-leader-cards .person a,.rfl-home #home-leader-cards .person small{overflow-wrap:anywhere}
.rfl-home #home-leader-cards td:last-child,.rfl-home #home-leader-cards th:last-child{text-align:right;overflow-wrap:anywhere}
@media(max-width:900px){.rfl-home #home-leader-cards{grid-template-columns:minmax(0,1fr)}}
@media(max-width:620px){
.rfl-home #home-leader-cards .card{padding:16px}
.rfl-home #home-leader-cards .race-banner{padding:16px 24px}
.rfl-home #home-leader-cards th:first-child{width:56px}
.rfl-home #home-leader-cards th:last-child{width:76px}
.rfl-home #home-leader-cards td,.rfl-home #home-leader-cards th{padding:12px 4px}
.rfl-home #home-leader-cards td{font-size:13px}
.rfl-home #home-leader-cards th{font-size:10px;letter-spacing:.04em}
.rfl-home #home-leader-cards .person{gap:6px;align-items:flex-start}
.rfl-home #home-leader-cards .person .avatar{width:28px;height:28px;font-size:11px}
.rfl-home #home-leader-cards .person small{font-size:10px;line-height:1.4;margin-top:4px}
.rfl-home #home-leader-cards .person .text-link{font-size:13px;line-height:1.4}
#home-top10 .home-rank-position{grid-template-columns:16px 22px;gap:4px;font-size:16px}
#home-top10 .home-rank-position .rank-badge{font-size:22px}
}

/* Mobile hero: event lockup above the enlarged message. */
@media(max-width:620px){
.rfl-home .hero-rotate .hero-lockup{order:-1;transform:none}
.rfl-home .hero-rotate .hero-inner h1{font-size:clamp(2.53rem,5.29vw,4.14rem)}
.rfl-home .hero-rotate img.hero-bg{object-position:left center}
}

@media(max-width:620px){.rfl-home #rfl-about .about-teaser-copy h2{font-size:2rem}}

/* Give homepage section titles extra breathing room on phones. */
@media(max-width:620px){.rfl-home h2{padding:0 10px}}

/* Cards and inset content already provide their own horizontal spacing. */
@media(max-width:620px){.rfl-home .card h2,.rfl-home .panel h2,.rfl-home .about-teaser-copy h2,.rfl-home .partner-band h2{padding:0}}

@media(max-width:620px){.rfl-home #home-challenges .race-banner .race-dist{font-size:34.5px}}

/* Give campaign statistics full-width rows on phones. */
@media(max-width:620px){
.rfl-home .stats-panel.stats-trio{grid-template-columns:minmax(0,1fr);padding:20px;gap:16px}
.rfl-home .stats-trio .stat{display:grid;grid-template-columns:24px minmax(0,1fr) auto;align-items:center;gap:12px;min-width:0}
.rfl-home .stats-trio .stat+.stat{border-left:0;padding-left:0;border-top:1px solid var(--line);padding-top:16px}
.rfl-home .stats-trio .stat-icon{margin:0}
.rfl-home .stats-trio .stat .small{font-size:16px}
.rfl-home .stats-trio .stat .number{margin:0;font-size:34px;text-align:right}
}

/* Mobile cards move twice as fast as the previous 30-second loop. */
@media(max-width:620px){.rfl-home .luminaria-tease #home-dedications[data-luminaria-ready] .rfl-dedication-loop{animation-duration:15s}}

/* Keep repeated card sets adjacent and cover the viewport across the loop seam. */
.rfl-home .luminaria-tease #home-dedications .ded-track{justify-content:flex-start}
.rfl-home .luminaria-tease #home-dedications .rfl-dedication-loop{flex:0 0 auto;gap:0;will-change:transform}
.rfl-home .luminaria-tease #home-dedications[data-luminaria-ready] .rfl-dedication-loop{animation-name:rfl-luminaria-continuous}
@keyframes rfl-luminaria-continuous{from{transform:translate3d(0,0,0)}to{transform:translate3d(var(--rfl-loop-distance),0,0)}}
@media(prefers-reduced-motion:reduce){.rfl-home .luminaria-tease #home-dedications[data-luminaria-ready] .rfl-dedication-loop{animation:none}}

/* A flat card track has no group wrappers to introduce gaps between repetitions. */
.rfl-home .luminaria-tease #home-dedications .rfl-dedication-loop{display:flex;gap:20px;width:max-content;flex-shrink:0}
.rfl-home .luminaria-tease #home-dedications .rfl-dedication-loop>.tease-card{flex:0 0 220px;margin:0}
@media(prefers-reduced-motion:reduce){.rfl-home #home-dedications .rfl-dedication-loop>.tease-card[aria-hidden="true"]{display:none}}

/* Inset the outer columns of the individual fundraiser table. */
.rfl-home #home-leader-cards .ind-scheme th:first-child,.rfl-home #home-leader-cards .ind-scheme td:first-child{padding-left:14px}
.rfl-home #home-leader-cards .ind-scheme th:last-child,.rfl-home #home-leader-cards .ind-scheme td:last-child{padding-right:14px}
@media(max-width:620px){
.rfl-home #home-leader-cards .ind-scheme th:first-child{width:62px}
.rfl-home #home-leader-cards .ind-scheme th:last-child{width:82px}
.rfl-home #home-leader-cards .ind-scheme th:first-child,.rfl-home #home-leader-cards .ind-scheme td:first-child{padding-left:10px}
.rfl-home #home-leader-cards .ind-scheme th:last-child,.rfl-home #home-leader-cards .ind-scheme td:last-child{padding-right:10px}
}

.rfl-home .help-section .help-head h2{padding-inline:0}

@media(max-width:620px){.rfl-home #home-top10 .home-leaderboard-break{display:none}}

/* Match mobile eyebrow labels to their section heading inset. */
@media(max-width:620px){
.rfl-home .section-head .eyebrow,.rfl-home .tease-head>.eyebrow{padding-inline:10px}
.rfl-home .card .eyebrow,.rfl-home .panel .eyebrow,.rfl-home .about-teaser-copy .eyebrow,.rfl-home .partner-band .eyebrow{padding-inline:0}
}

.rfl-home #home-challenges h3 .merch-badge{display:inline-block;margin-left:10px;margin-top:8px;vertical-align:middle}

.rfl-home section.hero-rotate{padding:84px 0px}
@media(max-width:620px){.rfl-home section.hero-rotate{padding:54px 0px}}

/* Home sponsor tiers match the Partners page outlines and simple labels. */
.rfl-home #home-sponsors .sponsor-tier{border:1px solid #d9cbe7;border-radius:14px;padding:28px 24px;gap:20px;margin-bottom:20px;background:transparent}
.rfl-home #home-sponsors .sponsor-tier>.eyebrow{background:none;border:0;border-radius:0;padding:0;margin:0;color:var(--purple,#5f249f);font-size:14px;line-height:1.4;letter-spacing:.12em;font-weight:700}
@media(max-width:620px){.rfl-home #home-sponsors .sponsor-tier{padding:24px 16px}.rfl-home #home-sponsors .sponsor-row{flex-wrap:wrap;justify-content:center}.rfl-home #home-sponsors .sponsor-row .sponsor-logo{flex:0 1 160px}}
