/* style/contact.css */
/* body đã padding-top: var(--header-offset); trang này không được viết lại padding-top cho body */

:root {
  --rr88-primary-color: #11A84E;
  --rr88-secondary-color: #22C768;
  --rr88-card-bg: #11271B;
  --rr88-background: #08160F;
  --rr88-text-main: #F2FFF6;
  --rr88-text-secondary: #A7D9B8;
  --rr88-border-color: #2E7A4E;
  --rr88-glow-color: #57E38D;
  --rr88-gold-color: #F2C14E;
  --rr88-divider-color: #1E3A2A;
  --rr88-deep-green: #0A4B2C;
  --rr88-button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
}

.page-contact {
  font-family: Arial, sans-serif;
  color: var(--rr88-text-main); /* Deep Green background, so light text */
  background-color: var(--rr88-background);
  line-height: 1.6;
}

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

.page-contact__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 0 60px 0; /* body đã xử lý padding-top cho header, đây chỉ là khoảng cách nhỏ */
  overflow: hidden;
}

.page-contact__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 600px; /* Giới hạn chiều cao để không quá lớn */
}

.page-contact__hero-content {
  text-align: center;
  padding: 40px 20px;
  max-width: 900px;
  z-index: 1; /* Đảm bảo nội dung không bị ảnh hưởng bởi ảnh nền */
}

.page-contact__main-title {
  color: var(--rr88-text-main);
  font-weight: bold;
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  /* Không đặt font-size cố định quá lớn, dùng font-weight và line-height để tạo hiệu ứng */
}

.page-contact__description {
  color: var(--rr88-text-secondary);
  font-size: 1.1em;
  margin-bottom: 30px;
}

.page-contact__section-title {
  color: var(--rr88-text-main);
  font-size: 2.2em;
  font-weight: bold;
  text-align: center;
  margin-bottom: 30px;
  position: relative;
  padding-bottom: 10px;
}

.page-contact__section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: var(--rr88-gold-color);
  border-radius: 2px;
}

.page-contact__text-block {
  color: var(--rr88-text-secondary);
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px auto;
  font-size: 1em;
}

/* Contact Methods Section */
.page-contact__methods-section,
.page-contact__form-section,
.page-contact__faq-section,
.page-contact__why-contact-section,
.page-contact__cta-section {
  padding: 80px 0;
  border-top: 1px solid var(--rr88-divider-color);
}

.page-contact__method-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-contact__method-card,
.page-contact__feature-card {
  background-color: var(--rr88-card-bg);
  border: 1px solid var(--rr88-border-color);
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-contact__method-card:hover,
.page-contact__feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3), 0 0 15px var(--rr88-glow-color);
}

.page-contact__method-icon,
.page-contact__feature-icon {
  width: 120px;
  height: 120px;
  margin-bottom: 20px;
  object-fit: contain;
  border-radius: 50%;
  border: 3px solid var(--rr88-primary-color);
  padding: 10px;
  box-shadow: 0 0 10px var(--rr88-glow-color);
}

