/* style/about.css */

/* Base styles for the About Us page */
.page-about {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light backgrounds */
  background-color: var(--background-color, #ffffff); /* Inherit from shared or default to white */
}

.page-about__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

.page-about__section-title {
  font-size: 2.5em;
  font-weight: bold;
  color: #26A9E0; /* Primary brand color */
  text-align: center;
  margin-bottom: 40px;
  padding-top: 20px;
}

.page-about__section-title--white {
  color: #ffffff;
}

.page-about__text-block {
  font-size: 1.1em;
  text-align: center;
  margin-bottom: 30px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-about__text-block--white {
  color: #ffffff;
}

.page-about__card {
  background-color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  padding: 30px;
  text-align: center;
  transition: transform 0.3s ease;
  height: 100%; /* Ensure cards in a grid have equal height */
  box-sizing: border-box;
}

.page-about__card:hover {
  transform: translateY(-5px);
}

.page-about__card-title {
  font-size: 1.5em;
  color: #26A9E0;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-about__card-text {
  font-size: 1em;
  color: #555555;
}

/* Hero Section */
.page-about__hero-section {
  position: relative;
  overflow: hidden;
  padding: 10px 0 60px 0; /* Small top padding, then larger bottom padding */
  text-align: center;
  display: flex;
  flex-direction: column; /* Image above, text below */
  align-items: center;
  justify-content: center;
}

.page-about__hero-image-wrapper {
  width: 100%;
  max-height: 600px; /* Limit height for aesthetic */
  overflow: hidden;
  margin-bottom: 30px; /* Space between image and content */
}

.page-about__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  min-height: 300px; /* Ensure minimum size */
}

.page-about__hero-content {
  position: relative; /* Ensure content is above any potential background effect */
  z-index: 1;
  color: #ffffff; /* White text for dark background */
  padding-top: 0; /* Already handled by section padding */
}

.page-about__main-title {
  font-size: clamp(2.2em, 4vw, 3.2em); /* Responsive font size */
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 20px;
  color: #ffffff;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-about__hero-description {
  font-size: 1.15em;
  margin-bottom: 30px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: #f0f0f0;
}

.page-about__cta-buttons {
  display: flex;
  flex-wrap: wrap; /* Allow wrapping on small screens */
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
}

.page-about__btn-primary,
.page-about__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  min-width: 180px;
  text-align: center;
  box-sizing: border-box;
}

.page-about__btn-primary {
  background-color: #EA7C07; /* Login color */
  color: #ffffff;
  border: 2px solid #EA7C07;
}

.page-about__btn-primary:hover {
  background-color: #d16b06;
  border-color: #d16b06;
}

.page-about__btn-secondary {
  background-color: #ffffff;
  color: #26A9E0;
  border: 2px solid #26A9E0;
}

.page-about__btn-secondary:hover {
  background-color: #26A9E0;
  color: #ffffff;
}

/* Mission & Vision Section */
.page-about__mission-vision {
  padding: 60px 0;
}

.page-about__grid-two-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

/* Why Choose hihi88 Section */
.page-about__why-choose {
  padding: 60px 0;
  background-color: #26A9E0; /* Primary brand color as background */
  color: #ffffff;
}

.page-about__content-with-image {
  display: flex;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
}

.page-about__text-content {
  flex: 1;
  min-width: 300px;
}

.page-about__image-container {
  flex: 1;
  min-width: 300px;
  text-align: center;
}

.page-about__content-image {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  min-height: 200px; /* Ensure minimum size */
}

.page-about__feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.page-about__feature-item {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 15px 20px;
  margin-bottom: 15px;
  font-size: 1.05em;
  line-height: 1.5;
}

.page-about__feature-item strong {
  color: #ffffff;
}

/* Our Values Section */
.page-about__our-values {
  padding: 60px 0;
}

.page-about__grid-three-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.page-about__value-card {
  background-color: #ffffff;
}

.page-about__value-image-wrapper {
  grid-column: span 1; /* Default span for single column */
  display: flex;
  align-items: center;
  justify-content: center;
}
/* Ensure image spans across columns on larger screens if needed */
@media (min-width: 992px) {
  .page-about__value-image-wrapper {
    grid-column: span 2; /* Make image span 2 columns on larger screens if desired */
  }
  .page-about__grid-three-cols {
    grid-template-columns: repeat(3, 1fr);
  }
  .page-about__value-image-wrapper:nth-child(5) { /* Target the 5th item if it's the image */
      grid-column: 2 / span 2; /* Position it central and span 2 columns */
  }
}


/* Responsible Gaming Section */
.page-about__responsible-gaming {
  padding: 60px 0;
  background-color: #26A9E0;
  color: #ffffff;
  text-align: center;
}

