/* style/about.css */

/* Căn chỉnh màu sắc dựa trên body background từ shared.css (giả định tối) */
.page-about {
  color: var(--text-main, #F2FFF6);
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
}

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

.page-about__section {
  padding: 60px 0;
  text-align: center;
}

.page-about__section-title {
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: var(--text-main, #F2FFF6);
  margin-bottom: 30px;
  font-weight: 700;
  line-height: 1.2;
}

.page-about__text-block {
  font-size: 1.1rem;
  color: var(--text-secondary, #A7D9B8);
  max-width: 900px;
  margin: 0 auto 20px auto;
  line-height: 1.7;
}

/* Hero Section */
.page-about__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 600px;
  padding: 10px 0 60px 0; /* body đã có padding-top, đây chỉ cần 10px */
  background-color: var(--background, #08160F);
  overflow: hidden;
}

.page-about__hero-image-wrapper {
  width: 100%;
  max-height: 700px;
  overflow: hidden;
  position: relative;
}

.page-about__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  filter: brightness(0.7); /* Chỉ làm tối hình ảnh, không thay đổi màu */
}

.page-about__hero-content {
  position: relative;
  z-index: 1;
  padding: 40px 20px;
  max-width: 900px;
  margin-top: -150px; /* Kéo nội dung lên trên hình ảnh một chút */
  background: linear-gradient(0deg, var(--background, #08160F) 0%, rgba(8, 22, 15, 0.8) 50%, rgba(8, 22, 15, 0) 100%);
}

.page-about__main-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  color: var(--text-main, #F2FFF6);
  margin-bottom: 20px;
  font-weight: 800;
  line-height: 1.1;
}

.page-about__hero-description {
  font-size: 1.2rem;
  color: var(--text-secondary, #A7D9B8);
  margin-bottom: 30px;
  line-height: 1.8;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* Buttons */
.page-about__btn-primary,
.page-about__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  text-align: center;
  box-sizing: border-box;
  max-width: 100%; /* Đảm bảo nút không tràn */
  white-space: normal; /* Cho phép xuống dòng */
  word-wrap: break-word; /* Ngắt từ khi cần */
}

.page-about__btn-primary {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  color: #F2FFF6;
  border: none;
}

.page-about__btn-primary:hover {
  background: linear-gradient(180deg, #13994A 0%, #2AD16F 100%);
  transform: translateY(-2px);
}

.page-about__btn-secondary {
  background: transparent;
  color: var(--main-color, #11A84E);
  border: 2px solid var(--border-color, #2E7A4E);
}

.page-about__btn-secondary:hover {
  background: var(--main-color, #11A84E);
  color: #F2FFF6;
  transform: translateY(-2px);
}

/* Story Section */
.page-about__story-section {
  background-color: var(--background, #08160F);
}

.page-about__image-content {
  width: 100%;
  max-width: 800px;
  height: auto;
  display: block;
  margin: 30px auto;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* Mission & Vision Section */
.page-about__mission-vision-section {
  background-color: var(--card-bg, #11271B);
}

.page-about__grid-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  margin-top: 40px;
}

@media (min-width: 768px) {
  .page-about__grid-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

.page-about__card {
  background-color: var(--card-bg, #11271B);
  border: 1px solid var(--border-color, #2E7A4E);
  border-radius: 10px;
  padding: 30px;
  text-align: left;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.page-about__card-title {
  font-size: 1.8rem;
  color: var(--text-main, #F2FFF6);
  margin-bottom: 15px;
  font-weight: 700;
}

.page-about__card-text {
  font-size: 1rem;
  color: var(--text-secondary, #A7D9B8);
  line-height: 1.7;
  flex-grow: 1;
}

/* Core Values Section */
.page-about__values-section {
  background-color: var(--background, #08160F);
}

.page-about__values-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 25px;
  margin-top: 40px;
}

@media (min-width: 768px) {
  .page-about__values-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .page-about__values-list {
    grid-template-columns: repeat(3, 1fr);
  }
}

.page-about__value-item {
  background-color: var(--card-bg, #11271B);
  border: 1px solid var(--border-color, #2E7A4E);
  border-radius: 10px;
  padding: 25px;
  text-align: left;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}

.page-about__value-title {
  font-size: 1.5rem;
  color: var(--text-main, #F2FFF6);
  margin-bottom: 10px;
  font-weight: 600;
}

.page-about__value-description {
  font-size: 0.95rem;
  color: var(--text-secondary, #A7D9B8);
  line-height: 1.6;
}

/* Why Choose Section */
.page-about__why-choose-section {
  background-color: var(--background, #08160F);
}

.page-about__features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  margin-top: 40px;
}

@media (min-width: 768px) {
  .page-about__features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .page-about__features-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.page-about__feature-card {
  background-color: var(--card-bg, #11271B);
  border: 1px solid var(--border-color, #2E7A4E);
  border-radius: 10px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.page-about__feature-icon {
  width: 100%;
  max-width: 250px;
  height: auto;
  margin: 0 auto 20px auto;
  display: block;
  border-radius: 8px;
}

.page-about__feature-title {
  font-size: 1.6rem;
  color: var(--text-main, #F2FFF6);
  margin-bottom: 15px;
  font-weight: 700;
}

.page-about__feature-description {
  font-size: 1rem;
  color: var(--text-secondary, #A7D9B8);
  line-height: 1.7;
  flex-grow: 1;
}

/* Responsible Gaming Section */
.page-about__responsible-gaming-section {
  background-color: var(--card-bg, #11271B);
}

/* FAQ Section */
.page-about__faq-section {
  background-color: var(--background, #08160F);
}

.page-about__faq-list {
  margin-top: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  text-align: left;
}

.page-about__faq-item {
  background-color: var(--card-bg, #11271B);
  border: 1px solid var(--border-color, #2E7A4E);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.page-about__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-main, #F2FFF6);
  cursor: pointer;
  background-color: var(--deep-green, #0A4B2C);
  border-bottom: 1px solid var(--divider, #1E3A2A);
}

.page-about__faq-item[open] .page-about__faq-question {
  border-bottom: 1px solid transparent;
}

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

.page-about__faq-toggle {
  font-size: 1.5rem;
  line-height: 1;
  margin-left: 15px;
  color: var(--glow, #57E38D);
}

.page-about__faq-item[open] .page-about__faq-toggle {
  content: '−';
}

.page-about__faq-answer {
  padding: 20px 25px;
  font-size: 1rem;
  color: var(--text-secondary, #A7D9B8);
  line-height: 1.7;
  background-color: var(--card-bg, #11271B);
}

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

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

/* CTA Section */
.page-about__cta-section {
  background-color: var(--main-color, #11A84E);
  padding: 80px 0;
}

.page-about__cta-section .page-about__section-title {
  color: #F2FFF6;
}

.page-about__cta-section .page-about__text-block {
  color: #F2FFF6;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-about__hero-content {
    margin-top: -100px;
  }
  .page-about__section {
    padding: 50px 0;
  }
}

@media (max-width: 768px) {
  .page-about__hero-content {
    margin-top: -80px;
  }
  .page-about__main-title {
    font-size: clamp(2rem, 8vw, 2.5rem);
  }
  .page-about__hero-description {
    font-size: 1rem;
  }
  .page-about__section-title {
    font-size: clamp(1.8rem, 6vw, 2.2rem);
  }
  .page-about__text-block {
    font-size: 0.95rem;
  }
  .page-about__btn-primary,
  .page-about__btn-secondary {
    padding: 12px 25px;
    font-size: 1rem;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    margin-bottom: 15px; /* Add spacing between stacked buttons */
  }
  .page-about__btn-primary:last-child, .page-about__btn-secondary:last-child {
    margin-bottom: 0;
  }
  .page-about__hero-section .page-about__btn-primary {
    width: auto !important; /* Allow hero button to be smaller if text wraps */
    max-width: 300px !important;
    margin: 0 auto;
  }
  .page-about__features-grid,
  .page-about__grid-container,
  .page-about__values-list {
    grid-template-columns: 1fr;
  }

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

  /* All containers for images/content must handle overflow */
  .page-about__section,
  .page-about__card,
  .page-about__container,
  .page-about__hero-section,
  .page-about__hero-image-wrapper,
  .page-about__features-grid,
  .page-about__grid-container,
  .page-about__values-list,
  .page-about__faq-list,
  .page-about__cta-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important; /* Prevent horizontal scroll */
  }
  .page-about__hero-section {
    padding-top: 10px !important; /* body đã承担 --header-offset，此处禁止 var(--header-offset) */
  }
  .page-about__hero-content {
    padding-left: 15px;
    padding-right: 15px;
  }
}

/* Desktop specific styles for hero content to prevent overlay on image */
@media (min-width: 769px) {
  .page-about__hero-content {
    position: relative; /* Ensure text is below image in DOM flow */
    margin-top: 0; /* Reset negative margin for larger screens */
    padding-top: 40px; /* Add proper padding */
    background: none; /* Remove gradient overlay for larger screens */
  }
  .page-about__hero-image-wrapper {
    order: -1; /* Place image visually above content */
    margin-bottom: 30px; /* Space between image and text */
  }
  .page-about__hero-section {
    flex-direction: column; /* Stack image and text vertically */
    min-height: auto; /* Adjust height for content */
    padding-bottom: 60px;
  }
  .page-about__hero-image {
    filter: none; /* Remove brightness filter */
  }
}