/* style/login.css */

/* Base styles for the login page */
.page-login {
  color: #ffffff; /* Light text for dark body background */
  font-family: Arial, sans-serif;
  line-height: 1.6;
  background-color: transparent; /* Body background is handled by shared.css */
}

/* Hero Section */
.page-login__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column; /* Image on top, content below */
  align-items: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding as body handles --header-offset */
  box-sizing: border-box;
  background-color: #0a0a0a; /* Dark background for the section */
}

.page-login__hero-image-wrapper {
  width: 100%;
  max-width: 1200px; /* Max width for the image */
  margin-bottom: 30px; /* Space between image and content */
  overflow: hidden;
  border-radius: 10px;
}

.page-login__hero-image {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

.page-login__hero-content {
  max-width: 800px;
  text-align: center;
  z-index: 1;
}

.page-login__main-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem); /* Responsive font size */
  font-weight: 700;
  color: #26A9E0; /* Brand color for main title */
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-login__hero-description {
  font-size: 1.1rem;
  margin-bottom: 30px;
  color: #f0f0f0;
}

/* Login Form */
.page-login__login-form-wrapper {
  background: rgba(255, 255, 255, 0.1); /* Semi-transparent white for form background */
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  width: 100%;
  max-width: 400px;
  box-sizing: border-box;
}

.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 #26A9E0;
  border-radius: 5px;
  background-color: rgba(255, 255, 255, 0.05);
  color: #ffffff;
  font-size: 1rem;
  box-sizing: border-box;
}

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

.page-login__form-input:focus {
  outline: none;
  border-color: #EA7C07;
  box-shadow: 0 0 0 3px rgba(234, 124, 7, 0.3);
}

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

.page-login__remember-me {
  display: flex;
  align-items: center;
  gap: 5px;
}

.page-login__checkbox {
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid #26A9E0;
  border-radius: 3px;
  background-color: rgba(255, 255, 255, 0.1);
  cursor: pointer;
  position: relative;
}

.page-login__checkbox:checked {
  background-color: #26A9E0;
  border-color: #26A9E0;
}

.page-login__checkbox:checked::before {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #ffffff;
  font-size: 14px;
  line-height: 1;
}

.page-login__checkbox-label {
  color: #ffffff;
  cursor: pointer;
}

.page-login__forgot-password-link {
  color: #26A9E0;
  text-decoration: none;
}

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

.page-login__btn-primary {
  background-color: #EA7C07; /* Login button color */
  color: #ffffff;
  padding: 12px 20px;
  border: none;
  border-radius: 5px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
  box-sizing: border-box; /* Ensure padding doesn't cause overflow */
  max-width: 100%; /* For responsive buttons */
  white-space: normal; /* Allow text wrap */
  word-wrap: break-word; /* Allow text wrap */
  text-decoration: none; /* For <a> tag */
  display: inline-block; /* For <a> tag */
}

.page-login__btn-primary:hover {
  background-color: #e06c00;
  transform: translateY(-2px);
}

.page-login__no-account-text {
  text-align: center;
  margin-top: 15px;
  color: #f0f0f0;
}

.page-login__register-link {
  color: #26A9E0;
  text-decoration: none;
  font-weight: bold;
}

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

