/* Premium Marquee Component */
:root {
  --mq-gap: 32px;
  --mq-card-bg: #ffffff;
  --mq-text-color: #1a1a1a;
  --mq-text-muted: #666666;
  --mq-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
  --mq-shadow-hover: 0 12px 32px rgba(0, 0, 0, 0.1);
  --mq-duration: 30s;
}

.cs_marquee_section {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 80px 120px;
  background: transparent;
}

/* Reduce gap when two marquees are stacked */
.cs_marquee_section + .cs_marquee_section {
  padding-top: 0;
}

/* Gradient Fade Edges - Disabled */
/*.cs_marquee_section::before,
.cs_marquee_section::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 100px;
  z-index: 2;
  pointer-events: none;
}

.cs_marquee_section::before {
  left: 0;
  background: linear-gradient(to right, var(--body-bg, #fff) 0%, transparent 100%);
}

.cs_marquee_section::after {
  right: 0;
  background: linear-gradient(to left, var(--body-bg, #fff) 0%, transparent 100%);
}*/

.cs_marquee_wrapper {
  display: flex;
  flex-wrap: nowrap; /* Ensure no wrapping */
  gap: var(--mq-gap);
  width: max-content; /* Allow content to dictate width */
  will-change: transform;
  cursor: grab;
}

/* Brand marquee track */
.cs_brand_marquee_track {
  cursor: grab;
}

/* Packages marquee wrapper */
.packages-marquee-wrapper {
  cursor: grab;
}

/* Marquee Animation - Normal Direction (Left to Right) */
@keyframes marquee {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Marquee Animation - Reverse Direction (Right to Left) */
@keyframes marquee-reverse {
  0% {
    transform: translateX(-50%);
  }
  100% {
    transform: translateX(0);
  }
}

/* Apply animation to marquee sections */
.cs_marquee_section:not(.cs_marquee_reverse) .cs_marquee_wrapper {
  animation: marquee var(--mq-duration) linear infinite;
}

/* Slow speed for Marquee Row 2 */
.cs_marquee_section.cs_marquee_slow .cs_marquee_wrapper {
  animation-duration: 80s !important;
}

/* Fast speed for Marquee - changed to slower */
.cs_marquee_section.cs_marquee_fast .cs_marquee_wrapper {
  animation-duration: 60s !important;
}

/* Reverse direction marquee */
.cs_marquee_section.cs_marquee_reverse .cs_marquee_wrapper {
  animation: marquee-reverse var(--mq-duration) linear infinite;
}

/* Pause on hover */
.cs_marquee_section:hover .cs_marquee_wrapper {
  animation-play-state: paused;
}

.cs_marquee_wrapper:active {
  cursor: grabbing;
}

/* Card Design */
.cs_marquee_card {
  /* Calculation handled by JS/CSS vars per breakpoint */
  flex: 0 0 var(--card-width);
  background: var(--mq-card-bg);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--mq-shadow);
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.4s ease;
  user-select: none;
  position: relative;
  /* Fix for Safari border-radius overflow */
  transform: translateZ(0);
}

/* Reduce video size in value cards */
.cs_marquee_card.cs_value_card_style_1 video {
  height: 100px !important;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 8px;
}

.cs_marquee_card.cs_value_card_style_1 .cs_value_card_divider {
  margin: 12px 0 !important;
}

.cs_marquee_card.cs_value_card_style_1 .cs_value_btn {
  padding: 10px 16px !important;
  font-size: 12px !important;
}

.cs_marquee_card:hover {
  transform: translateY(-8px);
  box-shadow: var(--mq-shadow-hover);
  z-index: 1;
}

.cs_marquee_card.active-scale {
  transform: scale(1.05);
  z-index: 1;
}

.cs_mq_thumb {
  width: 100%;
  position: relative;
  overflow: hidden;
}

.cs_mq_thumb img {
  width: 100%;
  height: auto;
  object-fit: contain;
  transition: transform 0.6s ease;
}

.cs_marquee_card:hover .cs_mq_thumb img {
  transform: scale(1.05);
}

.cs_mq_content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cs_mq_title {
  font-size: 20px;
  font-weight: 700;
  color: var(--mq-text-color);
  margin: 0;
  line-height: 1.3;
}

.cs_mq_desc {
  font-size: 16px;
  color: var(--mq-text-muted);
  margin: 0;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.cs_mq_cta {
  font-size: 14px;
  font-weight: 600;
  color: var(--primary-color, #ff4a17);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cs_mq_cta {
  /* display: none !important; */
}

/* Show all links in marquee content as golden buttons */
.cs_marquee_section .cs_mq_content a,
.cs_marquee_section.cs_marquee_section .cs_mq_content a {
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: linear-gradient(135deg, #E2B56A 0%, #D4A855 50%, #FBFBFC 100%);
  background-size: 200% 200%;
  color: #141F4C !important;
  font-weight: 600;
  font-size: 13px;
  text-decoration: none;
  border-radius: 6px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(226, 181, 106, 0.4);
  border: none;
  margin-top: 12px;
}

.cs_marquee_section .cs_mq_content a:hover {
  background-position: 100% 100%;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(226, 181, 106, 0.5);
  color: #141F4C !important;
}

/* Responsiveness */
.cs_marquee_section .cs_mq_content a.cs_mq_btn {
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: linear-gradient(135deg, #E2B56A 0%, #D4A855 50%, #FBFBFC 100%);
  background-size: 200% 200%;
  color: #141F4C !important;
  font-weight: 600;
  font-size: 13px;
  text-decoration: none;
  border-radius: 6px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(226, 181, 106, 0.4);
  border: none;
}

.cs_marquee_section .cs_mq_content a.cs_btn_gold:hover,
.cs_marquee_section .cs_mq_content a.cs_mq_btn:hover {
  background-position: 100% 100%;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(226, 181, 106, 0.5);
  color: #141F4C !important;
}

.cs_marquee_section .cs_mq_content a.cs_btn_gold svg,
.cs_marquee_section .cs_mq_content a.cs_mq_btn svg {
  transition: transform 0.3s ease;
}

.cs_marquee_section .cs_mq_content a.cs_btn_gold:hover svg,
.cs_marquee_section .cs_mq_content a.cs_mq_btn:hover svg {
  transform: translateX(4px);
}

/* Responsiveness */
/* Desktop: 5 cards - smaller to show more */
@media (min-width: 1024px) {
  :root { --card-width: calc((100vw - (var(--mq-gap) * 7)) / 5); }
  .cs_marquee_section::before, .cs_marquee_section::after { width: 180px; }
  .cs_mq_content { padding: 14px; }
  .cs_mq_title { font-size: 15px; }
  .cs_mq_desc { font-size: 12px; -webkit-line-clamp: 2; }
}

/* Tablet: 4 cards */
@media (min-width: 768px) and (max-width: 1023px) {
  :root { --card-width: calc((100vw - (var(--mq-gap) * 5)) / 4); }
  .cs_mq_content { padding: 12px; }
  .cs_mq_title { font-size: 14px; }
  .cs_mq_desc { font-size: 11px; -webkit-line-clamp: 2; }
}

/* Mobile: 1.5 cards (Partial Peek) - show more */
@media (max-width: 767px) {
  :root { --card-width: calc((100vw - (var(--mq-gap) * 2.5)) / 1.5); }
  .cs_marquee_section::before, .cs_marquee_section::after { width: 40px; }
  .cs_mq_content { padding: 12px; }
  .cs_mq_title { font-size: 14px; }
  .cs_mq_desc { font-size: 12px; -webkit-line-clamp: 2; }
}