/* =============================================================
   blend-carousel.css — Blend Sports
   Production-ready. Loader removed. H1 promoted. Grid layout.
   ============================================================= */

/* ---------- Global Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: linear-gradient(135deg, #2a2a2a, #1b1b1b);
  font-family: 'Poppins', Arial, sans-serif;
  color: #fff;
  overflow-x: hidden;
}

/* Accessibility: keyboard skip link */
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  transform: translateY(-220%);
  opacity: 0;
  pointer-events: none;
  z-index: 2147483647;
  background: #e61d25;
  color: #fff;
  padding: 10px 14px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  line-height: 1;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.skip-link:focus,
.skip-link:focus-visible,
.skip-link:active {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* =============================================================
   HERO HEADER
   FIX: Selector updated from h2 to h1 (H2 promoted to H1).
   ============================================================= */
header.glow-header {
  text-align: center;
  padding: 10px 20px 0;
  margin-top: 1.5rem;   /* 24px gap below navbar */
}

/* Glow animation on H1 and P */
header.glow-header h1,
header.glow-header p {
  animation: subtleGlow 3.5s ease-in-out infinite;
}

@keyframes subtleGlow {
  0%, 100% { text-shadow: 0 0 0 rgba(255, 255, 255, 0); }
  50%       { text-shadow: 0 0 4px rgba(255, 255, 255, 0.35); }
}

/* FIX: H1 selector (was h2) */
header.glow-header h1 {
  font-size: clamp(1.2rem, 3vw, 1.75rem);
  margin: 0 0 0.75rem;
  line-height: 1.1;
  font-weight: 600;
  color: #fff;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.4);
}

header.glow-header p {
  margin-top: 0;
  margin-bottom: 0.75rem;
  font-size: 1.05rem;
  color: #ccc;
  line-height: 1.6;
}

/* =============================================================
   SWIPE LABEL
   ============================================================= */
.swipe-label {
  text-align: center;
  color: #ccc;
  font-size: 0.9rem;
  margin-bottom: 16px;
  animation: swipeGlow 1.2s ease-in-out infinite;
}

@keyframes swipeGlow {
  0%   { text-shadow: 0 0 0 white; }
  50%  { text-shadow: 0 0 6px white; }
  100% { text-shadow: 0 0 0 white; }
}

/* =============================================================
   CAROUSEL WRAPPER — CSS Grid ensures indicators always sit
   below the card, never overlap it.
   ============================================================= */
.carousel-wrap {
  display: grid;
  grid-template-rows: auto auto;
  gap: 20px;
  align-items: start;
  max-width: 98vw;
  margin: 0 auto;
}

@media (min-width: 2560px) {
  .carousel-wrap {
    max-width: 2400px;
  }
}

/* =============================================================
   CAROUSEL CONTAINER
   ============================================================= */
.carousel {
  position: relative;
  /* No padding-bottom needed — grid handles indicator spacing */
}

/* =============================================================
   CAROUSEL ITEMS
   ============================================================= */
.carousel-item {
  display: none;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
}

.carousel-item.active {
  display: block;
  opacity: 1;
}

/* Fade-in-up on slide activation */
.carousel-item.active .carousel-content {
  animation: fadeUp 0.6s ease-out forwards;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =============================================================
   CAROUSEL CONTENT — Dark card layout
   ============================================================= */
.carousel-content {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  background: rgba(20, 20, 20, 0.85);
  padding: 20px;
  border-radius: 14px;
  gap: 20px;
  justify-content: space-between;
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.6),
    0 0 12px rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(3px);
  z-index: 3;
}

/* =============================================================
   VIDEO COLUMN
   ============================================================= */
.video-column {
  flex: 1 1 65%;
  position: relative;
}

/* Video thumbnail placeholder — 16:9 ratio */
.video-placeholder,
.video-wrapper {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  cursor: pointer;
  background: #000;
  border-radius: 10px;
  overflow: hidden;
}

/* FIX: Space between thumbnail and text content below */
.video-column .video-placeholder {
  margin-bottom: 1.5rem;
}

.video-placeholder img,
.video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
  border: none;
}

/* Subtle lift on hover — non-shaking */
.video-card,
.video-wrapper {
  transition:
    transform 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94),
    box-shadow 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform, box-shadow;
}

