/* style/login.css */
/* 页面完整样式代码 - 注意：所有选择器必须使用BEM命名规则（双下划线__连接） */
.page-login {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #333333; /* Default dark text for light body background */
  background-color: #ffffff; /* Assuming body background is white */
  padding-top: var(--header-offset, 120px); /* Ensure content is not hidden by fixed header */
}

/* Hero Section */
.page-login__hero-section {
  position: relative;
  width: 100%;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  padding: 60px 20px;
  box-sizing: border-box;
}

.page-login__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

.page-login__hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6); /* Dark overlay for text readability */
  z-index: 2;
}

.page-login__hero-content {
  position: relative;
  z-index: 3;
  color: #ffffff;
  max-width: 900px;
  padding: 20px;
  box-sizing: border-box;
}

.page-login__main-title {
  font-size: 3.2em;
  margin-bottom: 20px;
  line-height: 1.2;
  color: #FFFF00; /* Custom color for main title */
}

.page-login__description {
  font-size: 1.2em;
  margin-bottom: 30px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.page-login__login-form-wrapper {
  background: rgba(255, 255, 255, 0.15); /* Slightly transparent white background */
  padding: 30px;
  border-radius: 10px;
  max-width: 400px;
  margin: 30px auto 0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.page-login__login-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.page-login__form-group {
  text-align: left;
}

.page-login__form-label {
  display: block;
  margin-bottom: 8px;
  font-weight: bold;
  color: #ffffff;
}

.page-login__form-input {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid #017439;
  border-radius: 5px;
  background-color: rgba(255, 255, 255, 0.9);
  color: #333333;
  font-size: 1em;
  box-sizing: border-box;
}

.page-login__form-input::placeholder {
  color: #888888;
}

.page-login__form-options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9em;
  color: #ffffff;
}

.page-login__checkbox-label {
  display: flex;
  align-items: center;
  cursor: pointer;
}

.page-login__checkbox-input {
  margin-right: 8px;
}

.page-login__forgot-password-link {
  color: #FFFF00; /* Custom color for link */
  text-decoration: none;
}

.page-login__forgot-password-link:hover {
  text-decoration: underline;
}

.page-login__btn-login {
  background-color: #C30808; /* Custom Login Button color */
  color: #FFFF00; /* Custom Login Button font color */
  padding: 14px 25px;
  border: none;
  border-radius: 5px;
  font-size: 1.1em;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s ease;
  text-transform: uppercase;
  width: 100%;
  box-sizing: border-box;
}

.page-login__btn-login:hover {
  background-color: #e02020;
}

.page-login__register-text {
  margin-top: 20px;
  font-size: 1em;
  color: #ffffff;
}

.page-login__register-link {
  color: #FFFF00; /* Custom color for link */
  text-decoration: none;
  font-weight: bold;
}

.page-login__register-link:hover {
  text-decoration: underline;
}

/* General Content Section */
.page-login__content-section {
  padding: 60px 20px;
  text-align: center;
  box-sizing: border-box;
}

.page-login__container {
  max-width: 1200px;
  margin: 0 auto;
}

.page-login__section-title {
  font-size: 2.5em;
  margin-bottom: 20px;
  color: #017439; /* Brand primary color */
}

.page-login__section-description {
  font-size: 1.1em;
  max-width: 800px;
  margin: 0 auto 40px;
  color: #555555;
}

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

.page-login__benefit-item {
  background: #ffffff;
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  height: 100%; /* Ensure equal height */
  box-sizing: border-box;
  color: #333333;
}

.page-login__benefit-item:hover {
  transform: translateY(-5px);
}

.page-login__benefit-icon {
  width: 100%; /* Occupy full width of card */
  max-width: 400px; /* Example max-width for benefit icons, ensuring >200px */
  height: auto;
  border-radius: 8px;
  margin-bottom: 20px;
  object-fit: cover;
}

.page-login__benefit-title {
  font-size: 1.5em;
  margin-bottom: 15px;
  color: #017439;
}

.page-login__benefit-text {
  font-size: 1em;
  color: #555555;
  flex-grow: 1; /* Push footer to bottom */
}

/* Guide Section */
.page-login__guide-section {
  background-color: #017439; /* Dark background */
  color: #ffffff; /* Light text */
}

.page-login__guide-section .page-login__section-title,
.page-login__guide-section .page-login__section-description {
  color: #ffffff;
}

.page-login__guide-list {
  list-style: none;
  padding: 0;
  margin-top: 40px;
  text-align: left;
}

.page-login__guide-item {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 25px;
  margin-bottom: 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-login__guide-item:last-child {
  margin-bottom: 0;
}

.page-login__guide-step-title {
  font-size: 1.4em;
  color: #FFFF00; /* Custom color for step titles */
  margin-bottom: 10px;
}

.page-login__guide-item p {
  font-size: 1em;
  color: #f0f0f0;
}

.page-login__guide-item a {
  color: #FFFF00; /* Custom color for links */
  text-decoration: underline;
}

.page-login__guide-footer {
  margin-top: 40px;
  font-size: 1.1em;
  color: #f0f0f0;
}

.page-login__guide-footer a {
  color: #FFFF00; /* Custom color for links */
  text-decoration: underline;
}

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

.page-login__security-item {
  background: #ffffff;
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease;
  text-align: left;
  height: 100%;
  box-sizing: border-box;
  color: #333333;
}

.page-login__security-item:hover {
  transform: translateY(-5px);
}

.page-login__security-title {
  font-size: 1.5em;
  margin-bottom: 15px;
  color: #017439;
}

.page-login__security-text {
  font-size: 1em;
  color: #555555;
}

.page-login__security-text a {
  color: #017439;
  text-decoration: none;
}

.page-login__security-text a:hover {
  text-decoration: underline;
}

.page-login__security-cta {
  margin-top: 40px;
  font-size: 1.1em;
  color: #555555;
}

.page-login__security-cta a {
  color: #017439;
  text-decoration: none;
  font-weight: bold;
}

.page-login__security-cta a:hover {
  text-decoration: underline;
}

/* FAQ Section */
.page-login__faq-section {
  background-color: #017439; /* Dark background */
  color: #ffffff; /* Light text */
}

.page-login__faq-section .page-login__section-title,
.page-login__faq-section .page-login__section-description {
  color: #ffffff;
}

.page-login__faq-list {
  max-width: 900px;
  margin: 40px auto 0;
  text-align: left;
}

.page-login__faq-item {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-login__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.05);
  transition: background-color 0.3s ease;
}

.page-login__faq-question:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.page-login__faq-title {
  font-size: 1.2em;
  margin: 0;
  color: #ffffff;
}

.page-login__faq-toggle {
  font-size: 1.5em;
  font-weight: bold;
  color: #FFFF00; /* Custom color for toggle icon */
  transition: transform 0.3s ease;
}

.page-login__faq-item.active .page-login__faq-toggle {
  transform: rotate(45deg);
}

.page-login__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 25px;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

.page-login__faq-item.active .page-login__faq-answer {
  max-height: 1000px !important; /* Sufficiently large value */
  padding: 15px 25px 25px;
}

.page-login__faq-answer p {
  font-size: 1em;
  color: #f0f0f0;
  margin-bottom: 15px;
}

.page-login__faq-answer a {
  color: #FFFF00; /* Custom color for links */
  text-decoration: underline;
}

.page-login__faq-answer img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-top: 15px;
  display: block;
}

