/* Base styles for the page-index content */
.page-index {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light background */
  background-color: var(--secondary-color, #FFFFFF); /* Body background from shared */
}

/* --- HERO Section Styles --- */
.page-index__hero-section {
  position: relative;
  padding-bottom: 0;
  padding-left: 0;
  padding-right: 0;
  padding-top: 10px; /* Assuming shared.css sets padding-top on body */
  margin-top: 0;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

.page-index__hero-container {
  position: relative;
  margin: 0 auto;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.page-index__hero-image {
  width: 100%;
  margin: 0;
}

.page-index__hero-image img {
  width: 100%;
  height: auto;
  max-width: 100%;
  display: block;
  filter: none; /* Ensure no CSS filters are applied */
}

/* Desktop specific styles for HERO image */
@media (min-width: 850px) {
  .page-index__hero-image img {
    aspect-ratio: 16/5; /* Wider aspect ratio for desktop banner */
    object-fit: cover;
  }
}

/* Mobile specific styles for HERO image */
@media (max-width: 849px) {
  .page-index__hero-section {
    padding-top: 10px !important; /* Ensure minimal top padding on mobile */
  }
  .page-index__hero-image img {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    aspect-ratio: unset !important; /* Remove fixed aspect ratio */
    object-fit: contain !important; /* Prevent cropping on mobile */
    max-height: none !important;
    display: block !important;
  }
}

/* --- Products Showcase Section Styles --- */
.page-index__products-section {
  width: 100%;
  padding: 60px 20px;
  box-sizing: border-box;
  background-color: var(--secondary-color, #FFFFFF);
}

.page-index__products-container {
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
}

.page-index__products-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(6, 1fr); /* Desktop: 6 columns */
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.page-index__product-card {
  width: 100%;
  max-width: 300px; /* Max width per card */
  border-radius: 0; /* No border-radius */
  overflow: hidden;
  background: transparent; /* No background */
  box-shadow: none; /* No box-shadow */
  transition: transform 0.3s ease;
}

.page-index__product-card:hover {
  transform: translateY(-3px);
}

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

.page-index__product-card-image {
  width: 100%;
  max-width: 300px; /* Image container max width */
  overflow: hidden;
}

.page-index__product-card-image img {
  max-width: 100%;
  width: 100%;
  height: auto; /* Maintain original aspect ratio */
  display: block;
  filter: none; /* Ensure no CSS filters are applied */
}

/* --- Centered Decorative H1 Title --- */
.page-index__section-title-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  width: 100%;
  max-width: 100%;
  padding: 24px 12px;
  box-sizing: border-box;
  text-align: center;
  background-color: var(--secondary-color, #FFFFFF);
}

.page-index__section-title {
  margin: 0;
  font-size: clamp(1.1rem, 4.5vw, 1.75rem); /* Responsive font size */
  line-height: 1.35;
  color: #26A9E0; /* Brand primary color for title */
  font-weight: 700;
}

.page-index__section-title-line {
  flex: 1;
  max-width: 80px;
  height: 2px;
  background-color: #26A9E0; /* Brand primary color for lines */
  opacity: 0.6;
}

/* --- Long SEO Article Body --- */
.page-index__article-body {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 12px 48px;
  box-sizing: border-box;
  overflow-x: hidden; /* Prevent horizontal scroll */
  background-color: var(--secondary-color, #FFFFFF);
}

.page-index__article-body h2 {
  margin: 2rem 0 1rem;
  color: #26A9E0; /* Brand primary color for H2 */
  font-size: 1.8rem;
  font-weight: 600;
  line-height: 1.3;
}

.page-index__article-body h3 {
  margin: 1.25rem 0 0.75rem;
  color: #333333; /* Darker text for H3 */
  font-size: 1.4rem;
  font-weight: 600;
  line-height: 1.4;
}

.page-index__article-body p {
  margin-bottom: 1rem;
  color: #333333;
}

.page-index__article-body ul {
  list-style: disc;
  padding-left: 25px;
  margin-bottom: 1rem;
  color: #333333;
}

.page-index__article-body li {
  margin-bottom: 0.5rem;
  color: #333333;
}

.page-index__article-body a {
  color: #26A9E0; /* Links in article body */
  text-decoration: underline;
}

.page-index__article-figure {
  margin: 1.5rem auto;
  max-width: 800px;
  text-align: center;
}

.page-index__article-figure img {
  width: 100%;
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 8px; /* Slight rounded corners for article images */
  filter: none; /* Ensure no CSS filters are applied */
}

.page-index__article-figure figcaption {
  margin-top: 0.5rem;
  font-size: 0.9rem;
  color: #666666;
}

.page-index__article-quote {
  margin: 1.5rem 0;
  padding: 1rem 1.25rem;
  border-left: 4px solid #26A9E0; /* Brand primary color for quote border */
  background-color: #f8f8f8;
  color: #333333;
  font-style: italic;
}

.page-index__article-quote-link {
  font-weight: bold;
}

/* --- Button Styles (for CTA in article body) --- */
.page-index__btn-primary {
  display: inline-block;
  background-color: #EA7C07; /* Custom color for login/action */
  color: #ffffff;
  padding: 12px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  border: none;
  cursor: pointer;
  max-width: 100%; /* Ensure button responsiveness */
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
  text-align: center;
}

.page-index__btn-primary:hover {
  background-color: #d16e06;
}

/* --- Global Image Responsive Styles --- */
.page-index img {
  max-width: 100%;
  height: auto;
  display: block;
  filter: none; /* Ensure no CSS filters are applied */
}

/* --- Responsive Styles for Mobile (max-width: 768px) --- */
@media (max-width: 768px) {
  /* Generic container/section padding for mobile */
  .page-index__section,
  .page-index__card,
  .page-index__container {
    padding-left: 15px !important;
    padding-right: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }

  /* HERO Section specific for mobile */
  .page-index__hero-section {
    padding-top: 10px !important; /* Ensure minimal top padding on mobile */
  }
  .page-index__hero-image img {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    aspect-ratio: unset !important;
    object-fit: contain !important;
    max-height: none !important;
    display: block !important;
  }

  /* Products Showcase Section specific for mobile */
  .page-index__products-section {
    padding: 40px 15px;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
  }
  .page-index__products-container,
  .page-index__products-grid {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
  }
  .page-index__products-grid {
    grid-template-columns: repeat(2, 1fr); /* Mobile: 2 columns x 3 rows */
    gap: 15px;
  }
  .page-index__product-card,
  .page-index__product-card-image {
    max-width: 100%; /* Adjust card max-width for mobile */
  }

  /* Centered Decorative H1 Title specific for mobile */
  .page-index__section-title-wrap {
    padding: 20px 10px;
  }
  .page-index__section-title {
    font-size: clamp(1.25rem, 5vw, 1.6rem); /* Adjust clamp for mobile */
    line-height: 1.4;
  }
  .page-index__section-title-line {
    max-width: 40px; /* Shorter lines on mobile */
  }

  /* Long SEO Article Body specific for mobile */
  .page-index__article-body {
    padding: 0 15px 32px; /* Adjust padding for mobile */
    font-size: 16px; /* Base font size for mobile readability */
  }
  .page-index__article-body h2 {
    font-size: clamp(1.3rem, 5.5vw, 1.6rem); /* Adjust H2 font size for mobile */
    margin: 1.5rem 0 0.8rem;
  }
  .page-index__article-body h3 {
    font-size: clamp(1.1rem, 4.5vw, 1.3rem); /* Adjust H3 font size for mobile */
    margin: 1rem 0 0.6rem;
  }
  .page-index__article-figure {
    margin: 1rem auto;
  }
  .page-index__article-figure img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-index__article-quote {
    margin: 1rem 0;
    padding: 0.8rem 1rem;
  }
  .page-index__article-body ul {
    padding-left: 20px;
  }

  /* Buttons and button containers specific for mobile */
  .page-index__btn-primary {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    margin-bottom: 10px;
  }
  .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 !important;
    padding-right: 15px !important;
    overflow-x: hidden !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 10px;
  }
}

/* Ensure all images within .page-index are responsive by default */
.page-index img {
  max-width: 100%;
  height: auto;
  display: block;
  filter: none; /* Explicitly remove any potential filters */
}

/* Contrast Fixes (as per requirements) */
.page-index__dark-bg {
  color: #ffffff; /* Deep blue background with white text */
  background-color: #26A9E0;
}

.page-index__light-bg {
  color: #333333; /* White background with dark grey text */
  background-color: #ffffff;
}