/* style/index.css */

/* General page styling for dark body background */
.page-index {
  color: #ffffff; /* Light text for dark body background */
  font-family: Arial, sans-serif;
  line-height: 1.6;
  background-color: transparent; /* Body background is handled by shared.css */
  padding-bottom: 60px; /* Space before footer */
}

.page-index h1,
.page-index h2,
.page-index h3,
.page-index h4 {
  color: #ffffff; /* All headings also light */
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-index h1 {
  font-size: 3em;
  text-align: center;
}

.page-index h2 {
  font-size: 2.5em;
  text-align: center;
  margin-top: 40px;
  margin-bottom: 30px;
  position: relative;
  padding-bottom: 15px;
}

.page-index h2::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: var(--primary-color, #017439);
  border-radius: 2px;
}

.page-index h3 {
  font-size: 1.8em;
}

.page-index p {
  margin-bottom: 15px;
}

.page-index a {
  color: var(--primary-color, #017439);
  text-decoration: none;
}

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

/* 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); /* Fixed header offset */
  background: linear-gradient(135deg, rgba(1, 116, 57, 0.8), rgba(0, 0, 0, 0.9));
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.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.4);
}

.page-index__video-wrapper {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  height: 0;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
  background-color: #000; /* Fallback for video area */
}

.page-index__video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 12px;
  object-fit: cover;
  pointer-events: none; /* Prevent video controls from interfering with link click */
  background-color: #000; /* Ensure black background if video fails to load */
}

.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.4);
  border-radius: 12px;
  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: 20px;
  font-weight: bold;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.7);
  padding: 12px 25px;
  background: rgba(195, 8, 8, 0.8); /* Using register color for CTA hint */
  border-radius: 8px;
  white-space: nowrap;
  letter-spacing: 1px;
}

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