/* General Section Styles */
.page-login__section {
  padding: 80px 20px;
  box-sizing: border-box;
  background-color: #0d0d0d; /* Slightly lighter dark background for sections */
  color: #ffffff;
  text-align: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

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

.page-login__section-title {
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: #26A9E0;
  margin-bottom: 20px;
  font-weight: 700;
}

.page-login__section-description {
  font-size: 1.1rem;
  max-width: 900px;
  margin: 0 auto 40px auto;
  color: #f0f0f0;
}

/* Why Login Section */
.page-login__why-login-section {
  background-color: #0a0a0a;
}

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

.page-login__feature-card {
  background: rgba(255, 255, 255, 0.08); /* Darker semi-transparent background for cards */
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, background-color 0.3s ease;
  height: 100%; /* Ensure cards have equal height */
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  color: #ffffff; /* Light text for dark card background */
}

.page-login__feature-card:hover {
  transform: translateY(-5px);
  background-color: rgba(38, 169, 224, 0.2); /* Hover effect with primary color */
}

.page-login__feature-icon {
  width: 100%;
  max-width: 150px; /* Smallest recommended size for content images */
  height: auto;
  margin-bottom: 20px;
  object-fit: contain;
  border-radius: 8px;
}

.page-login__card-title {
  font-size: 1.5rem;
  color: #26A9E0;
  margin-bottom: 15px;
  font-weight: 600;
}

.page-login__card-text {
  font-size: 1rem;
  color: #f0f0f0;
  flex-grow: 1; /* Pushes content down if card is taller */
}

/* Guide Section */
.page-login__guide-section {
  background-color: #0d0d0d;
}

.page-login__guide-list {
  list-style: none;
  padding: 0;
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.page-login__guide-item {
  background: rgba(255, 255, 255, 0.08);
  padding: 30px;
  border-radius: 10px;
  text-align: left;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  color: #ffffff;
}

.page-login__guide-step-title {
  font-size: 1.6rem;
  color: #EA7C07; /* Login button color for steps */
  margin-bottom: 10px;
  font-weight: 600;
}

.page-login__guide-step-text {
  font-size: 1rem;
  color: #f0f0f0;
}

/* Troubleshooting Section */
.page-login__troubleshooting-section {
  background-color: #0a0a0a;
}

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

.page-login__troubleshooting-item {
  background: rgba(255, 255, 255, 0.08);
  padding: 30px;
  border-radius: 10px;
  text-align: left;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-login__troubleshooting-title {
  font-size: 1.5rem;
  color: #26A9E0;
  margin-bottom: 15px;
  font-weight: 600;
}

.page-login__troubleshooting-text {
  font-size: 1rem;
  color: #f0f0f0;
  margin-bottom: 20px;
}

.page-login__btn-secondary {
  background-color: transparent;
  color: #26A9E0;
  padding: 10px 20px;
  border: 2px solid #26A9E0;
  border-radius: 5px;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
  text-decoration: none;
  display: inline-block; /* For proper button-like behavior */
  box-sizing: border-box; /* Ensure padding doesn't cause overflow */
  max-width: 100%; /* For responsive buttons */
  white-space: normal; /* Allow text wrap */
  word-wrap: break-word; /* Allow text wrap */
  margin-top: auto; /* Push button to bottom */
}

.page-login__btn-secondary:hover {
  background-color: #26A9E0;
  color: #ffffff;
  transform: translateY(-2px);
}

/* FAQ Section */
.page-login__faq-section {
  background-color: #0d0d0d;
}

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

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

.page-login__faq-item summary {
  list-style: none; /* Remove default marker */
}

.page-login__faq-item summary::-webkit-details-marker {
  display: none; /* Remove default marker for Webkit browsers */
}

.page-login__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.2rem;
  font-weight: bold;
  color: #26A9E0;
  cursor: pointer;
  background-color: 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-toggle {
  font-size: 1.5rem;
  line-height: 1;
  color: #EA7C07; /* Login button color for toggle */
  margin-left: 15px;
}

.page-login__faq-item[open] .page-login__faq-toggle {
  content: '−'; /* Change to minus when open */
}

.page-login__faq-answer {
  padding: 20px 25px;
  font-size: 1rem;
  color: #f0f0f0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

.page-login__btn-text-link {
  color: #EA7C07;
  text-decoration: underline;
  font-weight: bold;
}

.page-login__btn-text-link:hover {
  color: #26A9E0;
}


/* CTA Section */
.page-login__cta-section {
  background-color: #0a0a0a;
  padding-bottom: 80px;
}

.page-login__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
  width: 100%;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
  overflow: hidden;
}

.page-login__cta-buttons .page-login__btn-primary,
.page-login__cta-buttons .page-login__btn-secondary {
  min-width: 180px; /* Ensure buttons are not too small */
  padding: 15px 30px;
  font-size: 1.2rem;
  border-radius: 8px;
}


/* Responsive Design */
@media (max-width: 1024px) {
  .page-login__main-title {
    font-size: clamp(2rem, 4.5vw, 3rem);
  }
  .page-login__section-title {
    font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  }
}

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

  .page-login__hero-section {
    padding: 40px 15px;
    padding-top: 10px;
  }

  .page-login__hero-image-wrapper {
    margin-bottom: 20px;
  }

  .page-login__main-title {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
  }

  .page-login__hero-description {
    font-size: 1rem;
  }

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

  .page-login__form-options {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .page-login__btn-primary,
  .page-login__btn-secondary,
  .page-login a[class*="button"],
  .page-login a[class*="btn"] {
    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;
  }

  /* All images and their containers */
  .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__login-form-wrapper,
  .page-login__cta-buttons,
  .page-login__faq-item {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important; /* Prevent content overflow */
  }

  .page-login__video-section { /* If a video section was present */
    padding-top: 10px !important;
  }

  .page-login__section {
    padding: 50px 15px;
  }

  .page-login__section-title {
    font-size: clamp(1.5rem, 5vw, 2.2rem);
  }

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

  .page-login__features-grid,
  .page-login__troubleshooting-items {
    grid-template-columns: 1fr; /* Stack cards vertically */
    gap: 20px;
  }

  .page-login__feature-icon {
    max-width: 100px;
  }

  .page-login__card-title,
  .page-login__guide-step-title,
  .page-login__troubleshooting-title {
    font-size: 1.3rem;
  }

  .page-login__faq-question {
    font-size: 1.1rem;
    padding: 15px 20px;
  }

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

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

  .page-login__cta-buttons .page-login__btn-primary,
  .page-login__cta-buttons .page-login__btn-secondary {
    min-width: unset; /* Remove min-width for full flexibility */
    width: 100%;
    padding: 12px 20px;
    font-size: 1.1rem;
  }
}

@media (max-width: 480px) {
  .page-login__main-title {
    font-size: clamp(1.5rem, 8vw, 2.2rem);
  }
  .page-login__login-form-wrapper {
    padding: 20px;
  }
  .page-login__btn-primary {
    font-size: 1rem;
  }
  .page-login__section-title {
    font-size: clamp(1.3rem, 6vw, 2rem);
  }
  .page-login__feature-icon {
    max-width: 80px;
  }
  .page-login__card-title,
  .page-login__guide-step-title,
  .page-login__troubleshooting-title {
    font-size: 1.2rem;
  }
  .page-login__faq-question {
    font-size: 1rem;
  }
}