/* style/contact.css */

/* --- Base Styles --- */
.page-contact {
  font-family: Arial, sans-serif;
  color: #333333; /* Default dark text color for light body background */
  line-height: 1.6;
  background-color: #FFFFFF; /* Explicitly set for clarity, though body is white */
}

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

.page-contact__section-title {
  font-size: 36px;
  color: #26A9E0; /* Primary color for titles */
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
}

.page-contact__section-description {
  font-size: 18px;
  color: #555555;
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px;
}

/* --- Hero Section --- */
.page-contact__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 20px;
  padding-top: var(--header-offset, 120px); /* Ensure space for fixed header */
  background: linear-gradient(135deg, #e0f2f7, #ffffff); /* Light gradient background */
  overflow: hidden;
}

.page-contact__hero-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.page-contact__hero-image {
  width: 100%;
  margin-bottom: 30px;
  max-width: 800px; /* Constrain image width within hero */
}

.page-contact__hero-image img {
  width: 100%;
  height: auto;
  max-width: 100%;
  display: block;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.page-contact__hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
}

.page-contact__hero-title {
  font-size: 48px;
  color: #26A9E0;
  margin-bottom: 15px;
  line-height: 1.2;
  font-weight: bold;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-contact__hero-description {
  font-size: 20px;
  color: #555555;
  margin-bottom: 30px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

/* --- Buttons --- */
.page-contact__cta-button,
.page-contact__btn-primary,
.page-contact__btn-secondary {
  display: inline-block;
  padding: 15px 40px;
  text-decoration: none;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  transition: all 0.3s ease;
  cursor: pointer;
  border: none;
  box-sizing: border-box; /* Ensure padding doesn't increase total width */
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow long words to break */
}

.page-contact__cta-button {
  background: #26A9E0;
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(38, 169, 224, 0.3);
}

.page-contact__cta-button:hover {
  background: #1e87c0;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(38, 169, 224, 0.4);
}

.page-contact__btn-primary {
  background: #26A9E0;
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(38, 169, 224, 0.3);
}

.page-contact__btn-primary:hover {
  background: #1e87c0;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(38, 169, 224, 0.4);
}

.page-contact__btn-secondary {
  background: #ffffff;
  color: #26A9E0;
  border: 2px solid #26A9E0;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  margin-left: 20px;
}

.page-contact__btn-secondary:hover {
  background: #f0f8ff;
  color: #1e87c0;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(38, 169, 224, 0.2);
}

/* --- Contact Info Section --- */
.page-contact__info-section {
  padding: 80px 0;
  background-color: #f8fcfd; /* Light background for contrast */
}

.page-contact__contact-methods {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.page-contact__method-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #e0e0e0;
}

.page-contact__method-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.page-contact__method-card img {
  width: 100%; /* Ensure image fills card width */
  max-width: 250px; /* Max width for smaller images */
  height: auto;
  display: block;
  margin: 0 auto 20px;
  object-fit: cover;
  border-radius: 8px;
  min-width: 200px; /* Minimum size requirement */
  min-height: 200px;
}

.page-contact__method-title {
  font-size: 24px;
  color: #26A9E0;
  margin-bottom: 10px;
}

.page-contact__method-text {
  font-size: 16px;
  color: #666666;
  margin-bottom: 20px;
}

.page-contact__method-link {
  color: #26A9E0;
  text-decoration: none;
  font-weight: bold;
  font-size: 16px;
  transition: color 0.3s ease;
}

.page-contact__method-link:hover {
  color: #1e87c0;
  text-decoration: underline;
}

/* --- Contact Form Section --- */
.page-contact__form-section {
  padding: 80px 0;
  background-color: #26A9E0; /* Primary color background */
  color: #ffffff; /* White text for dark background */
}

.page-contact__form-section .page-contact__section-title,
.page-contact__form-section .page-contact__section-description {
  color: #ffffff;
}

.page-contact__contact-form {
  max-width: 700px;
  margin: 50px auto 0;
  background: #ffffff;
  padding: 40px;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

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

.page-contact__form-label {
  display: block;
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 8px;
  color: #333333; /* Dark text for form labels on white background */
}

.page-contact__form-input,
.page-contact__form-textarea {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid #cccccc;
  border-radius: 8px;
  font-size: 16px;
  color: #333333;
  box-sizing: border-box;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.page-contact__form-input:focus,
.page-contact__form-textarea:focus {
  border-color: #26A9E0;
  box-shadow: 0 0 0 3px rgba(38, 169, 224, 0.2);
  outline: none;
}

.page-contact__form-textarea {
  resize: vertical;
  min-height: 120px;
}

.page-contact__submit-button {
  width: 100%;
  padding: 15px 20px;
  font-size: 20px;
  font-weight: bold;
  border-radius: 8px;
  background: #EA7C07; /* Custom color for login/submit */
  color: #ffffff;
  cursor: pointer;
  border: none;
  transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.page-contact__submit-button:hover {
  background: #d46f06;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(234, 124, 7, 0.4);
}

/* --- FAQ Section --- */
.page-contact__faq-section {
  padding: 80px 0;
  background-color: #f8fcfd;
}

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

/* FAQ容器样式 */
.page-contact__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* FAQ默认状态 - 答案隐藏 */
.page-contact__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
  padding: 0 20px; /* Adjusted padding for better visual */
  opacity: 0;
  color: #555555;
}

/* FAQ展开状态 - 🚨 Sử dụng !important và max-height đủ lớn để đảm bảo nó có thể mở rộng */
.page-contact__faq-item.active .page-contact__faq-answer {
  max-height: 2000px !important; /* 🚨 Sử dụng !important để đảm bảo độ ưu tiên, giá trị đủ lớn để chứa mọi nội dung */
  padding: 20px !important; /* Adjusted padding for better visual */
  opacity: 1;
  background: #ffffff;
  border-top: 1px solid #e0e0e0;
  border-radius: 0 0 8px 8px;
}

/* Vấn đề kiểu dáng */
.page-contact__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  position: relative;
}

.page-contact__faq-item.active .page-contact__faq-question {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  border-color: #26A9E0; /* Highlight active question */
}

.page-contact__faq-question:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.page-contact__faq-question:active {
  background: #eeeeee;
}

/* Kiểu dáng tiêu đề câu hỏi */
.page-contact__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  color: #333333;
  pointer-events: none; /* Ngăn thẻ h3 chặn sự kiện nhấp chuột */
}

/* Chuyển đổi biểu tượng */
.page-contact__faq-toggle {
  font-size: 28px; /* Slightly larger for better visibility */
  font-weight: bold;
  line-height: 1;
  color: #26A9E0; /* Primary color for toggle icon */
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Ngăn biểu tượng chặn sự kiện nhấp chuột */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; /* Increased size */
  height: 32px; /* Increased size */
  background-color: #e0f2f7; /* Light background for icon */
  border-radius: 50%;
}

.page-contact__faq-item.active .page-contact__faq-toggle {
  color: #ffffff; /* White icon on primary color background when active */
  background-color: #26A9E0;
  transform: rotate(180deg); /* Rotate for minus sign visual */
}

/* --- Call to Action Section --- */
.page-contact__cta-section {
  padding: 80px 0;
  background: linear-gradient(90deg, #26A9E0, #1e87c0); /* Gradient background */
  text-align: center;
  color: #ffffff;
}

.page-contact__cta-content {
  max-width: 900px;
  margin: 0 auto;
}

.page-contact__cta-title {
  font-size: 40px;
  color: #ffffff;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-contact__cta-description {
  font-size: 20px;
  color: #e0f2f7;
  margin-bottom: 40px;
}

.page-contact__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px; /* Space between buttons */
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
  .page-contact__hero-title {
    font-size: 40px;
  }
  .page-contact__section-title {
    font-size: 32px;
  }
  .page-contact__section-description {
    font-size: 17px;
  }
}

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

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

  .page-contact__section-title {
    font-size: 28px;
    margin-bottom: 15px;
  }

  .page-contact__section-description {
    font-size: 16px;
    margin-bottom: 30px;
  }

  /* Hero Section */
  .page-contact__hero-section {
    padding-top: var(--header-offset, 120px) !important; /* Mobile header offset */
    padding-bottom: 40px;
  }

  .page-contact__hero-title {
    font-size: 32px;
  }

  .page-contact__hero-description {
    font-size: 18px;
  }

  .page-contact__hero-image img {
    border-radius: 4px;
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  /* Contact Methods Section */
  .page-contact__info-section,
  .page-contact__form-section,
  .page-contact__faq-section,
  .page-contact__cta-section {
    padding: 50px 0;
  }

  .page-contact__contact-methods {
    grid-template-columns: 1fr; /* Single column for mobile */
    gap: 20px;
  }

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

  .page-contact__method-card img {
     /* Smaller image in card for mobile */
    min-
    min-
    margin-bottom: 15px;
  }

  .page-contact__method-title {
    font-size: 20px;
  }

  .page-contact__method-text {
    font-size: 15px;
  }

  /* Contact Form */
  .page-contact__contact-form {
    padding: 30px 20px;
    margin-top: 30px;
  }

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

  .page-contact__submit-button {
    font-size: 18px;
    padding: 12px 15px;
  }

  /* FAQ Section */
  .page-contact__faq-question {
    padding: 15px;
  }
  
  .page-contact__faq-question h3 {
    font-size: 16px;
    width: calc(100% - 40px); /* Adjust width for toggle */
  }
  
  .page-contact__faq-toggle {
    margin-left: 10px;
    width: 28px;
    height: 28px;
    font-size: 24px;
  }
  
  .page-contact__faq-answer {
    padding: 0 15px;
  }
  
  .page-contact__faq-item.active .page-contact__faq-answer {
    padding: 15px !important;
  }

  /* CTA Section */
  .page-contact__cta-title {
    font-size: 30px;
  }

  .page-contact__cta-description {
    font-size: 18px;
    margin-bottom: 30px;
  }

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

  .page-contact__cta-button,
  .page-contact__btn-primary,
  .page-contact__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-contact__btn-secondary {
    margin-top: 10px;
  }

  /* Ensure all images and containers are responsive */
  .page-contact img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-contact__section,
  .page-contact__card,
  .page-contact__container,
  .page-contact__contact-form,
  .page-contact__faq-list,
  .page-contact__cta-content {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    /* Adding padding to sections/containers to prevent content from touching edges */
    padding-left: 15px;
    padding-right: 15px;
  }
  /* Override section padding to ensure full width use and then apply inner container padding */
  .page-contact__info-section,
  .page-contact__form-section,
  .page-contact__faq-section,
  .page-contact__cta-section {
    padding-left: 0;
    padding-right: 0;
  }
}

/* Ensure no CSS filters are used on images */
.page-contact img {
  filter: none !important;
}

/* Contrast fix if needed (though already covered by explicit colors) */
.page-contact__contrast-fix {
  background: #ffffff !important;
  color: #333333 !important;
  border: 1px solid #e0e0e0 !important;
}

.page-contact__text-contrast-fix {
  color: #333333 !important;
  text-shadow: none !important;
}