/**
 * Phase 3 — Home page only (.rr-home scope).
 * Reuses Phase 1 tokens/components; no theme color changes.
 */

.rr-home {
  --rr-home-section-pad: clamp(2.75rem, 5.5vw, var(--rr-space-section));
}

/* ── 1. Hero carousel ── */
.rr-home .rr-home-hero {
  position: relative;
}

.rr-home .rr-home-hero .hero-content.container {
  max-width: var(--rr-shell-max);
  padding-left: var(--rr-shell-pad-x);
  padding-right: var(--rr-shell-pad-x);
}

.rr-home .rr-home-hero .hero-content h1 {
  max-width: 16ch;
  margin-inline: auto;
}

.rr-home .rr-home-hero .hero-lead {
  max-width: 36rem;
}

.rr-home .rr-home-hero .hero-cta-row {
  margin-top: 1.35rem;
}

.rr-home .rr-home-hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1rem;
}

.rr-home .rr-home-hero-actions a {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.88);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(11, 18, 32, 0.35);
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.rr-home .rr-home-hero-actions a:hover {
  color: #fff;
  border-color: rgba(236, 105, 1, 0.55);
  background: rgba(236, 105, 1, 0.15);
}

.rr-home .rr-home-hero-actions a.rr-home-hero-actions-primary {
  background: rgba(236, 105, 1, 0.22);
  border-color: rgba(236, 105, 1, 0.45);
  color: #fff;
}

.rr-home .rr-home-hero-scroll {
  position: absolute;
  left: 50%;
  bottom: 1.25rem;
  transform: translateX(-50%);
  z-index: 4;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.rr-home .rr-home-hero-scroll i {
  font-size: 1.1rem;
  animation: rrHomeScrollBounce 2s ease-in-out infinite;
}

@keyframes rrHomeScrollBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}

/* Rider quick bar (below hero) */
.rr-home-rider-bar {
  background: linear-gradient(90deg, var(--rr-ink), var(--rr-slate));
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding: 0.85rem 0;
}

.rr-home-rider-bar-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.65rem 1rem;
}

.rr-home-rider-bar-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  margin-right: 0.25rem;
}

.rr-home-rider-bar .btn {
  font-size: 0.82rem;
  padding: 0.5rem 1.1rem;
}

/* ── Section shell ── */
.rr-home-section {
  padding-top: var(--rr-home-section-pad);
  padding-bottom: var(--rr-home-section-pad);
}

.rr-home-section-head {
  text-align: center;
  max-width: 40rem;
  margin: 0 auto clamp(1.75rem, 4vw, 2.75rem);
}

.rr-home-section-head .rr-kicker {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--rr-orange);
  margin-bottom: 0.5rem;
}

.rr-home-section-head h2 {
  margin-bottom: 0.35rem;
}

.rr-home-section-head p {
  color: var(--rr-muted);
  margin: 0.5rem auto 0;
  font-size: 0.98rem;
  line-height: 1.55;
  max-width: 34rem;
}

.rr-home-section-actions {
  text-align: center;
  margin-top: clamp(1.5rem, 3vw, 2.25rem);
}

/* ── 2. Events ── */
.rr-home-events {
  background: var(--rr-light);
}

.rr-home-events .row {
  align-items: stretch;
}

.rr-home-events .rr-listing-card {
  height: 100%;
}

.rr-home-events .rr-listing-body .btn {
  margin-top: auto;
}

/* ── 3. Challengers ── */
.rr-home-challengers {
  background: #fff;
  border-top: 1px solid rgba(11, 18, 32, 0.05);
  border-bottom: 1px solid rgba(11, 18, 32, 0.05);
}

.rr-home-challengers .row {
  align-items: stretch;
}

/* ── 4. About / journey teaser ── */
.rr-home-about {
  background: var(--rr-surface);
}

.rr-home-about .rr-about-points {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
}

.rr-home-about .rr-about-points li {
  position: relative;
  padding-left: 1.35rem;
  margin-bottom: 0.55rem;
  color: var(--rr-text);
  font-size: 0.92rem;
  line-height: 1.45;
}

.rr-home-about .rr-about-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--rr-orange);
  box-shadow: 0 0 0 3px rgba(236, 105, 1, 0.15);
}

.rr-home-about-lead {
  color: var(--rr-text);
  line-height: 1.65;
  font-size: 0.98rem;
}

/* ── Gallery (home) ── */
.rr-home-gallery {
  background: var(--rr-light);
}

.rr-home-gallery .gallery-item {
  display: block;
  border-radius: var(--rr-radius);
  overflow: hidden;
  box-shadow: var(--rr-shadow-sm);
  position: relative;
}

.rr-home-gallery .gallery-item img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
  transition: transform 0.45s ease;
}

.rr-home-gallery .gallery-item:hover img {
  transform: scale(1.04);
}

.rr-home-gallery .gallery-item .overlay {
  position: absolute;
  inset: auto 0 0 0;
  padding: 0.75rem 1rem;
  background: linear-gradient(to top, rgba(11, 18, 32, 0.85), transparent);
  opacity: 1;
  pointer-events: none;
}

