/* style/support.css */

:root {
    --primary-color: #26A9E0;
    --secondary-color: #007bff; /* A slightly darker blue for hover/active states */
    --text-color-dark: #333333;
    --text-color-light: #ffffff;
    --background-light: #f8f9fa;
    --background-dark: #26A9E0;
    --border-color: #e0e0e0;
}

.page-support {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color-dark);
    background: var(--background-light);
}

/* Fixed header offset */
.page-support{
    padding-top: var(--header-offset, 120px);
}

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

.page-support__section-title {
    font-size: 2.5em;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
}

.page-support__section-title--white {
    color: var(--text-color-light);
}

.page-support__section-description {
    font-size: 1.1em;
    text-align: center;
    margin-bottom: 40px;
    color: var(--text-color-dark);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.page-support__section-description--white {
    color: rgba(255, 255, 255, 0.9);
}

/* Hero Section */
.page-support__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  background: linear-gradient(135deg, var(--primary-color), #4CAF50); /* Gradient with brand color */
  color: var(--text-color-light);
}

.page-support__hero-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1; /* Ensure content is above any potential background overlays */
}

.page-support__hero-image {
  width: 100%;
  margin-bottom: 30px;
}

.page-support__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.2);
}

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

.page-support__hero-title {
    font-size: 3.5em;
    margin-bottom: 15px;
    color: var(--text-color-light);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.page-support__hero-description {
    font-size: 1.3em;
    margin-bottom: 30px;
    color: rgba(255, 255, 255, 0.9);
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-support__cta-button {
  display: inline-block;
  padding: 15px 40px;
  background: #EA7C07; /* Login color for CTA */
  color: #ffffff;
  text-decoration: none;
  border-radius: 5px;
  font-size: 18px;
  font-weight: bold;
  margin-top: 30px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-support__cta-button:hover {
  background: #d66b00; /* Slightly darker orange */
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

/* Intro Section */
.page-support__intro-section {
    padding: 80px 0;
    background: var(--background-light);
}

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

.page-support__feature-item {
    background: #ffffff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-support__feature-item img {
    width: 100%;
    height: auto;
    max-width: 100%;
    border-radius: 6px;
    margin-bottom: 20px;
    object-fit: cover;
}

.page-support__feature-title {
    font-size: 1.5em;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.page-support__feature-text {
    font-size: 1em;
    color: var(--text-color-dark);
}

/* FAQ Section */
.page-support__faq-section {
    padding: 80px 0;
    background: var(--background-dark);
}

.page-support__faq-list {
    max-width: 900px;
    margin: 0 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, opacity 0.4s ease;
  padding: 0 15px;
  opacity: 0;
}

/* FAQ展开状态 - 🚨 使用!important和足够大的max-height确保一定能展开 */
.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: #f9f9f9;
  border-radius: 0 0 5px 5px;
  color: var(--text-color-dark);
}

/* 问题样式 */
.page-support__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #fff;
  border: 1px solid var(--border-color);
  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;
}

/* 问题标题样式 */
.page-support__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none; /* 防止h3标签阻止点击事件 */
  color: var(--text-color-dark);
}

/* 切换图标 */
.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; /* 防止图标阻止点击事件 */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

.page-support__faq-item.active .page-support__faq-toggle {
  color: var(--primary-color);
  transform: rotate(45deg);
}

/* Guides Section */
.page-support__guides-section {
    padding: 80px 0;
    background: var(--background-light);
}

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

.page-support__guide-card {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-support__guide-card img {
    width: 100%;
    height: 220px; /* Fixed height for consistency */
    object-fit: cover;
    display: block;
}

.page-support__guide-card-content {
    padding: 25px;
}

.page-support__guide-title {
    font-size: 1.4em;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.page-support__guide-title a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-support__guide-title a:hover {
    color: var(--secondary-color);
}

.page-support__guide-text {
    font-size: 0.95em;
    color: var(--text-color-dark);
    margin-bottom: 20px;
}

.page-support__guide-link {
    display: inline-block;
    padding: 10px 20px;
    background: var(--primary-color);
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    font-size: 0.9em;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.page-support__guide-link:hover {
    background: var(--secondary-color);
}

/* Contact Section */
.page-support__contact-section {
    padding: 80px 0;
    background: var(--background-dark);
}

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

.page-support__contact-item {
    background: #ffffff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    text-align: center;
    color: var(--text-color-dark);
}

.page-support__contact-item img {
    
    
    object-fit: contain;
    margin-bottom: 20px;
}

.page-support__contact-title {
    font-size: 1.6em;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.page-support__contact-text {
    font-size: 1em;
    margin-bottom: 25px;
}

.page-support__btn-secondary {
  display: inline-block;
  padding: 12px 25px;
  background: #ffffff;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
  text-decoration: none;
  border-radius: 5px;
  font-size: 1em;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.page-support__btn-secondary:hover {
  background: var(--primary-color);
  color: #ffffff;
  border-color: var(--primary-color);
}

/* Global image responsiveness */
.page-support img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .page-support {
        font-size: 15px;
        line-height: 1.5;
    }

    /* Fixed header offset for mobile */
    .page-support {
        padding-top: var(--header-offset, 120px) !important;
    }

    .page-support__container {
        padding: 15px;
    }

    .page-support__hero-section {
        padding: 40px 15px;
    }

    .page-support__hero-title {
        font-size: 2.2em;
    }

    .page-support__hero-description {
        font-size: 1em;
    }

    .page-support__cta-button {
        padding: 12px 30px;
        font-size: 16px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    .page-support__section-title {
        font-size: 2em;
    }

    .page-support__section-description {
        font-size: 0.95em;
    }

    .page-support__intro-section, .page-support__faq-section, .page-support__guides-section, .page-support__contact-section {
        padding: 40px 0;
    }

    .page-support__features-grid, .page-support__guides-grid, .page-support__contact-methods {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-support__feature-item, .page-support__guide-card, .page-support__contact-item {
        padding: 20px;
    }

    .page-support__feature-item img, .page-support__guide-card img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }
    
    /* FAQ Mobile */
    .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;
    }

    .page-support__btn-secondary {
        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-support__guide-link {
        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;
    }
}

/* Ensure all images within page-support are responsive and do not cause overflow */
.page-support__section, .page-support__card, .page-support__container, .page-support__features-grid, .page-support__guides-grid, .page-support__contact-methods {
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
}

/* Specific overrides for mobile to prevent overflow */
@media (max-width: 768px) {
    .page-support__section, .page-support__card, .page-support__container, .page-support__features-grid, .page-support__guides-grid, .page-support__contact-methods {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    /* Ensure all images directly inside content areas are responsive */
    .page-support__intro-section img, .page-support__faq-section img, .page-support__guides-section img, .page-support__contact-section img {
        max-width: 100% !important;
        height: auto !important;
        width: 100% !important;
        object-fit: cover;
    }
}