/* style/contact.css */

/* --- Base Page Styles --- */
.page-contact {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333333; /* Default dark text for light body background */
    background-color: #ffffff; /* Explicitly set to match body for clarity */
}

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

.page-contact__section-title {
    font-size: 36px;
    font-weight: 700;
    color: #017439; /* Brand primary color for titles */
    text-align: center;
    margin-bottom: 20px;
    padding-top: 40px;
}

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

/* --- Hero Section --- */
.page-contact__hero-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    padding-top: var(--header-offset, 120px); /* Ensures content is not hidden by fixed header */
    background: linear-gradient(135deg, #e0ffe0, #ffffff); /* Light gradient for hero section */
    color: #333333;
}

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

.page-contact__hero-title {
    font-size: 48px;
    font-weight: 800;
    color: #017439;
    margin-bottom: 20px;
    line-height: 1.2;
}

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

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

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

.page-contact__cta-button {
    display: inline-block;
    padding: 15px 40px;
    text-decoration: none;
    border-radius: 8px;
    font-size: 20px;
    font-weight: bold;
    margin-top: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-contact__cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

/* Specific button colors from requirements */
.page-contact__btn-register {
    background: #C30808; /* Register button color */
    color: #FFFF00;     /* Register button text color */
    border: none;
}
.page-contact__btn-register:hover {
    background: #a30606; /* Slightly darker on hover */
}

/* --- Channels Section --- */
.page-contact__channels-section {
    padding: 80px 0;
    background-color: #f8f8f8; /* Light background for contrast */
}

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

.page-contact__channel-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

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

.page-contact__channel-icon {
    width: 100%; /* Max width for images */
    height: auto;
    max-width: 250px; /* Smaller max-width for these illustrations */
    margin-bottom: 25px;
    border-radius: 8px;
    object-fit: cover;
}

.page-contact__channel-title {
    font-size: 24px;
    font-weight: 700;
    color: #017439;
    margin-bottom: 15px;
}

.page-contact__channel-text {
    font-size: 16px;
    color: #666666;
    margin-bottom: 25px;
    flex-grow: 1; /* Allows text to take available space */
}

.page-contact__btn-primary {
    display: inline-block;
    padding: 12px 25px;
    background: #017439;
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: bold;
    transition: background-color 0.3s ease, transform 0.3s ease;
    border: none;
}

.page-contact__btn-primary:hover {
    background: #005f2f;
    transform: translateY(-2px);
}

.page-contact__social-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-top: 15px;
    width: 100%;
}

.page-contact__social-link {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    background: #f0f0f0;
    color: #333333;
    text-decoration: none;
    border-radius: 5px;
    font-size: 15px;
    font-weight: 600;
    transition: background-color 0.3s ease, color 0.3s ease;
    border: 1px solid #e0e0e0;
}

.page-contact__social-link:hover {
    background: #e0e0e0;
    color: #017439;
}

.page-contact__social-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-right: 8px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}
/* Placeholder for actual social icons - these would ideally be SVGs or icon fonts */
.page-contact__social-icon--facebook { background-color: #3b5998; border-radius: 3px; }
.page-contact__social-icon--telegram { background-color: #0088cc; border-radius: 3px; }
.page-contact__social-icon--zalo { background-color: #0080ff; border-radius: 3px; }


/* --- Info Section --- */
.page-contact__info-section {
    background-color: #017439; /* Brand primary color */
    color: #ffffff;
    padding: 80px 0;
}

.page-contact__info-section .page-contact__section-title {
    color: #ffffff;
}

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

.page-contact__info-box {
    background: rgba(255, 255, 255, 0.1); /* Semi-transparent white background */
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.page-contact__info-heading {
    font-size: 22px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 15px;
}

.page-contact__info-text {
    font-size: 16px;
    color: #e0e0e0;
}

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

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

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

/* 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.3s ease;
  padding: 0 20px; /* Adjusted padding */
  opacity: 0;
  color: #555555;
}

/* FAQ展开状态 - 🚨 使用!important和足够大的max-height确保一定能展开 */
.page-contact__faq-item.active .page-contact__faq-answer {
  max-height: 2000px !important; /* 🚨 Use !important for priority, value large enough */
  padding: 20px 20px !important; /* Adjusted padding */
  opacity: 1;
  background: #ffffff; /* White background for answer */
  border-radius: 0 0 8px 8px; /* Match item border-radius */
  border-top: 1px solid #e0e0e0; /* Separator line */
}

/* 问题样式 */
.page-contact__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px; /* Adjusted padding */
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px; /* Match item border-radius */
  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;
    background-color: #f5f5f5; /* Slightly different background when active */
}

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

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

/* 问题标题样式 */
.page-contact__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px; /* Larger font size */
  font-weight: 600;
  line-height: 1.5;
  color: #333333;
  pointer-events: none; /* Prevent h3 from blocking click events */
}

/* 切换图标 */
.page-contact__faq-toggle {
  font-size: 28px; /* Larger icon */
  font-weight: bold;
  line-height: 1;
  color: #017439; /* Brand color for toggle */
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Prevent icon from blocking click events */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; /* Larger toggle area */
  height: 32px;
}

.page-contact__faq-item.active .page-contact__faq-toggle {
  color: #C30808; /* Change color when active */
  transform: rotate(180deg); /* Rotate for minus sign effect */
}


/* --- Responsive Design (Mobile) --- */
@media (max-width: 768px) {
    .page-contact__hero-section {
        padding-top: var(--header-offset, 120px) !important; /* Mobile specific padding-top */
        padding-bottom: 40px;
        padding-left: 15px;
        padding-right: 15px;
    }

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

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

    .page-contact__cta-button {
        padding: 12px 25px;
        font-size: 16px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        margin-left: 0;
        margin-right: 0;
    }

    .page-contact__section-title {
        font-size: 28px;
        padding-top: 30px;
    }

    .page-contact__section-description {
        font-size: 15px;
        margin-bottom: 30px;
        padding: 0 15px;
    }

    .page-contact__channels-section,
    .page-contact__info-section,
    .page-contact__faq-section {
        padding: 50px 0;
    }

    .page-contact__container {
        padding: 0 15px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

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

    .page-contact__channel-card,
    .page-contact__info-box {
        padding: 25px;
    }

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

    .page-contact__info-heading {
        font-size: 20px;
    }

    .page-contact__btn-primary {
        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-contact__social-links {
        flex-direction: column;
        gap: 10px;
    }

    .page-contact__social-link {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    /* FAQ Mobile Styles */
    .page-contact__faq-question {
        padding: 15px;
        flex-wrap: wrap;
    }

    .page-contact__faq-question h3 {
        font-size: 15px;
        margin-bottom: 0;
        width: calc(100% - 40px);
    }

    .page-contact__faq-toggle {
        margin-left: 10px;
        width: 24px;
        height: 24px;
        font-size: 20px;
    }

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

    .page-contact__faq-item.active .page-contact__faq-answer {
        padding: 15px !important;
    }

    /* Images responsiveness */
    .page-contact img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }

    .page-contact__section,
    .page-contact__card,
    .page-contact__container,
    .page-contact__hero-container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
}

/* Ensure no filter on images */
.page-contact img {
    filter: none;
}