.rr-home-gallery .gallery-item .overlay h5 {
  color: #fff;
  font-size: 0.92rem;
  margin: 0;
  font-family: var(--rr-display);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

/* ── 5. Video + modal ── */
.rr-home-videos {
  background: #fff;
}

.rr-home .video-card-home {
  background: #fff;
  border-radius: var(--rr-radius);
  overflow: hidden;
  border: 1px solid rgba(11, 18, 32, 0.06);
  box-shadow: var(--rr-shadow-sm);
  transition: transform 0.28s ease, box-shadow 0.28s ease;
  cursor: pointer;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.rr-home .video-card-home:hover {
  transform: translateY(-6px);
  box-shadow: var(--rr-shadow);
}

.rr-home .video-thumbnail-home {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--rr-ink);
  overflow: hidden;
  display: block;
}

.rr-home .video-thumbnail-home img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.rr-home .video-card-home:hover .video-thumbnail-home img {
  transform: scale(1.05);
}

.rr-home .play-button-home {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 50%;
  background: rgba(236, 105, 1, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 28px rgba(236, 105, 1, 0.35);
  transition: transform 0.22s ease, background 0.22s ease;
}

.rr-home .video-card-home:hover .play-button-home {
  transform: translate(-50%, -50%) scale(1.06);
  background: var(--rr-orange-deep);
}

.rr-home .play-button-home i {
  color: #fff;
  font-size: 1.35rem;
  margin-left: 0.15rem;
}

.rr-home .video-content-home {
  padding: 1rem 1.1rem 1.15rem;
  flex: 1;
}

.rr-home .video-title-home {
  font-family: var(--rr-display);
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--rr-ink);
  margin: 0;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rr-home .video-modal-home {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(11, 18, 32, 0.92);
  backdrop-filter: blur(6px);
  padding: var(--rr-shell-pad-x);
}

.rr-home .video-modal-home[hidden] {
  display: none !important;
}

.rr-home .video-modal-home.active {
  display: flex !important;
  align-items: center;
  justify-content: center;
}

.rr-home .video-modal-content-home {
  position: relative;
  width: min(72rem, 100%);
}

.rr-home .video-modal-close-home {
  position: absolute;
  top: -2.5rem;
  right: 0;
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  border: 0;
  background: transparent;
  padding: 0.25rem;
}

.rr-home .video-modal-close-home:hover {
  color: var(--rr-orange);
}

.rr-home .video-embed-home {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--rr-radius);
  overflow: hidden;
  box-shadow: var(--rr-shadow);
  background: #000;
}

.rr-home .video-embed-home iframe,
.rr-home .video-embed-home video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ── 6. Contact ── */
.rr-home-contact {
  background: var(--rr-light);
}

.rr-home-contact .contact-info-box {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.rr-home-contact .contact-info-box li {
  background: #fff;
  border-radius: var(--rr-radius);
  padding: 1rem 1.15rem;
  border: 1px solid rgba(11, 18, 32, 0.06);
  box-shadow: var(--rr-shadow-sm);
}

.rr-home-contact .contact-info-box .icon {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
  color: var(--rr-orange);
}

.rr-home-contact .contact-info-box h6 {
  margin: 0;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--rr-ink);
}

.rr-home-contact .contact-info-box p,
.rr-home-contact .contact-info-box a {
  margin: 0;
  color: var(--rr-text);
  text-decoration: none;
  font-size: 0.92rem;
  line-height: 1.45;
}

.rr-home-contact .contact-info-box a:hover {
  color: var(--rr-orange);
}

.rr-home-contact .rr-touch-card {
  height: 100%;
}

/* ── 7. Pre-footer CTA ── */
.rr-home-cta-band {
  background: linear-gradient(135deg, var(--rr-ink) 0%, var(--rr-slate) 65%, #243552 100%);
  color: #fff;
  padding: clamp(2.5rem, 5vw, 3.5rem) 0;
  position: relative;
  overflow: hidden;
}

.rr-home-cta-band::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--rr-orange), transparent);
}

.rr-home-cta-band-inner {
  text-align: center;
  max-width: 36rem;
  margin: 0 auto;
}

.rr-home-cta-band h2,
.rr-home-cta-band .section-title {
  color: #fff;
  font-size: clamp(1.65rem, 3.5vw, 2.15rem);
  margin-bottom: 0.5rem;
}

.rr-home-cta-band p {
  color: rgba(255, 255, 255, 0.72);
  margin-bottom: 1.35rem;
  line-height: 1.55;
}

.rr-home-cta-band .rr-home-cta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem;
}

@media (max-width: 767.98px) {
  .rr-home .rr-home-hero-scroll {
    display: none;
  }

  .rr-home-rider-bar-inner {
    flex-direction: column;
  }

  .rr-home-rider-bar-label {
    width: 100%;
    text-align: center;
    margin-right: 0;
  }

  .rr-home-rider-bar .btn {
    width: 100%;
    max-width: 20rem;
  }

  .rr-home-cta-band .rr-home-cta-row .btn {
    width: 100%;
    max-width: 20rem;
  }

  .rr-home-gallery .gallery-item img {
    height: 200px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rr-home .rr-home-hero-scroll i {
    animation: none;
  }
}