.page-about__responsible-gaming-image {
  margin-top: 40px;
}

/* Join Us Section */
.page-about__join-us {
  padding: 60px 0;
  text-align: center;
}

/* FAQ Section */
.page-about__faq-section {
  padding: 60px 0;
  background-color: #000000; /* Dark background for contrast */
  color: #ffffff;
}

.page-about__faq-list {
  max-width: 900px;
  margin: 0 auto;
}

.page-about__faq-item {
  background-color: rgba(255, 255, 255, 0.08); /* Slightly visible background */
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-about__faq-item summary {
  list-style: none; /* Remove default marker */
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-weight: bold;
  font-size: 1.15em;
  color: #ffffff;
  cursor: pointer;
  background-color: rgba(255, 255, 255, 0.05); /* Slightly darker on summary */
  transition: background-color 0.3s ease;
}

.page-about__faq-item summary::-webkit-details-marker {
  display: none; /* Hide default marker for webkit browsers */
}

.page-about__faq-item summary:hover {
  background-color: rgba(255, 255, 255, 0.15);
}

.page-about__faq-qtext {
  flex-grow: 1;
}

.page-about__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  margin-left: 15px;
  color: #26A9E0; /* Primary brand color for toggle */
}

.page-about__faq-answer {
  padding: 0 25px 20px 25px;
  font-size: 1em;
  color: #f0f0f0;
  line-height: 1.6;
}

/* Color Contrast Fixes (as per instructions) */
.page-about__dark-section {
  background-color: #26A9E0; /* Primary brand color */
  color: #ffffff;
}

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

/* Responsive Design */
@media (max-width: 992px) {
  .page-about__grid-two-cols,
  .page-about__content-with-image {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .page-about__content-with-image {
    flex-direction: column;
  }

  .page-about__text-content,
  .page-about__image-container {
    min-width: unset;
  }

  .page-about__hero-image-wrapper {
    max-height: 400px;
  }

  .page-about__main-title {
    font-size: clamp(2em, 5vw, 2.8em);
  }

  .page-about__section-title {
    font-size: 2em;
  }
}

@media (max-width: 768px) {
  .page-about__container {
    padding: 0 15px; /* Add side padding for mobile */
  }

  .page-about__hero-section {
    padding: 10px 0 40px 0;
  }

  .page-about__main-title {
    font-size: clamp(1.8em, 6vw, 2.5em);
  }

  .page-about__hero-description,
  .page-about__text-block,
  .page-about__card-text,
  .page-about__feature-item,
  .page-about__faq-answer p {
    font-size: 0.95em;
  }

  .page-about__section-title {
    font-size: 1.8em;
    margin-bottom: 30px;
  }

  .page-about__cta-buttons {
    flex-direction: column; /* Stack buttons vertically */
    gap: 15px;
  }

  .page-about__btn-primary,
  .page-about__btn-secondary {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding: 12px 20px; /* Adjust padding for mobile buttons */
  }

  /* Image, Video, Button Responsive Adaptations */
  .page-about img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-about__section,
  .page-about__card,
  .page-about__container,
  .page-about__hero-image-wrapper,
  .page-about__image-container,
  .page-about__content-with-image,
  .page-about__cta-buttons,
  .page-about__faq-list {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important; /* Prevent horizontal scroll */
  }

  /* Ensure content area images are not too small */
  .page-about__content-image {
    min-width: 200px !important;
    min-height: 200px !important;
  }

  /* Specific padding for sections in mobile */
  .page-about__mission-vision,
  .page-about__why-choose,
  .page-about__our-values,
  .page-about__responsible-gaming,
  .page-about__join-us,
  .page-about__faq-section {
    padding: 40px 0 !important; /* Adjust section padding */
  }

  /* FAQ items on mobile */
  .page-about__faq-item summary {
    font-size: 1em;
    padding: 15px 20px;
  }
  .page-about__faq-answer {
    padding: 0 20px 15px 20px;
  }
}

/* Ensure content area images are not too small by default */
.page-about__content-image {
  min-width: 200px;
  min-height: 200px;
}

/* Additional style for the value image to make it span two columns on desktop */
@media (min-width: 769px) {
  .page-about__grid-three-cols {
    grid-template-columns: repeat(3, 1fr); /* Default 3 columns */
  }
  .page-about__value-image-wrapper {
    grid-column: span 2; /* Span 2 columns */
    grid-row: 2 / span 1; /* Place in the second row, spanning one row */
    margin: auto; /* Center the image in its grid area */
  }
  .page-about__value-card:nth-child(4) { /* Adjust layout for the 4th card */
      grid-column: 1 / span 1;
  }
}

/* Ensure no video is accidentally styled with filter */
.page-about video {
  filter: none !important;
}