/* style/about.css */

/* Common styles for page-about scope */
.page-about {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light background */
  background-color: var(--background-color, #ffffff);
}

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

.page-about__content-area {
  padding: 40px 0;
}

.page-about h1 {
  font-weight: 700;
  line-height: 1.2;
  color: #ffffff;
  margin-bottom: 20px;
  max-width: 900px; /* Prevent H1 from being too wide */
}

.page-about h2 {
  font-size: 2.2em;
  font-weight: 700;
  margin-bottom: 20px;
  color: #26A9E0;
  text-align: center;
}

.page-about h3 {
  font-size: 1.6em;
  font-weight: 600;
  margin-top: 30px;
  margin-bottom: 15px;
  color: #26A9E0;
}

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

.page-about ul {
  list-style: disc;
  margin-left: 20px;
  margin-bottom: 15px;
}

.page-about li {
  margin-bottom: 8px;
}

/* Color Contrast Specifics */
.page-about__dark-bg {
  background-color: #26A9E0;
  color: #ffffff;
}

.page-about__dark-bg h1, .page-about__dark-bg h2, .page-about__dark-bg h3 {
  color: #ffffff;
}

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

.page-about__light-bg h2, .page-about__light-bg h3 {
  color: #26A9E0;
}

/* Buttons */
.page-about__btn {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  text-align: center;
  transition: all 0.3s ease;
  box-sizing: border-box;
  max-width: 100%; /* Ensure buttons don't overflow */
  white-space: normal; /* Allow text to wrap */
  word-wrap: break-word; /* Break long words */
}

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

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

.page-about__btn-secondary {
  background-color: transparent;
  color: #26A9E0;
  border: 2px solid #26A9E0;
  margin-left: 15px;
}

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

.page-about__cta-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-top: 30px;
  justify-content: center;
}

/* Hero Section */
.page-about__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 0;
  padding-top: 10px; /* Small top padding, body handles --header-offset */
  text-align: center;
}

.page-about__hero-image {
  width: 100%;
  height: auto;
  max-width: 100%;
  display: block;
  margin-bottom: 30px;
  border-radius: 10px;
}

.page-about__hero-content {
  max-width: 800px;
}

/* Content Sections Layout */
.page-about__mission-vision-section .page-about__container,
.page-about__history-development-section .page-about__container,
.page-about__security-safety-section .page-about__container,
.page-about__team-culture-section .page-about__container,
.page-about__contact-support-section .page-about__container {
  display: flex;
  align-items: center;
  gap: 40px;
  padding-top: 40px;
  padding-bottom: 40px;
}

.page-about__history-development-section .page-about__container,
.page-about__contact-support-section .page-about__container {
  flex-direction: row-reverse; /* Image on right for these sections */
}

.page-about__image-content {
  flex: 1;
  min-width: 300px; /* Ensure images are not too small */
  max-width: 50%;
  height: auto;
  display: block;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.page-about__content-area {
  flex: 1;
  padding: 0;
  text-align: left;
}

/* Game Categories */
.page-about__game-categories {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 30px;
}

.page-about__game-category {
  background-color: #f9f9f9;
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  text-align: center;
}

.page-about__game-category h3 {
  color: #26A9E0;
  margin-top: 0;
  text-align: center;
}

.page-about__game-category .page-about__btn {
  margin-top: 15px;
  margin-left: 0;
  margin-right: 0;
}

/* FAQ Section */
.page-about__faq-list {
  margin-top: 30px;
}

.page-about__faq-item {
  background-color: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-about__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  cursor: pointer;
  font-weight: 600;
  color: #333333;
  background-color: #f0f0f0;
  border-bottom: 1px solid #e0e0e0;
}

.page-about__faq-item[open] .page-about__faq-question {
  border-bottom: 1px solid #26A9E0;
  background-color: #eaf7ff;
  color: #26A9E0;
}

.page-about__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  transition: transform 0.3s ease;
}

.page-about__faq-item[open] .page-about__faq-toggle {
  transform: rotate(45deg);
}

.page-about__faq-answer {
  padding: 15px 20px;
  color: #555555;
}

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

.page-about__faq-item summary {
  list-style: none;
}

/* CTA Section */
.page-about__cta-section {
  padding: 80px 0;
  text-align: center;
}

.page-about__cta-section h2 {
  margin-bottom: 25px;
}

.page-about__cta-section .page-about__btn-primary {
  margin-top: 30px;
  margin-left: 0;
  margin-right: 0;
}

/* Responsive Design */
@media (max-width: 992px) {
  .page-about__mission-vision-section .page-about__container,
  .page-about__history-development-section .page-about__container,
  .page-about__security-safety-section .page-about__container,
  .page-about__team-culture-section .page-about__container,
  .page-about__contact-support-section .page-about__container {
    flex-direction: column;
    text-align: center;
  }

  .page-about__image-content {
    max-width: 80%;
    margin-bottom: 30px;
  }

  .page-about__content-area {
    padding: 0;
  }
}

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

  .page-about h1 {
    font-size: 2em;
  }

  .page-about h2 {
    font-size: 1.8em;
  }

  .page-about h3 {
    font-size: 1.4em;
  }

  .page-about__container {
    padding: 0 15px;
  }

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

  .page-about__cta-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .page-about__btn-secondary {
    margin-left: 0;
  }

  /* Images responsive */
  .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__game-category {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }

  /* Buttons responsive */
  .page-about__cta-button,
  .page-about__btn-primary,
  .page-about__btn-secondary,
  .page-about a[class*="button"],
  .page-about 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;
    padding-right: 15px;
  }

  .page-about__cta-buttons,
  .page-about__button-group,
  .page-about__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;
  }
}