.page-index__play-now-button {
  display: inline-block;
  padding: 18px 45px;
  background: var(--primary-color, #017439); /* Primary color for Play Now button */
  color: #ffffff;
  text-decoration: none;
  border-radius: 10px;
  font-size: 20px;
  font-weight: bold;
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
  border: none;
  cursor: pointer;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.page-index__play-now-button:hover {
  background: #005f2e; /* Slightly darker green on hover */
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.page-index__play-now-button:active {
  transform: translateY(0);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* H1 Title + Promotion Buttons Section */
.page-index__title-section {
  background: #1a1a1a; /* Dark background for this section */
  padding: 80px 20px;
  text-align: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.page-index__title-container {
  max-width: 1000px;
  margin: 0 auto;
}

.page-index__main-title {
  font-size: 3.5em;
  color: #ffffff;
  margin-bottom: 25px;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

.page-index__title-description {
  font-size: 1.2em;
  color: #f0f0f0;
  max-width: 800px;
  margin: 0 auto 40px auto;
}

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

.page-index__cta-button {
  display: inline-block;
  padding: 16px 35px;
  text-decoration: none;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.page-index__cta-button--register {
  background: #C30808; /* Custom color for Register */
  color: #FFFF00; /* Custom font color for Register */
}

.page-index__cta-button--register:hover {
  background: #a30606; /* Darker red on hover */
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

.page-index__cta-button--login {
  background: #C30808; /* Custom color for Login */
  color: #FFFF00; /* Custom font color for Login */
  border: 2px solid #FFFF00; /* Yellow border for login */
}

.page-index__cta-button--login:hover {
  background: #a30606; /* Darker red on hover */
  border-color: #ffd700; /* Gold border on hover */
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}


/* FAQ Section */
.page-index__faq-section {
  background: #121212; /* Match body background */
  padding: 80px 20px;
}

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

.page-index__faq-title {
  color: #ffffff;
  margin-bottom: 40px;
}

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

.page-index__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05); /* Slightly lighter background for FAQ items */
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.page-index__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  background: rgba(255, 255, 255, 0.08); /* Slightly lighter for question header */
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-index__faq-question:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
}

.page-index__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 1.15em;
  font-weight: 600;
  line-height: 1.5;
  color: #ffffff;
  pointer-events: none;
}

.page-index__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: var(--primary-color, #017439);
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 20px;
  pointer-events: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
}

.page-index__faq-item.active .page-index__faq-toggle {
  color: #ffffff;
  transform: rotate(45deg); /* Rotate for minus sign effect */
  background: var(--primary-color, #017439);
}

.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.4s ease;
  padding: 0 25px;
  opacity: 0;
  color: #e0e0e0;
}

.page-index__faq-item.active .page-index__faq-answer {
  max-height: 2000px !important; /* Sufficiently large for content */
  padding: 20px 25px !important;
  opacity: 1;
  background: rgba(255, 255, 255, 0.03); /* Darker than question for contrast */
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0 0 8px 8px;
}

/* Brand Introduction Section */
.page-index__brand-section {
  background: #1a1a1a; /* Darker background */
  padding: 80px 20px;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.page-index__brand-container {
  max-width: 1200px;
  margin: 0 auto;
}

.page-index__brand-title {
  color: #ffffff;
  margin-bottom: 50px;
}

.page-index__brand-content {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
}

.page-index__brand-item {
  background: rgba(255, 255, 255, 0.07); /* Dark card background */
  border-radius: 12px;
  padding: 30px;
  flex: 1 1 calc(33% - 40px); /* 3 items per row on desktop */
  min-width: 300px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-index__brand-item-image {
  width: 100%;
  height: 250px; /* Fixed height for consistency */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
  display: block; /* Ensure it takes full width */
}

.page-index__brand-item h3 {
  color: var(--primary-color, #017439);
  font-size: 1.5em;
  margin-bottom: 15px;
  text-align: left;
}

.page-index__brand-item p {
  color: #e0e0e0;
  font-size: 1em;
}

/* Blog List Section */
.page-index__blog-section {
  background: #121212; /* Match body background */
  padding: 80px 20px;
}

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

.page-index__blog-title {
  color: #ffffff;
  margin-bottom: 50px;
}

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

.page-index__blog-item {
  background: rgba(255, 255, 255, 0.07); /* Dark card background */
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-index__blog-link {
  display: block;
  color: #ffffff;
  text-decoration: none;
  padding: 25px; /* Padding inside the link/card */
}

.page-index__blog-item-image {
  width: 100%;
  height: 200px; /* Consistent image height */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
  display: block;
  /* Ensure image is not smaller than 200px display size */
  min-width: 200px;
  min-height: 200px;
}

.page-index__blog-item-title {
  font-size: 1.4em;
  margin-bottom: 10px;
  color: var(--primary-color, #017439);
  line-height: 1.4;
}

.page-index__blog-item-excerpt {
  font-size: 0.95em;
  color: #e0e0e0;
  margin-bottom: 15px;
}

.page-index__blog-item-date {
  font-size: 0.85em;
  color: #888;
  display: block;
}

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

.page-index__view-more-button {
  display: inline-block;
  padding: 14px 30px;
  background: var(--primary-color, #017439);
  color: #ffffff;
  text-decoration: none;
  border-radius: 8px;
  font-size: 1em;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.page-index__view-more-button:hover {
  background: #005f2e;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

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

  .page-index__brand-item {
    flex: 1 1 calc(50% - 20px); /* 2 items per row */
  }
}

@media (max-width: 768px) {
  .page-index {
    font-size: 16px;
    line-height: 1.6;
    padding-bottom: 40px;
  }

  .page-index h1 {
    font-size: 2.2em;
  }

  .page-index h2 {
    font-size: 2em;
    margin-top: 30px;
    margin-bottom: 25px;
  }

  .page-index h3 {
    font-size: 1.6em;
  }

  /* Video Section Mobile */
  .page-index__video-section {
    padding-top: var(--header-offset, 120px) !important;
    padding-bottom: 40px;
    padding-left: 15px;
    padding-right: 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }
  
  .page-index__video-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 0;
    padding-right: 0;
    overflow: hidden !important;
  }
  
  .page-index__video-link {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .page-index__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    border-radius: 8px;
    overflow: hidden !important;
  }
  
  .page-index__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    border-radius: 8px;
    object-fit: contain;
  }
  
  .page-index__video-click-hint {
    font-size: 16px !important;
    padding: 10px 20px !important;
  }
  
  .page-index__video-cta {
    margin-top: 30px;
    padding-left: 15px;
    padding-right: 15px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  
  .page-index__play-now-button {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 15px 30px !important;
    font-size: 18px !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  /* H1 Title Section Mobile */
  .page-index__title-section {
    padding: 60px 15px;
  }

  .page-index__main-title {
    font-size: 2.2em;
    margin-bottom: 20px;
  }

  .page-index__title-description {
    font-size: 1.1em;
    margin-bottom: 30px;
  }

  .page-index__cta-buttons {
    flex-direction: column;
    gap: 15px;
    padding: 0 15px; /* Add padding to buttons container */
  }

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

  /* FAQ Section Mobile */
  .page-index__faq-section {
    padding: 60px 15px;
  }

  .page-index__faq-title {
    font-size: 2em;
    margin-bottom: 30px;
  }

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

  .page-index__faq-question h3 {
    font-size: 1em;
  }

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

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

  /* Brand Section Mobile */
  .page-index__brand-section {
    padding: 60px 15px;
  }

  .page-index__brand-title {
    font-size: 2em;
    margin-bottom: 40px;
  }

  .page-index__brand-content {
    flex-direction: column;
    gap: 20px;
  }

  .page-index__brand-item {
    flex: 1 1 100%; /* Single item per row */
    padding: 25px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-index__brand-item-image {
    height: 200px; /* Adjust height for mobile */
  }

  /* Blog Section Mobile */
  .page-index__blog-section {
    padding: 60px 15px;
  }

  .page-index__blog-title {
    font-size: 2em;
    margin-bottom: 40px;
  }

  .page-index__blog-list {
    grid-template-columns: 1fr; /* Single column for mobile */
    gap: 20px;
  }

  .page-index__blog-item {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-index__blog-item-image {
    height: 180px; /* Adjust height for mobile */
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    min-width: 200px;
    min-height: 200px; /* Ensure minimum size */
  }

  .page-index__blog-link {
    padding: 20px;
  }

  .page-index__blog-item-title {
    font-size: 1.2em;
  }

  .page-index__blog-item-excerpt {
    font-size: 0.9em;
  }

  .page-index__view-more-button-container {
    margin-top: 40px;
  }

  .page-index__view-more-button {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 12px 25px;
    font-size: 0.95em;
  }

  /* Ensure all images are responsive and don't overflow */
  .page-index img {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    box-sizing: border-box !important;
    min-width: 200px !important; /* Enforce min-width for all images */
    min-height: 200px !important; /* Enforce min-height for all images */
  }

  /* Ensure all containers with images/videos/buttons are responsive */
  .page-index__section,
  .page-index__container,
  .page-index__wrapper,
  .page-index__content,
  .page-index__list {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}

/* Base styles for all buttons to ensure responsiveness */
.page-index a[class*="button"],
.page-index a[class*="btn"] {
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
  text-align: center; /* Ensure text is centered within button */
}

/* Base styles for button containers */
.page-index__cta-buttons,
.page-index__button-group,
.page-index__btn-container {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

/* Mobile specific overrides for buttons and their containers */
@media (max-width: 768px) {
  .page-index a[class*="button"],
  .page-index a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px; /* Ensure padding inside button */
    padding-right: 15px; /* Ensure padding inside button */
  }

  .page-index__cta-buttons,
  .page-index__button-group,
  .page-index__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    flex-wrap: wrap !important;
    gap: 10px; /* Space between buttons if they wrap */
    flex-direction: column; /* Often better for multiple buttons on mobile */
  }
}

/* No CSS filters allowed for images */
.page-index img {
  filter: none !important;
}

/* Enforce minimum image display size in content areas */
.page-index__content-area img,
.page-index__brand-item-image,
.page-index__blog-item-image {
  min-width: 200px;
  min-height: 200px;
}