.video-card:hover,
.video-wrapper:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 14px rgba(255, 255, 255, 0.2);
}

/* =============================================================
   PLAY BUTTON
   ============================================================= */
.play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 59px;
  height: 59px;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.5);
  pointer-events: none; /* clicks pass through to parent */
}

.play-button::after {
  content: '';
  position: absolute;
  left: 22px;
  top: 16px;
  width: 0;
  height: 0;
  border-left: 20px solid #e61d25;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
}

/* =============================================================
   FEATURED LABEL
   ============================================================= */
.featured-label {
  position: absolute;
  top: -26px;
  left: 0;
  background-color: #e61d25;
  color: #fff;
  padding: 6px 12px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 16px;
  animation: pulse 1.5s infinite;
  z-index: 2;
}

@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(230, 29, 37, 0.7); }
  70%  { box-shadow: 0 0 0 10px rgba(230, 29, 37, 0); }
  100% { box-shadow: 0 0 0 0 rgba(230, 29, 37, 0); }
}

/* =============================================================
   SLIDE TEXT CONTENT
   ============================================================= */
.carousel .text-content h2 {
  font-size: clamp(1.15rem, 2.2vw, 1.3rem);
  margin: 0 0 0.5rem;
  line-height: 1.25;
  color: #fff;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
  font-weight: 600;
}

.text-content h3 {
  font-size: clamp(1.15rem, 2.2vw, 1.3rem);
  margin: 0 0 1rem;
  line-height: 1.25;
  color: #fff;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
}

.text-content p {
  margin-top: 0;
  font-size: clamp(0.9rem, 2vw, 1.05rem);
  color: #ccc;
  line-height: 1.6;
  letter-spacing: 0.3px;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.4);
}

/* Match About-page internal link styling */
.accent-link {
  color: #e61d25;
  font-weight: 600;
  text-decoration: underline;
}

.accent-link:hover,
.accent-link:focus,
.accent-link:focus-visible {
  color: #fff;
}

/* =============================================================
   IMAGES COLUMN
   ============================================================= */
.images-column {
  flex: 1 1 30%;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.image-card {
  background: rgba(20, 20, 20, 0.85);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  transition: box-shadow 0.3s ease;
  position: relative;
}

/* Create aspect ratio container for images (same technique as video) */
.image-card a {
  display: block;
  position: relative;
  width: 100%;
  padding-bottom: 54.17%; /* 325/600 = 0.5417 → 54.17% maintains 600:325 aspect ratio */
  overflow: hidden;
}

.image-card img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
  display: block;
  transition: transform 0.3s ease;
}

.image-card:hover img {
  transform: scale(1.05);
}

.image-card:hover {
  box-shadow: 0 6px 16px rgba(255, 255, 255, 0.25);
}

/* =============================================================
   NAVIGATION BUTTONS
   FIX: Defined on .carousel so they position relative to it.
   Desktop: top 45%. Mobile: repositioned near text content.
   ============================================================= */
.nav-button {
  position: absolute;
  top: 45%;                 /* desktop: slightly above centre */
  transform: translateY(-50%);
  background: #fff;
  color: #e61d25;
  border: none;
  padding: 12px 16px;
  font-size: 28px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 1000;
  opacity: 0.95;
  transition: background 0.2s ease, color 0.2s ease;
  line-height: 1;
}

.nav-button:hover {
  background: #eee;
  color: #c00;
}

.nav-button:focus-visible {
  outline: 3px solid rgba(230, 29, 37, 0.6);
  outline-offset: 3px;
}

.nav-button.prev { left: 10px; }
.nav-button.next { right: 10px; }

/* =============================================================
   SWIPE INDICATORS
   FIX: grid-row:2 keeps dots in their own row, never overlapping.
   ============================================================= */
.swipe-indicators {
  grid-row: 2;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  position: relative;    /* not absolute — grid controls placement */
  z-index: 1;
  margin: 0;
}

.swipe-indicators .dot {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  padding: 0;
  margin: 0;
  font: inherit;
  line-height: 0;
  display: inline-block;
  vertical-align: middle;
  width: 12px;
  height: 12px;
  background-color: #323232;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.swipe-indicators .dot.active {
  background-color: #e61d25;
  transform: scale(1.4);
}

