/* style/login.css */

/* Base styles for the login page */
.page-login {
  background-color: #08160F; /* Custom background color */
  color: #F2FFF6; /* Main text color for dark background */
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  font-size: 18px;
}

/* Container for content sections */
.page-login__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

/* Hero Section */
.page-login__hero-section {
  position: relative;
  display: flex;
  flex-direction: column; /* Stack image and content vertically */
  align-items: center;
  text-align: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding as body handles --header-offset */
  overflow: hidden;
  background-color: #08160F; /* Fallback background */
}

.page-login__hero-image {
  width: 100%;
  max-height: 550px; /* Max height for hero image */
  object-fit: cover;
  filter: brightness(0.6);
  margin-bottom: 40px; /* Space between image and content */
  display: block; /* Ensure it behaves as a block element */
  border-radius: 10px;
}

.page-login__hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  padding: 40px;
  background: #11271B; /* Use a solid background for text content */
  border-radius: 10px;
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

.page-login__main-title {
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  font-weight: bold;
  color: #F2FFF6;
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-login__description {
  font-size: 1.1rem;
  color: #A7D9B8; /* Secondary text color */
  margin-bottom: 30px;
}

/* CTA Buttons */
.page-login__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
  width: 100%;
}

.page-login__btn-primary,
.page-login__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  box-sizing: border-box;
  text-align: center;
  min-width: 180px;
  white-space: normal;
  word-wrap: break-word;
}

.page-login__btn-primary {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%); /* Custom button gradient */
  color: #F2FFF6;
  border: none;
  box-shadow: 0 4px 15px rgba(42, 209, 111, 0.4);
}

.page-login__btn-primary:hover {
  background: linear-gradient(180deg, #13994A 0%, #2AD16F 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(42, 209, 111, 0.6);
}

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

.page-login__btn-secondary:hover {
  background: #2AD16F;
  color: #08160F;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(42, 209, 111, 0.2);
}

/* Section Titles */
.page-login__section-title {
  font-size: clamp(2rem, 3.5vw, 2.5rem);
  font-weight: bold;
  text-align: center;
  margin-bottom: 40px;
  color: #F2FFF6;
}

/* Form Section */
.page-login__form-section {
  padding: 80px 0;
  background-color: #11271B; /* Card BG color */
  text-align: center;
}

.page-login__login-form {
  max-width: 500px;
  margin: 0 auto;
  background-color: #08160F; /* Darker background for form */
  padding: 40px;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
  border: 1px solid #2E7A4E; /* Custom border color */
}

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

.page-login__form-label {
  display: block;
  margin-bottom: 10px;
  font-size: 1.1rem;
  color: #F2FFF6;
}

.page-login__form-input {
  width: 100%;
  padding: 15px;
  border: 1px solid #2E7A4E;
  border-radius: 8px;
  background-color: #0A4B2C; /* Deep Green */
  color: #F2FFF6;
  font-size: 1rem;
  box-sizing: border-box;
}

.page-login__form-input::placeholder {
  color: #A7D9B8;
  opacity: 0.7;
}

.page-login__form-input:focus {
  outline: none;
  border-color: #57E38D; /* Glow color on focus */
  box-shadow: 0 0 0 3px rgba(87, 227, 141, 0.3);
}

.page-login__form-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  margin-top: 30px;
}

.page-login__login-form .page-login__btn-primary {
  width: 100%;
  max-width: 250px;
}

