/* style/register.css */

/* Base styles for the page-register scope */
.page-register {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333333; /* Dark text for light background */
    background-color: var(--secondary-color); /* #FFFFFF */
}

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

.page-register__section-title {
    font-size: 36px;
    color: #26A9E0; /* Brand color for titles */
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
}

.page-register__section-description {
    font-size: 18px;
    text-align: center;
    margin-bottom: 40px;
    color: #555555;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Hero Section */
.page-register__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); /* Ensure space for fixed header */
    background: linear-gradient(135deg, #26A9E0, #FFFFFF); /* Blend brand colors */
    color: #ffffff; /* White text for gradient background */
}

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

.page-register__hero-image {
    width: 100%;
    margin-bottom: 30px;
    max-width: 1000px; /* Constrain image width */
}

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

.page-register__hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
    padding: 0 15px;
}

.page-register__hero-title {
    font-size: 48px;
    font-weight: bold;
    margin-bottom: 20px;
    color: #ffffff;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.page-register__hero-description {
    font-size: 22px;
    margin-bottom: 40px;
    color: #f0f0f0;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-register__cta-button {
    display: inline-block;
    padding: 18px 45px;
    background: #EA7C07; /* Login button color */
    color: #ffffff;
    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);
    border: none;
}

.page-register__cta-button:hover {
    background: #D26E06; /* Darkened #EA7C07 */
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* Intro Section */
.page-register__intro-section {
    padding: 80px 0;
    background-color: #FFFFFF; /* Light background */
    color: #333333;
}

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

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

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

.page-register__feature-item img {
    width: 100%;
    max-width: 250px; /* Constrain image size within feature item */
    height: auto;
    margin-bottom: 20px;
    border-radius: 8px;
}

.page-register__feature-title {
    font-size: 24px;
    color: #26A9E0;
    margin-bottom: 15px;
}

.page-register__feature-text {
    font-size: 16px;
    color: #666666;
}

/* Form Section */
.page-register__form-section {
    padding: 80px 0;
    background-color: #26A9E0; /* Brand color as background */
    color: #ffffff; /* White text for brand color background */
}

.page-register__form-section .page-register__section-title,
.page-register__form-section .page-register__section-description {
    color: #ffffff;
}

.page-register__registration-form {
    max-width: 600px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.15); /* Slightly transparent white for form background */
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.page-register__form-group {
    margin-bottom: 25px;
}

.page-register__form-label {
    display: block;
    margin-bottom: 10px;
    font-size: 16px;
    font-weight: bold;
    color: #ffffff;
}

.page-register__form-input {
    width: calc(100% - 20px);
    padding: 15px 10px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.1);
    color: #ffffff;
    font-size: 16px;
    transition: border-color 0.3s ease, background-color 0.3s ease;
}

.page-register__form-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.page-register__form-input:focus {
    border-color: #ffffff;
    background: rgba(0, 0, 0, 0.2);
    outline: none;
}

