/* style/support.css */

/* Variables and base styles for page-support */
.page-support {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333333; /* Default dark text for light body background */
    background-color: var(--dark-bg, #0d0d0d); /* Assuming shared --dark-bg is dark */
}

/* Ensure main content area respects header offset */
.page-support__hero-section {
    position: relative;
    width: 100%;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-size: cover;
    background-position: center;
    color: #ffffff; /* Light text for dark hero background */
    padding-top: var(--header-offset, 120px); /* Ensures content is below fixed header */
    padding-bottom: 80px;
    overflow: hidden; /* Prevent background image overflow */
}

.page-support__hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6); /* Dark overlay for text readability */
    z-index: 1;
}

.page-support__hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

.page-support__main-title {
    font-size: 3.5em;
    margin-bottom: 20px;
    font-weight: bold;
    color: #FFCC00; /* Auxiliary color for emphasis */
    line-height: 1.2;
}

.page-support__description {
    font-size: 1.2em;
    margin-bottom: 40px;
    color: #f0f0f0;
}

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

.page-support__cta-button {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1em;
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    white-space: normal; /* Allow text wrapping */
    word-wrap: break-word; /* Ensure text breaks */
    max-width: 100%; /* Ensure button doesn't overflow */
    box-sizing: border-box;
}

.page-support__cta-button--primary {
    background-color: #FFCC00; /* Auxiliary color */
    color: #003366; /* Primary color for text */
    border: 2px solid #FFCC00;
}

.page-support__cta-button--primary:hover {
    background-color: #e6b800;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.page-support__cta-button--secondary {
    background-color: #003366; /* Primary color */
    color: #FFCC00; /* Auxiliary color for text */
    border: 2px solid #FFCC00;
}

.page-support__cta-button--secondary:hover {
    background-color: #002244;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

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

.page-support__section-title {
    font-size: 2.5em;
    font-weight: bold;
    text-align: center;
    margin-bottom: 20px;
    color: #003366; /* Primary color for titles */
}

.page-support__section-title--light {
    color: #FFCC00; /* Auxiliary color for titles on dark backgrounds */
}

.page-support__section-intro {
    font-size: 1.1em;
    text-align: center;
    max-width: 800px;
    margin: 0 auto 50px auto;
    color: #555555;
}

/* Channels Section */
.page-support__channels-section {
    padding: 80px 0;
    background-color: #f8f9fa;
}

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

.page-support__channel-card {
    background: #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, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
}

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

.page-support__channel-icon {
    width: 200px; /* Min size 200x200 */
    height: 150px;
    object-fit: contain;
    margin-bottom: 25px;
}

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

.page-support__channel-description {
    font-size: 1em;
    color: #666666;
    margin-bottom: 25px;
    flex-grow: 1; /* Ensure description takes available space */
}

.page-support__channel-button {
    display: inline-block;
    padding: 12px 25px;
    background-color: #003366;
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s ease;
    white-space: normal;
    word-wrap: break-word;
    max-width: 100%;
    box-sizing: border-box;
}

.page-support__channel-button:hover {
    background-color: #002244;
}

/* Self-Help Section */
.page-support__self-help-section {
    padding: 80px 0;
    background-color: #ffffff;
}

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

.page-support__resource-card {
    background: #f0f8ff;
    border-left: 5px solid #003366;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-support__resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.12);
}

.page-support__resource-title {
    font-size: 1.4em;
    color: #003366;
    margin-bottom: 10px;
    font-weight: bold;
}

.page-support__resource-description {
    font-size: 0.95em;
    color: #666666;
    margin-bottom: 20px;
}

.page-support__resource-link {
    display: inline-block;
    color: #003366;
    text-decoration: none;
    font-weight: bold;
    border-bottom: 2px solid #FFCC00;
    padding-bottom: 3px;
    transition: color 0.3s ease, border-color 0.3s ease;
}

.page-support__resource-link:hover {
    color: #002244;
    border-color: #e6b800;
}

.page-support__view-all-resources {
    text-align: center;
    margin-top: 50px;
}

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

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

/* FAQ容器样式 */
.page-support__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
}

/* FAQ默认状态 - 答案隐藏 */
.page-support__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease;
  padding: 0 15px;
  opacity: 0;
}

/* FAQ展开状态 - 🚨 使用!important và đủ lớn max-height để đảm bảo có thể mở rộng */
.page-support__faq-item.active .page-support__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 15px !important;
  opacity: 1;
  background: #f0f8ff; /* Light blue background for answer */
  border-radius: 0 0 5px 5px;
  color: #333333;
}

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

.page-support__faq-question:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
}

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

/* Vấn đề tiêu đề kiểu dáng */
.page-support__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none; /* Ngăn chặn thẻ h3 chặn sự kiện nhấp */
  color: #003366; /* Primary color for FAQ question */
}