.page-login__forgot-password-link {
  color: #A7D9B8;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

.page-login__forgot-password-link:hover {
  color: #57E38D; /* Glow color */
  text-decoration: underline;
}

.page-login__form-footer {
  margin-top: 30px;
  font-size: 0.9rem;
  color: #A7D9B8;
}

/* Why Choose Section */
.page-login__why-choose-section {
  padding: 80px 0;
  background-color: #08160F;
}

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

.page-login__feature-card {
  background-color: #11271B; /* Card BG color */
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  border: 1px solid #2E7A4E;
  height: 100%; /* Ensure cards have equal height */
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.page-login__feature-image {
  max-width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
}

.page-login__feature-title {
  font-size: 1.6rem;
  color: #F2FFF6;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-login__feature-description {
  color: #A7D9B8;
  font-size: 1rem;
  flex-grow: 1; /* Allow description to take available space */
}

/* Register CTA Section */
.page-login__register-cta-section {
  padding: 80px 0;
  text-align: center;
  background-color: #0A4B2C; /* Deep Green for a different contrast */
  color: #F2FFF6;
}

.page-login__register-cta-section .page-login__section-title {
  color: #F2FFF6;
}

.page-login__register-cta-section .page-login__description {
  color: #A7D9B8;
  max-width: 800px;
  margin: 0 auto 40px auto;
}

/* FAQ Section */
.page-login__faq-section {
  padding: 80px 0;
  background-color: #08160F; /* Background color */
}

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

.page-login__faq-item {
  background-color: #11271B; /* Card BG color */
  border: 1px solid #2E7A4E; /* Border color */
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-login__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  cursor: pointer;
  background-color: #1E3A2A; /* Divider color for question background */
  color: #F2FFF6;
  font-weight: bold;
  font-size: 1.1rem;
  transition: background-color 0.3s ease;
  list-style: none; /* For details/summary */
}

.page-login__faq-question::-webkit-details-marker {
  display: none; /* Hide default marker for details/summary */
}

.page-login__faq-item[open] > .page-login__faq-question {
  background-color: #0A4B2C; /* Deep Green when open */
  color: #F2FFF6;
}

.page-login__faq-question:hover {
  background-color: #0A4B2C; /* Deep Green on hover */
}

.page-login__faq-qtext {
  flex-grow: 1;
}

.page-login__faq-toggle {
  font-size: 1.5rem;
  line-height: 1;
  margin-left: 15px;
  color: #57E38D; /* Glow color for toggle */
}

.page-login__faq-answer {
  padding: 0 25px 20px 25px;
  color: #A7D9B8;
  font-size: 1rem;
  line-height: 1.8;
}

.page-login__faq-answer p {
  margin-top: 15px;
}


/* Responsive styles */
@media (max-width: 1024px) {
  .page-login__hero-image {
    max-height: 450px;
  }
  .page-login__hero-content {
    padding: 30px;
  }
}

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

  /* Ensure all content containers have proper padding and width */
  .page-login__section,
  .page-login__card,
  .page-login__container,
  .page-login__hero-section,
  .page-login__form-section,
  .page-login__why-choose-section,
  .page-login__register-cta-section,
  .page-login__faq-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    overflow: hidden !important; /* Prevent horizontal scroll */
  }

  .page-login__hero-section {
    padding-top: 10px !important; /* body already handles --header-offset */
    padding-bottom: 40px !important;
  }

  .page-login__hero-image {
    max-height: 300px;
    margin-bottom: 30px;
  }

  .page-login__hero-content {
    padding: 20px;
  }

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

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

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

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

  .page-login__section-title {
    font-size: 1.8rem;
    margin-bottom: 30px;
  }

  .page-login__login-form {
    padding: 30px;
  }

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

  .page-login__features-grid {
    grid-template-columns: 1fr; /* Single column layout */
  }

  .page-login__feature-card {
    padding: 20px;
  }

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

  /* FAQ */
  .page-login__faq-question {
    font-size: 1rem;
    padding: 15px 20px;
  }
  .page-login__faq-answer {
    padding: 0 20px 15px 20px;
  }
}

@media (max-width: 480px) {
  .page-login__main-title {
    font-size: 1.8rem;
  }
  .page-login__section-title {
    font-size: 1.6rem;
  }
  .page-login__hero-content {
    padding: 15px;
  }
}

/* Ensure no filter is used on images except for specific cases */
.page-login img {
  filter: none; /* Default: No CSS filter allowed for changing image colors */
}
/* Exception for hero image to darken it for mood and better contrast with surrounding elements */
.page-login__hero-image {
  filter: brightness(0.6); /* Allowed for stylistic mood, not text overlay */
}