/* style/index.css */

/* Base styles for the page content */
.page-index {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Default text color for dark body background */
  background-color: transparent; /* Body background is handled by shared.css var(--dark-bg-1) */
}

/* Sections */
.page-index__video-section,
.page-index__hero-section,
.page-index__faq-section,
.page-index__brand-section,
.page-index__blog-section {
  padding: 60px 20px;
  text-align: center;
}

.page-index__section-title {
  font-size: 36px;
  font-weight: bold;
  margin-bottom: 40px;
  color: #ffffff;
}

/* Specific section background/text colors based on body background and content */
.page-index__dark-bg {
  background-color: var(--primary-color, #26A9E0);
  color: #ffffff;
}

.page-index__dark-bg .page-index__section-title {
  color: #ffffff;
}

.page-index__light-bg {
  background-color: #ffffff;
  color: #333333;
}

.page-index__light-bg .page-index__section-title {
  color: var(--primary-color, #26A9E0);
}

/* Video Section */
.page-index__video-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  padding-top: var(--header-offset, 120px); /* Ensure space for fixed header */
  background-color: transparent;
}

.page-index__video-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.page-index__video-link {
  display: block;
  text-decoration: none;
  position: relative;
  width: 100%;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__video-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.page-index__video-wrapper {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.page-index__video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 8px;
  object-fit: cover;
  pointer-events: none; /* Prevent video controls from blocking click event */
}

.page-index__video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 8px;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 1;
}

.page-index__video-link:hover .page-index__video-overlay {
  opacity: 1;
}

.page-index__video-click-hint {
  color: #ffffff;
  font-size: 18px;
  font-weight: bold;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  padding: 10px 20px;
  background: rgba(38, 169, 224, 0.8); /* Using primary color */
  border-radius: 5px;
  white-space: nowrap;
}

.page-index__video-cta {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 30px;
}

.page-index__play-now-button {
  display: inline-block;
  padding: 15px 40px;
  background: var(--primary-color, #26A9E0);
  color: #ffffff;
  text-decoration: none;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border: none;
  cursor: pointer;
}

.page-index__play-now-button:hover {
  background: #1e87c2; /* Darker shade of primary color */
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.page-index__play-now-button:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Hero Section (H1 Title + CTA) */
.page-index__hero-section {
  padding: 80px 20px;
  background-color: var(--primary-color, #26A9E0);
  color: #ffffff;
  text-align: center;
}

.page-index__hero-container {
  max-width: 900px;
  margin: 0 auto;
}

.page-index__main-title {
  font-size: 48px;
  line-height: 1.2;
  margin-bottom: 20px;
  color: #ffffff;
}

.page-index__hero-description {
  font-size: 18px;
  margin-bottom: 40px;
  color: #f0f0f0;
}

.page-index__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.page-index__cta-button {
  display: inline-block;
  padding: 15px 35px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.page-index__btn-primary {
  background: #ffffff;
  color: var(--primary-color, #26A9E0);
  border: 2px solid #ffffff;
}

.page-index__btn-primary:hover {
  background: #f0f0f0;
  color: var(--primary-color, #26A9E0);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.page-index__btn-secondary {
  background: transparent;
  color: #ffffff;
  border: 2px solid #ffffff;
}

.page-index__btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

/* FAQ Section */
.page-index__faq-section {
  padding: 80px 20px;
  background-color: #f8f8f8;
  color: #333333;
}

.page-index__faq-section .page-index__section-title {
  color: var(--primary-color, #26A9E0);
}

.page-index__faq-container {
  max-width: 900px;
  margin: 0 auto;
  text-align: left;
}

.page-index__faq-list {
  margin-top: 30px;
}

.page-index__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.page-index__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-index__faq-item.active .page-index__faq-question {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}

.page-index__faq-question:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
}

.page-index__faq-question:active {
  background: #eeeeee;
}

.page-index__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  color: #333333;
  pointer-events: none; /* Prevent h3 from blocking click event */
}

.page-index__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: #666;
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Prevent icon from blocking click event */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}

.page-index__faq-item.active .page-index__faq-toggle {
  color: var(--primary-color, #26A9E0);
  transform: rotate(45deg); /* Change to X or rotate for active */
}

.page-index__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.3s ease;
  padding: 0 25px;
  opacity: 0;
  background: #f9f9f9;
  color: #555555;
  font-size: 16px;
}

.page-index__faq-item.active .page-index__faq-answer {
  max-height: 2000px !important; /* Sufficiently large to contain any content */
  padding: 20px 25px !important;
  opacity: 1;
  border-radius: 0 0 8px 8px;
  border: 1px solid #e0e0e0;
  border-top: none;
}

/* Brand Section */
.page-index__brand-section {
  padding: 80px 20px;
  background-color: #ffffff;
  color: #333333;
}

.page-index__brand-section .page-index__section-title {
  color: var(--primary-color, #26A9E0);
}

.page-index__brand-container {
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}

.page-index__brand-intro-text {
  font-size: 18px;
  margin-bottom: 50px;
  color: #555555;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-index__brand-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-index__brand-item {
  background: #f9f9f9;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__brand-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.page-index__brand-item-title {
  font-size: 24px;
  color: var(--primary-color, #26A9E0);
  margin-bottom: 15px;
  font-weight: bold;
}

.page-index__brand-item p {
  font-size: 16px;
  color: #555555;
}

/* Blog Section */
.page-index__blog-section {
  padding: 80px 20px;
  background-color: var(--primary-color, #26A9E0);
  color: #ffffff;
}

.page-index__blog-container {
  max-width: 1100px;
  margin: 0 auto;
}

.page-index__blog-section .page-index__section-title {
  color: #ffffff;
}

.page-index__blog-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-index__blog-item {
  background: #ffffff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__blog-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.page-index__blog-link {
  text-decoration: none;
  display: block;
  color: inherit;
}

.page-index__blog-image-wrapper {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  overflow: hidden;
}

.page-index__blog-item-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.page-index__blog-item:hover .page-index__blog-item-image {
  transform: scale(1.05);
}

.page-index__blog-content {
  padding: 20px;
  text-align: left;
}

.page-index__blog-item-title {
  font-size: 20px;
  font-weight: bold;
  color: #333333;
  margin-bottom: 10px;
  line-height: 1.4;
}

.page-index__blog-item-excerpt {
  font-size: 15px;
  color: #666666;
  margin-bottom: 15px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.page-index__blog-item-meta {
  font-size: 13px;
  color: #999999;
  display: block;
}

.page-index__view-all-button-wrapper {
  margin-top: 50px;
  text-align: center;
}

/* General button styling for blog section */
.page-index__blog-section .page-index__cta-button {
  background: #ffffff;
  color: var(--primary-color, #26A9E0);
  border: 2px solid #ffffff;
}

.page-index__blog-section .page-index__cta-button:hover {
  background: #f0f0f0;
  color: var(--primary-color, #26A9E0);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-index__main-title {
    font-size: 42px;
  }
  .page-index__section-title {
    font-size: 32px;
  }
}

@media (max-width: 768px) {
  .page-index__video-section,
  .page-index__hero-section,
  .page-index__faq-section,
  .page-index__brand-section,
  .page-index__blog-section {
    padding: 40px 15px !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }

  .page-index__video-section {
    padding-top: var(--header-offset, 120px) !important; /* Mobile header offset */
  }

  /* Video Section Mobile */
  .page-index__video-container,
  .page-index__video-link,
  .page-index__video-wrapper,
  .page-index__video {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-index__video-wrapper {
    padding-bottom: 56.25% !important; /* Maintain aspect ratio */
    height: 0 !important;
  }

  .page-index__video {
    object-fit: contain !important; /* Ensure video fits within bounds */
    height: 100% !important;
  }

  .page-index__video-cta {
    margin-top: 20px;
    padding: 0 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-index__play-now-button {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 12px 25px !important;
    font-size: 16px !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-index__video-click-hint {
    font-size: 16px !important;
    padding: 8px 16px !important;
  }

  /* Hero Section Mobile */
  .page-index__main-title {
    font-size: 32px;
  }

  .page-index__hero-description {
    font-size: 16px;
  }

  .page-index__cta-buttons {
    flex-direction: column;
    gap: 15px;
    padding: 0 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-index__cta-button {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 12px 25px !important;
    font-size: 16px !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  /* FAQ Section Mobile */
  .page-index__section-title {
    font-size: 28px;
  }

  .page-index__faq-question {
    padding: 15px 20px;
  }

  .page-index__faq-question h3 {
    font-size: 16px;
  }

  .page-index__faq-toggle {
    font-size: 24px;
    width: 28px;
    height: 28px;
  }

  .page-index__faq-answer {
    padding: 0 20px;
    font-size: 15px;
  }

  .page-index__faq-item.active .page-index__faq-answer {
    padding: 15px 20px !important;
  }

  /* Brand Section Mobile */
  .page-index__brand-intro-text {
    font-size: 16px;
  }

  .page-index__brand-item {
    padding: 25px;
  }

  .page-index__brand-item-title {
    font-size: 20px;
  }

  .page-index__brand-item p {
    font-size: 15px;
  }

  /* Blog Section Mobile */
  .page-index__blog-list {
    grid-template-columns: 1fr;
  }

  .page-index__blog-item-image {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-index__blog-image-wrapper {
    height: auto; /* Allow height to adjust based on aspect ratio */
  }

  .page-index__blog-item-title {
    font-size: 18px;
  }

  .page-index__blog-item-excerpt {
    font-size: 14px;
  }

  .page-index__blog-section .page-index__cta-button {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 12px 25px !important;
    font-size: 16px !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  /* Ensure all images are responsive */
  .page-index img {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    box-sizing: border-box !important;
  }

  .page-index__blog-item-image {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    box-sizing: border-box !important;
  }

  /* Ensure all content containers do not cause overflow */
  .page-index__hero-container,
  .page-index__faq-container,
  .page-index__brand-container,
  .page-index__blog-container {
    padding-left: 0;
    padding-right: 0;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }
}

/* Color Contrast Fixes */
.page-index__content-area,
.page-index__text-block {
  color: #ffffff; /* Assuming dark body background */
  background: transparent;
}

.page-index p,
.page-index li {
  color: inherit;
}

.page-index__card {
  background: #ffffff; /* White background for card */
  color: #333333; /* Dark text for white background */
  border: 1px solid #e0e0e0;
}

.page-index__dark-section {
  background: var(--primary-color, #26A9E0);
  color: #ffffff;
}

.page-index__btn-primary {
  background: #ffffff;
  color: var(--primary-color, #26A9E0);
  border: 2px solid #ffffff;
}

.page-index__btn-secondary {
  background: transparent;
  color: #ffffff;
  border: 2px solid #ffffff;
}

/* Login button color */
.page-index__login-button {
  background-color: #EA7C07;
  color: #FFFFFF;
}

.page-index__login-button:hover {
  background-color: #cc6a00;
}

/* General link color */
.page-index a {
  color: var(--primary-color, #26A9E0);
  text-decoration: none;
}

.page-index a:hover {
  text-decoration: underline;
}

.page-index__dark-bg a {
  color: #ffffff;
}

.page-index__dark-bg a:hover {
  color: #f0f0f0;
}