.swipe-indicators .dot:focus-visible {
  outline: 3px solid rgba(230, 29, 37, 0.5);
  outline-offset: 3px;
  border-radius: 4px;
}

/* =============================================================
   CTA BUTTON
   ============================================================= */
.glowing-button.small {
  display: block;
  width: fit-content;
  margin: 20px auto 0;
  padding: 8px 16px;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  background: #e61d25;
  color: #fff;
  border: 2px solid #e61d25;
  border-radius: 5px;
  box-shadow: 0 0 5px #fff, 0 0 10px #e61d25;
  transition: all 0.3s ease;
}

.glowing-button.small:hover {
  background: #fff;
  color: #e61d25;
  box-shadow: 0 0 10px #fff, 0 0 20px #fff;
}

/* Touch reset — instant on mobile */
.glowing-button.small.touched {
  background: #e61d25;
  color: #fff;
  box-shadow: 0 0 5px #fff, 0 0 10px #e61d25;
  transition: none;
}

/* =============================================================
   TABLET + MOBILE BACKGROUND CONTINUITY (max-width: 991px)
   Keep one continuous dark base from hero through welcome section.
   ============================================================= */
@media (max-width: 991px) {
  .hero-carousel-section,
  .hero-carousel-section + .container {
    background: linear-gradient(135deg, #2a2a2a, #1b1b1b) !important;
  }

  .hero-carousel-section {
    border-radius: 0;
    margin: 0;
  }

  .hero-carousel-section + .container {
    margin-top: 0;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .hero-carousel-section + .container .welcome,
  .hero-carousel-section + .container .welcome .row,
  .hero-carousel-section + .container .welcome .welcom_right {
    background: transparent !important;
  }
}

/* =============================================================
   MOBILE STYLES  (max-width: 768px)
   ============================================================= */
@media (max-width: 768px) {

  .hero-carousel-section {
    padding: 10px 0 12px;
  }

  /* Tighten grid gap on small screens */
  .carousel-wrap {
    gap: 14px;
  }

  /* Stack columns vertically */
  .carousel-content {
    background: transparent;
    padding: 0;
    gap: 12px;
    box-shadow: none;
    border-radius: 0;
    flex-direction: column;
  }

  .video-column,
  .images-column {
    flex: 1 1 100%;
    width: 100%;
    padding: 0 12px;
  }

  /* Full-bleed video on mobile */
  .video-placeholder,
  .video-wrapper {
    border-radius: 8px;
    margin: 0;
  }

  /* Dark card for text content under video */
  .video-column .text-content {
    background: rgba(8, 8, 8, 0.92);
    padding: 14px;
    margin: 12px 12px 0;
    border-radius: 10px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25);
    color: #fff;
  }

  /* Smaller play button on phones */
  .play-button {
    width: 48px;
    height: 48px;
  }

  .play-button::after {
    left: 16px;
    top: 12px;
    border-left-width: 14px;
    border-top-width: 10px;
    border-bottom-width: 10px;
  }

  /* Mobile arrow: anchor near text content, away from images */
  .nav-button {
    top: auto;
    bottom: 390px;
    padding: 10px 14px;
    font-size: 24px;
  }

  /* Smaller dots */
  .swipe-indicators .dot {
    width: 8px;
    height: 8px;
  }

  .swipe-indicators .dot.active {
    transform: scale(1.3);
  }

  /* CTA button */
  .glowing-button.small {
    padding: 10px 20px;
    font-size: 14px;
  }

  /* Featured label */
  .featured-label {
    font-size: 12px;
    padding: 4px 10px;
  }

  /* Focus styles for a11y */
  .video-placeholder:focus-visible,
  .nav-button:focus-visible,
  .dot:focus-visible {
    outline: 3px solid rgba(230, 29, 37, 0.4);
    outline-offset: 4px;
    border-radius: 8px;
  }
}

/* =============================================================
   ULTRA-WIDE CAP
   ============================================================= */
@media (min-width: 2560px) {
  .carousel {
    max-width: 2400px;
    margin-left: auto;
    margin-right: auto;
  }
}
