/* style/support.css */

/* Base styles for the support page */
.page-support {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #ffffff; /* Default text color for dark body background */
    background-color: #1a1a1a; /* Matches body background for consistency */
}

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

/* Section styling */
.page-support__hero-section {
    position: relative;
    padding-top: var(--header-offset, 120px); /* Use header offset here if body padding is 0, otherwise 0 */
    padding-bottom: 60px;
    background: linear-gradient(135deg, #2C2F4C, #1a1a1a); /* Dark gradient */
    color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    overflow: hidden;
}

.page-support__hero-content {
    position: relative;
    z-index: 10;
    max-width: 800px;
    margin-bottom: 30px;
}

.page-support__hero-title {
    font-size: 3.2em;
    margin-bottom: 20px;
    color: #FFD700; /* Auxiliary color for emphasis */
    line-height: 1.2;
    font-weight: 700;
}

.page-support__hero-description {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: #f0f0f0;
}

.page-support__hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.page-support__hero-image {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 50%; /* Adjust as needed for visual balance */
    max-width: 700px;
    opacity: 0.2; /* Subtle background image */
    z-index: 1;
}

.page-support__hero-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    border-radius: 0; /* No specific radius */
    box-shadow: none; /* No shadow */
}

/* General section styling */
.page-support__section-title {
    font-size: 2.5em;
    color: #FFD700;
    text-align: center;
    margin-bottom: 20px;
    font-weight: 700;
}

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

/* Light background sections */
.page-support__light-bg {
    background-color: #f0f0f0; /* Light background for contrast */
    color: #333333; /* Dark text for light background */
}

.page-support__light-bg .page-support__section-title {
    color: #2C2F4C;
}

.page-support__light-bg .page-support__section-description {
    color: #555555;
}

/* Dark background sections */
.page-support__dark-bg {
    background-color: #2C2F4C; /* Brand primary color for dark sections */
    color: #ffffff;
}

/* Channels section */
.page-support__channels-section {
    padding: 80px 0;
}

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

.page-support__channel-card {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #ffffff;
}

.page-support__channel-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.page-support__channel-card img {
    width: 100%;
    max-width: 250px; /* Constrain image width */
    height: auto;
    margin-bottom: 20px;
    border-radius: 8px;
    object-fit: cover;
    border: none;
    box-shadow: none;
}

.page-support__card-title {
    font-size: 1.5em;
    color: #FFD700;
    margin-bottom: 15px;
    font-weight: 600;
}

.page-support__card-text {
    font-size: 1em;
    color: #f0f0f0;
    margin-bottom: 25px;
    flex-grow: 1;
}

/* FAQ section */
.page-support__faq-section {
    padding: 80px 0;
}

.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: rgba(255, 255, 255, 0.05); /* Slightly lighter background for answer */
    border-radius: 0 0 5px 5px;
    color: #f0f0f0;
}

/* Vấn đề phong cách */
.page-support__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 20px;
    background: #1a1a1a; /* Darker background for question */
    border: 1px solid rgba(255, 255, 255, 0.1);
    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: rgba(255, 255, 255, 0.05);
    border-color: #FFD700;
}

.page-support__faq-question:active {
    background: rgba(255, 255, 255, 0.1);
}

/* Vấn đề tiêu đề phong cách */
.page-support__faq-question h3 {
    margin: 0;
    padding: 0;
    flex: 1;
    font-size: 1.1em;
    font-weight: 600;
    line-height: 1.5;
    color: #ffffff;
    pointer-events: none; /* Ngăn thẻ h3 chặn sự kiện nhấp */
}

/* Chuyển đổi biểu tượng */
.page-support__faq-toggle {
    font-size: 24px;
    font-weight: bold;
    line-height: 1;
    color: #FFD700;
    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 */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 1px solid #FFD700;
    border-radius: 50%;
}

.page-support__faq-item.active .page-support__faq-toggle {
    color: #ffffff;
    background-color: #FFD700;
    border-color: #FFD700;
    transform: rotate(45deg); /* Xoay để tạo hiệu ứng dấu trừ */
}

/* Contact Form Section */
.page-support__contact-form-section {
    padding: 80px 0;
}

.page-support__contact-form {
    max-width: 700px;
    margin: 0 auto;
    background-color: #ffffff; /* White background for form */
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    color: #333333; /* Dark text for form */
}

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

.page-support__form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2C2F4C;
}

.page-support__form-input,
.page-support__form-textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    font-size: 1em;
    color: #333333;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

