/* style/gift-code.css */
:root {
    --primary-color: #0A2463;
    --secondary-color: #FFD700;
    --dark-bg-1: #0d0d0d; /* Giả định từ shared.css */
    --text-color-light: #ffffff;
    --text-color-dark: #333333;
    --border-color: #e0e0e0;
}

.page-gift-code {
    font-family: 'Arial', sans-serif;
    color: var(--text-color-light); /* Mặc định text màu sáng vì body là nền tối */
    background-color: var(--dark-bg-1);
}

.page-gift-code__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    padding-top: 120px; /* Đảm bảo nội dung không bị che bởi header cố định */
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-color-light);
}

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

.page-gift-code__hero-image {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
    border-radius: 8px;
    object-fit: cover;
    margin-bottom: 30px;
}

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

.page-gift-code__main-title {
    font-size: 42px;
    font-weight: bold;
    margin-bottom: 20px;
    line-height: 1.2;
    color: var(--text-color-light);
}

.page-gift-code__hero-description {
    font-size: 20px;
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    color: var(--text-color-light);
}

.page-gift-code__cta-button {
    display: inline-block;
    padding: 15px 40px;
    background: var(--primary-color);
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    font-size: 18px;
    font-weight: bold;
    margin-top: 30px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.page-gift-code__cta-button:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-gift-code__section {
    padding: 60px 20px;
    background-color: var(--dark-bg-1); /* Mặc định nền tối */
    color: var(--text-color-light);
}

.page-gift-code__section.page-gift-code__light-bg {
    background-color: #f1f3f5; /* Nền sáng cho các section cụ thể */
    color: var(--text-color-dark);
}

.page-gift-code__section a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-gift-code__section a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

.page-gift-code__container {
    max-width: 1200px;
    margin: 0 auto;
    box-sizing: border-box;
}

.page-gift-code__section-title {
    font-size: 36px;
    font-weight: bold;
    text-align: center;
    margin-bottom: 40px;
    color: inherit;
}

.page-gift-code__text-block {
    font-size: 16px;
    line-height: 1.7;
    margin-bottom: 20px;
    color: inherit;
}

.page-gift-code__image-wrapper {
    text-align: center;
    margin-bottom: 40px;
}

.page-gift-code__content-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-gift-code__list {
    list-style: disc inside;
    margin-bottom: 20px;
    padding-left: 20px;
    color: inherit;
}

.page-gift-code__ordered-list {
    list-style: decimal inside;
    margin-bottom: 20px;
    padding-left: 20px;
    color: inherit;
}

.page-gift-code__list-item {
    font-size: 16px;
    line-height: 1.7;
    margin-bottom: 10px;
    color: inherit;
}

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

.page-gift-code__card {
    background: #ffffff;
    color: var(--text-color-dark);
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 30px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--border-color);
}

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

.page-gift-code__card-title {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.page-gift-code__card-description {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-color-dark);
}

/* FAQ Section */
.page-gift-code__faq-section {
    background-color: #f1f3f5; /* Nền sáng */
    color: var(--text-color-dark);
}

.page-gift-code__faq-item {
    margin-bottom: 15px;
    border-radius: 5px;
    overflow: hidden;
}

.page-gift-code__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;
}

.page-gift-code__faq-item.active .page-gift-code__faq-answer {
    max-height: 2000px !important;
    padding: 20px 15px !important;
    opacity: 1;
    background: #f9f9f9;
    border-radius: 0 0 5px 5px;
}

.page-gift-code__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-gift-code__faq-question:hover {
    background: #f5f5f5;
    border-color: #d0d0d0;
}

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

.page-gift-code__faq-question h3 {
    margin: 0;
    padding: 0;
    flex: 1;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.5;
    pointer-events: none;
    color: var(--text-color-dark);
}

.page-gift-code__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-gift-code__faq-item.active .page-gift-code__faq-toggle {
    color: var(--primary-color);
    transform: rotate(45deg); /* Thay đổi dấu + thành X */
}