.page-contact__method-title,
.page-contact__feature-title {
  color: var(--rr88-text-main);
  font-size: 1.5em;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-contact__method-description,
.page-contact__feature-description {
  color: var(--rr88-text-secondary);
  font-size: 0.95em;
  margin-bottom: 25px;
  flex-grow: 1;
}

/* Buttons */
.page-contact__btn-primary,
.page-contact__btn-secondary {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1em;
  transition: all 0.3s ease;
  text-align: center;
  cursor: pointer;
  white-space: normal; /* Cho phép chữ xuống dòng */
  word-wrap: break-word; /* Ngắt từ khi cần */
  box-sizing: border-box;
}

.page-contact__btn-primary {
  background: var(--rr88-button-gradient);
  color: #ffffff;
  border: 2px solid transparent;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.page-contact__btn-primary:hover {
  background: linear-gradient(180deg, #13994A 0%, #2AD16F 100%);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3), 0 0 12px var(--rr88-glow-color);
}

.page-contact__btn-secondary {
  background-color: transparent;
  color: var(--rr88-primary-color);
  border: 2px solid var(--rr88-primary-color);
}

.page-contact__btn-secondary:hover {
  background-color: var(--rr88-primary-color);
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* Contact Form */
.page-contact__contact-form {
  max-width: 700px;
  margin: 40px auto 0 auto;
  background-color: var(--rr88-card-bg);
  border: 1px solid var(--rr88-border-color);
  border-radius: 12px;
  padding: 40px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-contact__form-group {
  margin-bottom: 25px;
}

.page-contact__form-label {
  display: block;
  color: var(--rr88-text-main);
  font-size: 1.1em;
  margin-bottom: 8px;
  font-weight: bold;
}

.page-contact__form-input,
.page-contact__form-textarea {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid var(--rr88-border-color);
  border-radius: 8px;
  background-color: var(--rr88-deep-green);
  color: var(--rr88-text-main);
  font-size: 1em;
  box-sizing: border-box;
}

.page-contact__form-input::placeholder,
.page-contact__form-textarea::placeholder {
  color: var(--rr88-text-secondary);
  opacity: 0.7;
}

.page-contact__form-input:focus,
.page-contact__form-textarea:focus {
  outline: none;
  border-color: var(--rr88-primary-color);
  box-shadow: 0 0 0 3px rgba(var(--rr88-primary-color-rgb), 0.3);
}

.page-contact__submit-button {
  width: auto;
  padding-left: 40px;
  padding-right: 40px;
  margin-top: 20px;
  display: block; /* Để nút nằm giữa nếu cần */
  margin-left: auto;
  margin-right: auto;
}

/* FAQ Section */
.page-contact__faq-list {
  max-width: 900px;
  margin: 40px auto 0 auto;
}

.page-contact__faq-item {
  background-color: var(--rr88-card-bg);
  border: 1px solid var(--rr88-border-color);
  border-radius: 10px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.page-contact__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  color: var(--rr88-text-main);
  font-size: 1.15em;
  font-weight: bold;
  cursor: pointer;
  background-color: var(--rr88-deep-green);
  transition: background-color 0.3s ease;
  list-style: none; /* For details/summary */
}

.page-contact__faq-question::-webkit-details-marker {
  display: none;
}

.page-contact__faq-item[open] > .page-contact__faq-question {
  background-color: var(--rr88-primary-color);
}

.page-contact__faq-question:hover {
  background-color: var(--rr88-primary-color);
}

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

.page-contact__faq-toggle {
  font-size: 1.5em;
  margin-left: 20px;
  color: var(--rr88-gold-color);
}

.page-contact__faq-answer {
  padding: 15px 25px 20px 25px;
  background-color: var(--rr88-card-bg);
  color: var(--rr88-text-secondary);
  font-size: 1em;
  line-height: 1.6;
}

.page-contact__cta-container {
  text-align: center;
  margin-top: 40px;
}

.page-contact__features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-contact__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
  flex-wrap: wrap; /* Cho phép nút xuống dòng trên di động */
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-contact__main-title {
    font-size: clamp(2.5em, 5vw, 3.5em);
  }
  .page-contact__section-title {
    font-size: clamp(1.8em, 4vw, 2.5em);
  }
  .page-contact__hero-image {
    max-height: 500px;
  }
}

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

  .page-contact__container {
    padding-left: 15px !important;
    padding-right: 15px !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow-x: hidden;
  }

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

  .page-contact__hero-image {
    max-height: 400px;
    width: 100% !important;
    height: auto !important;
  }

  .page-contact__hero-content {
    padding: 20px 15px;
  }

  .page-contact__main-title {
    font-size: clamp(2em, 7vw, 3em);
    margin-bottom: 15px;
  }

  .page-contact__description {
    font-size: 1em;
  }

  .page-contact__section-title {
    font-size: clamp(1.5em, 6vw, 2em);
    margin-bottom: 20px;
  }

  .page-contact__text-block {
    margin-bottom: 30px;
  }

  .page-contact__methods-section,
  .page-contact__form-section,
  .page-contact__faq-section,
  .page-contact__why-contact-section,
  .page-contact__cta-section {
    padding: 50px 0;
  }

  .page-contact__method-grid,
  .page-contact__features-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-contact__method-card,
  .page-contact__feature-card {
    padding: 25px;
  }

  .page-contact__method-icon,
  .page-contact__feature-icon {
    width: 100px;
    height: 100px;
    margin-bottom: 15px;
  }

  .page-contact__method-title,
  .page-contact__feature-title {
    font-size: 1.3em;
  }

  .page-contact__btn-primary,
  .page-contact__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 15px;
  }

  .page-contact__contact-form {
    padding: 30px 20px;
  }

  .page-contact__form-label {
    font-size: 1em;
  }

  .page-contact__form-input,
  .page-contact__form-textarea {
    padding: 10px 12px;
  }

  .page-contact__faq-question {
    padding: 15px 20px;
    font-size: 1em;
  }

  .page-contact__faq-answer {
    padding: 10px 20px 15px 20px;
  }

  .page-contact__cta-buttons {
    flex-direction: column;
    gap: 15px;
  }
  
  /* Ensure all images are responsive */
  .page-contact img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-contact__section,
  .page-contact__card,
  .page-contact__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  
  .page-contact__video-section {
    padding-top: 10px !important; /* body đã承担 --header-offset，此处禁止 var(--header-offset) */
  }

  /* Video specific mobile styles, if any video exists */
  .page-contact video,
  .page-contact__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-contact__video-section,
  .page-contact__video-container,
  .page-contact__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
}

/* Color Contrast Safety for elements not explicitly colored */
.page-contact p, .page-contact li, .page-contact label {
  color: var(--rr88-text-secondary); /* Ensure readability on dark background */
}

.page-contact__card p, .page-contact__card li {
  color: var(--rr88-text-secondary);
}

.page-contact__contact-form label {
  color: var(--rr88-text-main);
}