.page-support__form-input:focus,
.page-support__form-textarea:focus {
    border-color: #FFD700;
    outline: none;
}

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

/* Responsible Gaming Section */
.page-support__responsible-gaming-section {
    padding: 80px 0;
    text-align: center;
}

.page-support__responsible-gaming-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 50px;
    margin-top: 40px;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
}

.page-support__responsible-gaming-content img {
    max-width: 45%;
    height: auto;
    border-radius: 10px;
    object-fit: cover;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.page-support__responsible-gaming-list {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
    max-width: 45%;
}

.page-support__responsible-gaming-list li {
    background-color: rgba(255, 255, 255, 0.08);
    margin-bottom: 15px;
    padding: 15px 20px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    color: #f0f0f0;
    font-size: 1.05em;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.page-support__responsible-gaming-list li p {
    margin: 0;
}

.page-support__responsible-gaming-list li::before {
    content: '✅';
    margin-right: 15px;
    font-size: 1.2em;
    color: #FFD700;
}

/* Buttons */
.page-support__btn-primary,
.page-support__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.05em;
    transition: all 0.3s ease;
    text-align: center;
    box-sizing: border-box; /* Crucial for responsiveness */
    max-width: 100%; /* Crucial for responsiveness */
    white-space: normal; /* Allow text wrap */
    word-wrap: break-word; /* Allow text wrap */
}

.page-support__btn-primary {
    background-color: #FFD700;
    color: #2C2F4C;
    border: 2px solid #FFD700;
}

.page-support__btn-primary:hover {
    background-color: #e6c200;
    border-color: #e6c200;
    transform: translateY(-3px);
}

.page-support__btn-secondary {
    background-color: transparent;
    color: #FFD700;
    border: 2px solid #FFD700;
}

.page-support__btn-secondary:hover {
    background-color: #FFD700;
    color: #2C2F4C;
    transform: translateY(-3px);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-support__hero-title {
        font-size: 2.8em;
    }
    .page-support__section-title {
        font-size: 2em;
    }
    .page-support__hero-image {
        width: 60%;
    }
    .page-support__responsible-gaming-content {
        gap: 30px;
    }
    .page-support__responsible-gaming-content img,
    .page-support__responsible-gaming-list {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    /* Fixed header offset handling */
    .page-support__hero-section {
        padding-top: var(--header-offset, 120px) !important; /* Ensure it applies if shared.css doesn't set body padding */
    }

    .page-support__container {
        padding: 30px 15px;
    }

    .page-support__hero-title {
        font-size: 2em;
    }
    .page-support__hero-description {
        font-size: 1em;
    }
    .page-support__hero-buttons {
        flex-direction: column;
        gap: 15px;
        width: 100%;
        padding: 0 15px;
        box-sizing: border-box;
    }
    .page-support__hero-image {
        position: relative;
        width: 80%;
        margin-top: 30px;
        opacity: 0.3;
    }
    .page-support__hero-image img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }

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

    .page-support__channels-grid {
        grid-template-columns: 1fr;
    }

    .page-support__channel-card img {
        max-width: 200px;
    }

    .page-support__faq-question {
        padding: 15px;
        flex-wrap: wrap;
    }
    
    .page-support__faq-question h3 {
        font-size: 1em;
        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__contact-form {
        padding: 25px;
    }

    .page-support__responsible-gaming-content {
        flex-direction: column;
        gap: 20px;
    }
    .page-support__responsible-gaming-content img,
    .page-support__responsible-gaming-list {
        max-width: 100%;
        width: 100%; /* Ensure full width on mobile */
    }
    .page-support__responsible-gaming-list li {
        font-size: 1em;
        padding: 12px 15px;
    }

    /* Mobile specific image and button rules */
    .page-support img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }
    
    .page-support__hero-section,
    .page-support__channels-section,
    .page-support__faq-section,
    .page-support__contact-form-section,
    .page-support__responsible-gaming-section {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    .page-support__btn-primary,
    .page-support__btn-secondary,
    .page-support a[class*="button"],
    .page-support a[class*="btn"] {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding-left: 15px; /* Adjust padding for better look on small screens */
        padding-right: 15px;
    }
    
    .page-support__hero-buttons,
    .page-support__button-group,
    .page-support__btn-container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        flex-wrap: wrap !important;
        gap: 10px;
        flex-direction: column; /* Ensure vertical stacking for multiple buttons */
    }
}