/* style/login.css */

/* Variables for consistent colors */
:root {
    --primary-color: #FFD700; /* Gold */
    --secondary-color: #8B0000; /* Dark Red */
    --text-dark: #333333;
    --text-light: #ffffff;
    --bg-light: #f9f9f9;
    --bg-dark-section: #222222; /* A dark background for contrast sections */
    --border-color: #e0e0e0;
}

/* Base styles for the login page content */
.page-login {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-dark); /* Default text color for light body background */
    background-color: #ffffff; /* Explicitly set for content area if body is default */
}

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

.page-login__section-title {
    font-size: 32px;
    color: var(--secondary-color);
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
}

.page-login__section-description {
    font-size: 18px;
    text-align: center;
    margin-bottom: 40px;
    color: var(--text-dark);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* 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 */
    min-height: 600px;
    overflow: hidden;
}

.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;
    max-width: 600px;
    color: var(--text-light);
}

.page-login__main-title {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 20px;
    font-weight: bold;
    line-height: 1.2;
}

.page-login__intro-description {
    font-size: 20px;
    margin-bottom: 30px;
}

.page-login__login-form-container {
    background: rgba(0, 0, 0, 0.7);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

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

.page-login__form-label {
    display: block;
    margin-bottom: 8px;
    font-size: 16px;
    color: var(--text-light);
}

.page-login__form-input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--primary-color);
    border-radius: 5px;
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    font-size: 16px;
    box-sizing: border-box;
}

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

.page-login__form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

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

.page-login__forgot-password:hover {
    color: var(--text-light);
}

.page-login__login-button {
    background-color: var(--primary-color);
    color: var(--text-light);
    padding: 12px 25px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    transition: background-color 0.3s ease, transform 0.2s ease;
    text-decoration: none; /* Make it look like a button */
    display: inline-block;
    max-width: 100%; /* For button responsive */
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
}

.page-login__login-button:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
}

.page-login__register-prompt {
    font-size: 16px;
    color: var(--text-light);
    margin-top: 20px;
}

.page-login__register-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-login__register-link:hover {
    color: var(--text-light);
}

/* Benefits Section */
.page-login__benefits-section {
    padding: 80px 0;
    background-color: var(--bg-light); /* Light background for this section */
    color: var(--text-dark);
}

.page-login__benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    text-align: center;
}

.page-login__benefit-item {
    background: #ffffff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-login__benefit-icon {
    width: 100%;
    max-width: 250px;
    height: auto;
    margin-bottom: 20px;
    object-fit: contain;
}

.page-login__benefit-title {
    font-size: 22px;
    color: var(--secondary-color);
    margin-bottom: 15px;
    font-weight: bold;
}

.page-login__benefit-text {
    font-size: 16px;
    color: var(--text-dark);
}

/* Security Section */
.page-login__security-section {
    padding: 80px 0;
    background-color: var(--bg-dark-section); /* Dark background */
    color: var(--text-light); /* Light text for dark background */
}

.page-login__security-section .page-login__section-title {
    color: var(--primary-color);
}

.page-login__security-section .page-login__section-description {
    color: rgba(255, 255, 255, 0.8);
}

.page-login__security-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    text-align: center;
}

.page-login__feature-item {
    background: rgba(255, 255, 255, 0.08);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-login__feature-icon {
    width: 100%;
    max-width: 150px;
    height: auto;
    margin-bottom: 20px;
    object-fit: contain;
}

.page-login__feature-title {
    font-size: 22px;
    color: var(--primary-color);
    margin-bottom: 15px;
    font-weight: bold;
}

.page-login__feature-text {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.7);
}

/* App Download Section */
.page-login__app-download-section {
    padding: 80px 0;
    background-color: var(--bg-light);
    color: var(--text-dark);
}

.page-login__app-download-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 50px;
    flex-wrap: wrap;
}

.page-login__app-text {
    flex: 1;
    min-width: 300px;
    text-align: left;
}

.page-login__app-image-wrapper {
    flex: 1;
    min-width: 300px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.page-login__app-image {
    width: 100%;
    max-width: 500px;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.page-login__download-button {
    background-color: var(--primary-color);
    color: var(--text-light);
    padding: 15px 30px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    margin-top: 30px;
    transition: background-color 0.3s ease, transform 0.2s ease;
    max-width: 100%; /* For button responsive */
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
}

.page-login__download-button:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
}

/* FAQ Section */
.page-login__faq-section {
    padding: 80px 0;
    background-color: #ffffff;
    color: var(--text-dark);
}

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

.page-login__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
}

/* 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 15px;
  opacity: 0;
}

/* 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 for priority, value large enough for any content */
  padding: 20px 15px !important;
  opacity: 1;
  background: var(--bg-light);
  border-radius: 0 0 5px 5px;
}

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

.page-login__faq-question:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
}

.page-login__faq-question:active {
  background: #eeeeee;
}

/* Question title style */
.page-login__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--text-dark);
  pointer-events: none; /* Prevent h3 from blocking click event */
}

/* Toggle icon */
.page-login__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: var(--secondary-color);
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Prevent icon from blocking click event */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

.page-login__faq-item.active .page-login__faq-toggle {
  color: var(--primary-color);
  transform: rotate(45deg); /* Rotate for 'x' effect, or just change text to '−' */
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-login__main-title {
        font-size: 40px;
    }
    .page-login__intro-description {
        font-size: 18px;
    }
    .page-login__section-title {
        font-size: 28px;
    }
    .page-login__section-description {
        font-size: 16px;
    }
    .page-login__app-download-content {
        flex-direction: column;
        text-align: center;
    }
    .page-login__app-text {
        text-align: center;
    }
}

@media (max-width: 768px) {
    /* Mobile specific header offset */
    .page-login__hero-section {
        padding-top: var(--header-offset, 120px) !important;
        padding-bottom: 40px;
        padding-left: 15px;
        padding-right: 15px;
    }

    .page-login__main-title {
        font-size: 32px;
    }
    .page-login__intro-description {
        font-size: 16px;
    }
    .page-login__section-title {
        font-size: 24px;
    }
    .page-login__section-description {
        font-size: 15px;
    }
    .page-login__container {
        padding: 30px 15px;
    }

    /* Images responsive */
    .page-login img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        box-sizing: border-box;
    }
    .page-login__section,
    .page-login__card,
    .page-login__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Buttons responsive */
    .page-login__login-button,
    .page-login__download-button,
    .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;
    }
    .page-login__form-actions {
        flex-direction: column;
        gap: 15px;
    }
    .page-login__forgot-password {
        text-align: center;
        width: 100%;
    }

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