/* CTA Section */
.page-login__cta-section {
  background-color: #ffffff;
  padding: 80px 20px;
}

.page-login__cta-buttons {
  display: flex;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

.page-login__cta-button {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  text-transform: uppercase;
  max-width: 100%; /* Ensure buttons don't overflow */
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
  text-align: center;
}

.page-login__btn-primary {
  background-color: #C30808; /* Custom Login Button color */
  color: #FFFF00; /* Custom Login Button font color */
  border: 2px solid #C30808;
}

.page-login__btn-primary:hover {
  background-color: #e02020;
  border-color: #e02020;
}

.page-login__btn-secondary {
  background-color: #017439; /* Brand primary color */
  color: #ffffff;
  border: 2px solid #017439;
}

.page-login__btn-secondary:hover {
  background-color: #005a2e;
  border-color: #005a2e;
}

.page-login__btn-tertiary {
  background-color: #f5f5f5; /* Light background */
  color: #017439; /* Brand primary color */
  border: 2px solid #017439;
}

.page-login__btn-tertiary:hover {
  background-color: #e0e0e0;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-login__main-title {
    font-size: 2.8em;
  }

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

  .page-login__benefits-grid,
  .page-login__security-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  }
}

@media (max-width: 768px) {
  .page-login {
    font-size: 16px;
    line-height: 1.6;
  }

  .page-login__hero-section {
    min-height: 500px;
    padding: 40px 15px;
  }

  .page-login__main-title {
    font-size: 2.2em;
    margin-bottom: 15px;
  }

  .page-login__description {
    font-size: 1em;
    margin-bottom: 20px;
  }

  .page-login__login-form-wrapper {
    padding: 25px;
    margin-top: 20px;
  }

  .page-login__form-input {
    padding: 10px 12px;
  }

  .page-login__btn-login {
    padding: 12px 20px;
    font-size: 1em;
  }

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

  .page-login__container {
    padding-left: 15px;
    padding-right: 15px;
    box-sizing: border-box;
  }

  .page-login__section-title {
    font-size: 1.8em;
    margin-bottom: 15px;
  }

  .page-login__section-description {
    font-size: 0.95em;
    margin-bottom: 30px;
  }

  .page-login__benefits-grid,
  .page-login__security-grid {
    grid-template-columns: 1fr; /* Stack items on mobile */
    gap: 20px;
  }

  .page-login__benefit-item,
  .page-login__security-item {
    padding: 25px;
  }

  .page-login__benefit-title,
  .page-login__security-title {
    font-size: 1.3em;
  }

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

  .page-login__guide-step-title {
    font-size: 1.2em;
  }

  .page-login__faq-question {
    padding: 15px 20px;
  }

  .page-login__faq-title {
    font-size: 1.1em;
  }

  .page-login__faq-answer {
    padding: 0 20px;
  }

  .page-login__faq-item.active .page-login__faq-answer {
    padding: 10px 20px 20px;
  }

  .page-login__cta-buttons {
    flex-direction: column; /* Stack buttons vertically */
    gap: 15px;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-login__cta-button {
    width: 100%;
    max-width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  /* Image responsive rules for mobile */
  .page-login img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-login__section,
  .page-login__card,
  .page-login__container,
  .page-login__hero-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow-x: hidden !important; /* Prevent horizontal scroll */
  }
}

@media (max-width: 480px) {
  .page-login__main-title {
    font-size: 1.8em;
  }
  .page-login__section-title {
    font-size: 1.5em;
  }
  .page-login__login-form-wrapper {
    margin-left: 0;
    margin-right: 0;
  }
}

/* Ensure content area images are not smaller than 200px display size */
.page-login__benefit-icon,
.page-login__faq-image {
  min-width: 200px;
  min-height: 200px;
}

/* Color contrast enforcement */
/* For dark background sections */
.page-login__dark-bg {
  background-color: #017439; /* Primary brand color */
  color: #ffffff; /* White text for contrast */
}

.page-login__dark-bg .page-login__section-title,
.page-login__dark-bg .page-login__section-description,
.page-login__dark-bg .page-login__form-label,
.page-login__dark-bg .page-login__register-text {
  color: #ffffff;
}

/* For light background sections (default) */
.page-login__light-bg {
  background-color: #ffffff;
  color: #333333;
}

.page-login p,
.page-login li {
  color: inherit; /* Inherit from parent for consistency */
}

/* Links in light background sections */
.page-login__light-bg a {
  color: #017439; /* Use brand primary for links */
}

/* Button colors are custom as per requirements */
/* Login button */
.page-login__btn-login {
  background-color: #C30808;
  color: #FFFF00;
}

/* Primary CTA button (login) */
.page-login__btn-primary {
  background-color: #C30808;
  color: #FFFF00;
}

/* Secondary CTA button (register) */
.page-login__btn-secondary {
  background-color: #017439;
  color: #FFFFFF;
}

/* Tertiary CTA button (download) */
.page-login__btn-tertiary {
  background-color: #f5f5f5;
  color: #017439;
  border-color: #017439;
}