/* Variables for brand colors, assuming they are defined in shared.css or here */
:root {
    --primary-color: #007BFF; /* Deep Blue */
    --secondary-color: #FFD700; /* Gold */
    --text-dark: #333333;
    --text-light: #ffffff;
    --background-light: #f9f9f9;
    --border-color: #e0e0e0;
}

.page-login {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-dark); /* Default text color for light background */
    background-color: #ffffff; /* Default body background is white */
}

/* Hero Section */
.page-login__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, var(--primary-color) 0%, #0056b3 100%); /* Subtle gradient with primary color */
    color: var(--text-light);
}

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

.page-login__hero-image {
    width: 100%;
    margin-bottom: 30px;
}

.page-login__hero-image img {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    filter: none; /* Ensure no filter on images */
}

.page-login__hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
    max-width: 800px;
    margin-top: -80px; /* Overlap image slightly for visual appeal */
    background: rgba(0, 0, 0, 0.5); /* Semi-transparent overlay for text readability */
    padding: 30px;
    border-radius: 12px;
}

.page-login__main-heading {
    font-size: 3em;
    margin-bottom: 20px;
    color: var(--text-light);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.page-login__hero-description {
    font-size: 1.2em;
    line-height: 1.8;
    color: #e0e0e0;
}

/* General Section Styling */
.page-login__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.page-login__section-title {
    font-size: 2.5em;
    text-align: center;
    margin-bottom: 40px;
    color: var(--primary-color);
}

.page-login__section-intro {
    text-align: center;
    font-size: 1.1em;
    margin-bottom: 50px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Light Background Section */
.page-login__light-bg {
    background-color: var(--background-light);
    color: var(--text-dark);
    padding: 80px 0;
}

/* Dark Background Section */
.page-login__dark-section {
    background-color: var(--primary-color);
    color: var(--text-light);
    padding: 80px 0;
}
.page-login__dark-section .page-login__section-title {
    color: var(--secondary-color); /* Gold title on blue background */
}
.page-login__dark-section .page-login__section-intro {
    color: #e0e0e0;
}

/* Login Form Section */
.page-login__form-section {
    padding: 80px 0;
}

.page-login__login-card {
    background: #ffffff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    max-width: 500px;
    margin: 0 auto 40px auto;
    border: 1px solid var(--border-color);
}

.page-login__login-form {
    margin-bottom: 30px;
}

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

.page-login__form-label {
    display: block;
    margin-bottom: 10px;
    font-weight: bold;
    color: var(--primary-color);
    font-size: 1.1em;
}

.page-login__form-input {
    width: 100%;
    padding: 15px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1em;
    box-sizing: border-box;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.page-login__form-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.2);
    outline: none;
}

.page-login__form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    font-size: 0.95em;
}

.page-login__remember-me {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.page-login__checkbox {
    margin-right: 8px;
    width: 18px;
    height: 18px;
    accent-color: var(--primary-color);
}

.page-login__forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-login__forgot-password:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

.page-login__submit-button,
.page-login__cta-button,
.page-login__register-button {
    display: block; /* Ensures full width on mobile */
    width: 100%;
    padding: 18px 25px;
    font-size: 1.1em;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box; /* Ensure padding is included in width */
}

.page-login__btn-primary {
    background: var(--primary-color);
    color: var(--text-light);
    margin-bottom: 15px;
}

.page-login__btn-primary:hover {
    background: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 123, 255, 0.3);
}

.page-login__btn-secondary {
    background: var(--secondary-color);
    color: var(--text-dark);
}

.page-login__btn-secondary:hover {
    background: #e6c200;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 215, 0, 0.3);
}

.page-login__register-prompt {
    text-align: center;
    margin-top: 20px;
    font-size: 1em;
}

.page-login__register-prompt p {
    margin-bottom: 15px;
    color: var(--text-dark);
}

.page-login__form-footer-text {
    text-align: center;
    margin-top: 30px;
    font-size: 0.95em;
    color: #666;
}

/* Benefits Section */
.page-login__benefits-grid,
.page-login__why-w888-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.page-login__benefit-item,
.page-login__why-item {
    background: rgba(255, 255, 255, 0.1); /* Light background for items on dark section */
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}
.page-login__light-bg .page-login__benefit-item,
.page-login__light-bg .page-login__why-item {
    background: #ffffff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    border: 1px solid var(--border-color);
}

.page-login__benefit-item:hover,
.page-login__why-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
}

.page-login__benefit-item img,
.page-login__why-item img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 20px;
    object-fit: cover;
    filter: none; /* Ensure no filter on images */
}

.page-login__benefit-title,
.page-login__why-title {
    font-size: 1.5em;
    margin-bottom: 15px;
    color: var(--secondary-color); /* Gold titles on dark background */
}
.page-login__light-bg .page-login__benefit-title,
.page-login__light-bg .page-login__why-title {
    color: var(--primary-color); /* Blue titles on light background */
}

.page-login__benefit-item p,
.page-login__why-item p {
    font-size: 1em;
    line-height: 1.7;
    color: #e0e0e0;
}
.page-login__light-bg .page-login__benefit-item p,
.page-login__light-bg .page-login__why-item p {
    color: var(--text-dark);
}

/* CTA Section */
.page-login__cta-section,
.page-login__cta-bottom-section {
    text-align: center;
    padding-top: 40px;
}

.page-login__cta-section p,
.page-login__cta-bottom-section p {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: var(--text-light);
}
.page-login__light-bg .page-login__cta-section p,
.page-login__light-bg .page-login__cta-bottom-section p {
    color: var(--text-dark);
}

.page-login__button-group {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
}

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

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

/* FAQ container styles */
.page-login__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  background-color: #ffffff;
}

/* FAQ default state - answer hidden */
.page-login__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 25px; /* Adjust padding here */
  opacity: 0;
  color: var(--text-dark);
}

/* FAQ expanded state - 🚨 Use!important and sufficiently large max-height */
.page-login__faq-item.active .page-login__faq-answer {
  max-height: 2000px !important; /* 🚨 Use!important to ensure priority, value large enough to contain any content */
  padding: 20px 25px !important; /* Adjust padding here */
  opacity: 1;
  background: var(--background-light);
  border-top: 1px solid var(--border-color);
}

/* Question styles */
.page-login__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px; /* Adjust padding here */
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}