/* News Section */
.page-gift-code__news-section {
    background-color: var(--dark-bg-1);
    color: var(--text-color-light);
}

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

.page-gift-code__news-card {
    background: #1a1a1a; /* Nền tối cho card tin tức */
    color: var(--text-color-light);
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    padding: 25px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

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

.page-gift-code__news-title {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 10px;
    line-height: 1.4;
}

.page-gift-code__news-title a {
    color: var(--text-color-light);
    text-decoration: none;
}

.page-gift-code__news-title a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

.page-gift-code__news-excerpt {
    font-size: 15px;
    line-height: 1.6;
    color: #cccccc;
    margin-bottom: 15px;
}

.page-gift-code__read-more {
    display: inline-block;
    font-size: 15px;
    font-weight: bold;
    color: var(--secondary-color);
    text-decoration: none;
}

.page-gift-code__read-more:hover {
    text-decoration: underline;
    color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-gift-code__main-title {
        font-size: 36px;
    }
    .page-gift-code__hero-description {
        font-size: 18px;
    }
    .page-gift-code__section-title {
        font-size: 30px;
    }
    .page-gift-code__text-block, .page-gift-code__list-item {
        font-size: 15px;
    }
    .page-gift-code__card-title {
        font-size: 20px;
    }
}

@media (max-width: 768px) {
    .page-gift-code__hero-section {
        padding-top: 100px !important; /* Mobile padding-top override */
        padding-bottom: 40px;
    }
    .page-gift-code__main-title {
        font-size: 28px;
    }
    .page-gift-code__hero-description {
        font-size: 16px;
    }
    .page-gift-code__cta-button {
        padding: 12px 30px;
        font-size: 16px;
        margin-top: 20px;
    }
    .page-gift-code__section {
        padding: 40px 15px;
    }
    .page-gift-code__section-title {
        font-size: 26px;
        margin-bottom: 30px;
    }
    .page-gift-code__text-block, .page-gift-code__list-item, .page-gift-code__card-description, .page-gift-code__news-excerpt {
        font-size: 14px;
        line-height: 1.6;
    }
    .page-gift-code__card-grid, .page-gift-code__news-grid {
        gap: 20px;
    }
    .page-gift-code__card, .page-gift-code__news-card {
        padding: 20px;
    }
    .page-gift-code__card-title {
        font-size: 18px;
    }
    .page-gift-code__news-title {
        font-size: 17px;
    }
    .page-gift-code__faq-question {
        padding: 15px;
        flex-wrap: wrap;
    }
    .page-gift-code__faq-question h3 {
        font-size: 15px;
        margin-bottom: 0;
        width: calc(100% - 40px);
    }
    .page-gift-code__faq-toggle {
        margin-left: 10px;
        width: 24px;
        height: 24px;
        font-size: 20px;
    }
    .page-gift-code__faq-answer {
        padding: 0 15px;
    }
    .page-gift-code__faq-item.active .page-gift-code__faq-answer {
        padding: 15px !important;
    }
    /* 强制图片响应式 */
    .page-gift-code img {
      max-width: 100% !important;
      width: 100% !important;
      height: auto !important;
    }
    .page-gift-code__section,
    .page-gift-code__card,
    .page-gift-code__container {
      max-width: 100% !important;
      width: 100% !important;
      box-sizing: border-box !important;
      padding-left: 15px;
      padding-right: 15px;
    }
}

@media (max-width: 480px) {
    .page-gift-code__main-title {
        font-size: 24px;
    }
    .page-gift-code__hero-description {
        font-size: 14px;
    }
    .page-gift-code__cta-button {
        padding: 10px 25px;
        font-size: 14px;
    }
    .page-gift-code__section-title {
        font-size: 22px;
    }
    .page-gift-code__text-block, .page-gift-code__list-item, .page-gift-code__card-description, .page-gift-code__news-excerpt {
        font-size: 13px;
    }
    .page-gift-code__card-title {
        font-size: 16px;
    }
    .page-gift-code__news-title {
        font-size: 15px;
    }
}