.page-register__checkbox-group {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.page-register__checkbox-group input[type="checkbox"] {
    margin-right: 10px;
    width: 20px;
    height: 20px;
    accent-color: #EA7C07; /* Highlight checkbox with login color */
}

.page-register__checkbox-group a {
    color: #EA7C07; /* Link color for terms */
    text-decoration: underline;
    transition: color 0.3s ease;
}

.page-register__checkbox-group a:hover {
    color: #D26E06;
}

.page-register__btn-submit {
    width: 100%;
    padding: 18px;
    background: #EA7C07; /* Login button color */
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-register__btn-submit:hover {
    background: #D26E06;
    transform: translateY(-2px);
}

.page-register__login-prompt {
    text-align: center;
    margin-top: 30px;
    font-size: 16px;
    color: #f0f0f0;
}

.page-register__login-prompt a {
    color: #EA7C07; /* Link color for login */
    text-decoration: underline;
    transition: color 0.3s ease;
}

.page-register__login-prompt a:hover {
    color: #D26E06;
}

/* Benefits Section */
.page-register__benefits-section {
    padding: 80px 0;
    background-color: #FFFFFF; /* Light background */
    color: #333333;
}

.page-register__benefits-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    list-style: none;
    padding: 0;
    margin-top: 50px;
}

.page-register__benefit-item {
    background: #f9f9f9;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-register__benefit-item img {
    width: 100%;
     /* Icons should be larger than 200px, but display smaller */
    height: auto;
    margin-bottom: 20px;
    border-radius: 50%; /* Make icons round */
    object-fit: cover;
}

.page-register__benefit-item p {
    font-size: 17px;
    color: #666666;
    margin: 0;
}

/* FAQ Section */
.page-register__faq-section {
    padding: 80px 0;
    background-color: #f5f8fa; /* Slightly off-white for contrast with benefits */
    color: #333333;
}

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

/* FAQ默认状态 - 答案隐藏 */
.page-register__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 và đủ lớn max-height để đảm bảo có thể mở rộng */
.page-register__faq-item.active .page-register__faq-answer {
  max-height: 2000px !important; /* 🚨 Sử dụng!important để đảm bảo ưu tiên, giá trị đủ lớn để chứa bất kỳ nội dung nào */
  padding: 20px 15px !important;
  opacity: 1;
  background: #ffffff; /* White background for answer */
  border-radius: 0 0 5px 5px;
  box-shadow: inset 0 2px 5px rgba(0,0,0,0.03);
}

/* Vấn đề kiểu dáng */
.page-register__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #ffffff;
  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-register__faq-item.active .page-register__faq-question {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    border-color: #26A9E0; /* Brand color border when active */
}

.page-register__faq-question:hover {
  background: #f0f5f8; /* Lighter hover for questions */
  border-color: #2298CA;
}

.page-register__faq-question:active {
  background: #e0e5e8;
}

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

/* Chuyển đổi biểu tượng */
.page-register__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: #26A9E0; /* Brand color for toggle icon */
  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 click */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background-color: rgba(38, 169, 224, 0.1); /* Light background for icon */
}

.page-register__faq-item.active .page-register__faq-toggle {
  color: #EA7C07; /* Login color when active */
  transform: rotate(45deg); /* Xoay để tạo hiệu ứng 'trừ' */
}

/* Final CTA Section */
.page-register__cta-final {
    padding: 80px 0;
    background-color: #26A9E0; /* Brand color as background */
    color: #ffffff; /* White text */
    text-align: center;
}

.page-register__cta-final .page-register__section-title,
.page-register__cta-final .page-register__section-description {
    color: #ffffff;
}

.page-register__cta-button--large {
    padding: 20px 50px;
    font-size: 22px;
    margin-top: 40px;
}


/* --- Responsive Design --- */

/* All images responsive */
.page-register img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Mobile Adaptation */
@media (max-width: 768px) {
    .page-register {
        font-size: 16px;
        line-height: 1.6;
    }

    .page-register__container {
        padding: 15px;
    }

    /* Hero Section Mobile */
    .page-register__hero-section {
        padding-top: var(--header-offset, 120px) !important; /* Mobile header offset */
        padding-bottom: 40px;
    }

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

    .page-register__hero-description {
        font-size: 18px;
        margin-bottom: 30px;
    }

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

    /* General section padding */
    .page-register__intro-section,
    .page-register__form-section,
    .page-register__benefits-section,
    .page-register__faq-section,
    .page-register__cta-final {
        padding: 40px 0;
    }

    .page-register__section-title {
        font-size: 28px;
        margin-bottom: 15px;
    }

    .page-register__section-description {
        font-size: 16px;
        margin-bottom: 30px;
    }

    /* Feature Grid Mobile */
    .page-register__features-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-register__feature-item {
        padding: 20px;
    }

    .page-register__feature-item img {
        
    }

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

    /* Form Section Mobile */
    .page-register__registration-form {
        padding: 30px 20px;
    }

    .page-register__form-label {
        font-size: 15px;
    }

    .page-register__form-input {
        padding: 12px 10px;
        font-size: 15px;
    }

    .page-register__btn-submit {
        padding: 15px;
        font-size: 18px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    /* Benefits List Mobile */
    .page-register__benefits-list {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-register__benefit-item img {
        
    }

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

    /* Ensure all content containers are responsive */
    .page-register__section,
    .page-register__card,
    .page-register__container,
    .page-register__hero-container,
    .page-register__registration-form,
    .page-register__features-grid,
    .page-register__benefits-list,
    .page-register__faq-section {
      max-width: 100% !important;
      width: 100% !important;
      box-sizing: border-box !important;
      padding-left: 15px;
      padding-right: 15px;
    }

    /* Images within content area must be responsive */
    .page-register img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }
}