/* Chuyển đổi biểu tượng */
.page-support__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: #666;
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Ngăn chặn biểu tượng chặn sự kiện nhấp */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

.page-support__faq-item.active .page-support__faq-toggle {
  color: #003366; /* Primary color for active toggle */
  transform: rotate(45deg); /* Optional: rotate to form an 'X' */
}

/* Commitment Section */
.page-support__commitment-section {
    padding: 80px 0;
    background-color: #003366; /* Primary color background */
    color: #ffffff; /* Light text for dark background */
}

.page-support__commitment-section .page-support__section-title {
    color: #FFCC00; /* Auxiliary color for title on dark background */
}

.page-support__commitment-section .page-support__section-intro {
    color: #f0f0f0;
}

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

.page-support__commitment-item {
    background: rgba(255, 255, 255, 0.1); /* Semi-transparent white background */
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, background 0.3s ease;
}

.page-support__commitment-item:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.15);
}

.page-support__commitment-icon {
    width: 200px; /* Min size 200x200 */
    height: 150px;
    object-fit: contain;
    margin-bottom: 25px;
}

.page-support__commitment-title {
    font-size: 1.5em;
    color: #FFCC00; /* Auxiliary color for titles */
    margin-bottom: 15px;
    font-weight: bold;
}

.page-support__commitment-description {
    font-size: 1em;
    color: #f0f0f0;
}

/* Final CTA Section */
.page-support__final-cta-section {
    padding: 80px 0;
    background-color: #222222; /* Dark background for emphasis */
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-support__final-cta-image {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.3; /* Subtle background image */
    z-index: 0;
}

.page-support__final-cta-content {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
    color: #ffffff;
    padding: 20px;
}

.page-support__final-cta-content .page-support__section-title {
    margin-bottom: 20px;
}

.page-support__final-cta-content .page-support__description {
    margin-bottom: 40px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-support__main-title {
        font-size: 3em;
    }
    .page-support__section-title {
        font-size: 2em;
    }
}

@media (max-width: 768px) {
    .page-support__hero-section {
        padding-top: var(--header-offset, 120px) !important;
        min-height: 500px;
        padding-bottom: 60px;
    }

    .page-support__main-title {
        font-size: 2.5em;
    }
    .page-support__description {
        font-size: 1em;
        margin-bottom: 30px;
    }
    .page-support__cta-buttons {
        flex-direction: column;
        gap: 15px;
        padding: 0 15px; /* Add padding to buttons container */
    }
    .page-support__cta-button {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        padding: 12px 20px;
        font-size: 1em;
    }

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

    .page-support__channels-section,
    .page-support__self-help-section,
    .page-support__faq-section,
    .page-support__commitment-section,
    .page-support__final-cta-section {
        padding: 50px 0;
    }

    .page-support__channels-grid,
    .page-support__resource-grid,
    .page-support__commitment-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-top: 30px;
    }

    .page-support__channel-card,
    .page-support__resource-card,
    .page-support__commitment-item {
        padding: 25px;
    }

    .page-support__faq-list {
        margin-top: 30px;
    }

    /* FAQ mobile adjustments */
    .page-support__faq-question {
        padding: 15px;
        flex-wrap: wrap;
    }
    
    .page-support__faq-question h3 {
        font-size: 15px;
        margin-bottom: 0;
        width: calc(100% - 40px);
    }
    
    .page-support__faq-toggle {
        margin-left: 10px;
        width: 24px;
        height: 24px;
        font-size: 20px;
    }
    
    .page-support__faq-answer {
        padding: 0 15px;
    }
    
    .page-support__faq-item.active .page-support__faq-answer {
        padding: 15px !important;
    }

    /* Image responsive */
    .page-support img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    
    .page-support__hero-section,
    .page-support__channels-section,
    .page-support__self-help-section,
    .page-support__faq-section,
    .page-support__commitment-section,
    .page-support__final-cta-section,
    .page-support__container,
    .page-support__channels-grid,
    .page-support__resource-grid,
    .page-support__commitment-grid,
    .page-support__final-cta-content {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow: hidden !important;
    }
    .page-support__final-cta-image {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important; /* ensure image covers area */
    }

    /* Video (if any, although none used for support page) */
    .page-support video,
    .page-support__video {
      max-width: 100% !important;
      width: 100% !important;
      height: auto !important;
      display: block !important;
    }
    .page-support__video-section,
    .page-support__video-container,
    .page-support__video-wrapper {
      max-width: 100% !important;
      width: 100% !important;
      box-sizing: border-box !important;
      padding-left: 15px;
      padding-right: 15px;
      overflow: hidden !important;
    }
    .page-support__video-section {
      padding-top: var(--header-offset, 120px) !important;
    }
}

/* Base image styles to prevent filters */
.page-support img {
    filter: none; /* Ensure no CSS filters are applied */
}