/* style/login.css */

/* Custom Properties based on color palette */
:root {
    --page-login-primary-color: #11A84E; /* Main color */
    --page-login-secondary-color: #22C768; /* Auxiliary color */
    --page-login-card-bg: #11271B; /* Card Background */
    --page-login-bg: #08160F; /* Background */
    --page-login-text-main: #F2FFF6; /* Main Text */
    --page-login-text-secondary: #A7D9B8; /* Secondary Text */
    --page-login-border-color: #2E7A4E; /* Border */
    --page-login-glow-color: #57E38D; /* Glow */
    --page-login-gold-color: #F2C14E; /* Gold */
    --page-login-divider-color: #1E3A2A; /* Divider */
    --page-login-deep-green: #0A4B2C; /* Deep Green */

    /* Button Gradient */
    --page-login-btn-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
}

.page-login {
    background-color: var(--page-login-bg);
    color: var(--page-login-text-main); /* Light text for dark background */
    font-family: 'Arial', sans-serif; /* Example font */
    line-height: 1.6;
}

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

.page-login__hero-section {
    display: flex;
    flex-direction: column; /* Default for mobile, will change for desktop */
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    padding-top: 10px; /* Small top padding, body handles header offset */
    text-align: center;
    background-color: var(--page-login-deep-green); /* Example background for hero */
    position: relative;
    overflow: hidden;
}

.page-login__hero-content {
    max-width: 800px;
    z-index: 1;
    margin-bottom: 30px; /* Space between content and image on mobile */
}

.page-login__main-title {
    font-size: clamp(2.2em, 4vw, 3.5em); /* Responsive font size */
    font-weight: 700;
    color: var(--page-login-gold-color); /* Gold for main title */
    margin-bottom: 20px;
    line-height: 1.2;
}

.page-login__description {
    font-size: 1.1em;
    color: var(--page-login-text-secondary);
    margin-bottom: 30px;
}

.page-login__hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
}

.page-login__btn-primary,
.page-login__btn-secondary,
.page-login__submit-button,
.page-login__social-btn,
.page-login a[class*="button"],
.page-login a[class*="btn"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1em;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    box-sizing: border-box; /* Crucial for responsive buttons */
    white-space: normal; /* Allow text wrapping */
    word-wrap: break-word; /* Allow text wrapping */
    max-width: 100%; /* Ensure buttons don't exceed container width */
}

.page-login__btn-primary, .page-login__submit-button {
    background: var(--page-login-btn-gradient);
    color: #ffffff; /* White text for primary button */
    border: none;
    box-shadow: 0 4px 15px rgba(42, 209, 111, 0.4);
}

.page-login__btn-primary:hover, .page-login__submit-button:hover {
    opacity: 0.9;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(42, 209, 111, 0.6);
}

.page-login__btn-secondary {
    background-color: transparent;
    color: var(--page-login-primary-color);
    border: 2px solid var(--page-login-primary-color);
    box-shadow: 0 0 0 rgba(0,0,0,0);
}

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

.page-login__hero-image-wrapper {
    width: 100%;
    max-width: 1200px; /* Constrain image width */
    margin-top: 30px; /* Space above image */
    z-index: 0;
}

.page-login__hero-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.5);
}

.page-login__section-title {
    font-size: 2.5em;
    font-weight: 700;
    color: var(--page-login-gold-color);
    text-align: center;
    margin-bottom: 20px;
    padding-top: 40px;
}

.page-login__section-description {
    font-size: 1.1em;
    color: var(--page-login-text-secondary);
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px auto;
}

/* Form Section */
.page-login__form-section {
    background-color: var(--page-login-bg); /* Dark background for form section */
    padding: 60px 0;
    text-align: center;
}

.page-login__form-wrapper {
    background-color: var(--page-login-card-bg); /* Darker card background */
    border-radius: 12px;
    padding: 40px;
    max-width: 500px;
    margin: 40px auto 0 auto;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    border: 1px solid var(--page-login-border-color);
}

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

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

.page-login__form-label {
    display: block;
    margin-bottom: 8px;
    color: var(--page-login-text-main);
    font-weight: 600;
}

.page-login__form-input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--page-login-divider-color);
    border-radius: 6px;
    background-color: var(--page-login-deep-green); /* Input background */
    color: var(--page-login-text-main);
    font-size: 1em;
    box-sizing: border-box;
}

.page-login__form-input::placeholder {
    color: var(--page-login-text-secondary);
    opacity: 0.7;
}

.page-login__form-input:focus {
    outline: none;
    border-color: var(--page-login-primary-color);
    box-shadow: 0 0 0 3px rgba(17, 168, 78, 0.3);
}

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

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

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

.page-login__checkbox-label {
    color: var(--page-login-text-secondary);
}

.page-login__forgot-password {
    color: var(--page-login-primary-color);
    text-decoration: none;
}

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

.page-login__submit-button {
    width: 100%;
    margin-top: 10px;
}

.page-login__social-login {
    margin-top: 30px;
    border-top: 1px solid var(--page-login-divider-color);
    padding-top: 30px;
}

.page-login__social-text {
    color: var(--page-login-text-secondary);
    margin-bottom: 20px;
}

.page-login__social-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.page-login__social-btn {
    width: 100%;
    max-width: 200px;
    padding: 12px 20px;
    border-radius: 6px;
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
}

.page-login__social-btn--facebook {
    background-color: #3b5998;
}

.page-login__social-btn--google {
    background-color: #ea4335;
}

.page-login__no-account-text {
    margin-top: 30px;
    color: var(--page-login-text-secondary);
}

.page-login__register-link {
    color: var(--page-login-primary-color);
    text-decoration: none;
    font-weight: 600;
}

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

/* Benefits Section */
.page-login__benefits-section {
    background-color: var(--page-login-bg); /* Use page background for section */
    padding: 80px 0;
}

.page-login__dark-section {
    background-color: var(--page-login-deep-green); /* A darker green for contrast sections */
    color: var(--page-login-text-main);
}

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

.page-login__benefit-card,
.page-login__security-item,
.page-login__promo-card {
    background-color: var(--page-login-card-bg); /* Card background */
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    border: 1px solid var(--page-login-border-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start; /* Align content to top */
}

.page-login__benefit-icon {
    width: 200px; /* Min size 200x200 */
    height: 200px;
    object-fit: contain;
    margin-bottom: 20px;
    border-radius: 8px; /* Slightly rounded corners for icons */
}

.page-login__benefit-title,
.page-login__security-title,
.page-login__promo-title {
    font-size: 1.5em;
    color: var(--page-login-text-main);
    margin-bottom: 15px;
    font-weight: 600;
}

.page-login__benefit-text,
.page-login__security-text,
.page-login__promo-text {
    color: var(--page-login-text-secondary);
    font-size: 1em;
    flex-grow: 1; /* Allow text to grow and push CTA to bottom */
}

/* Security Section */
.page-login__security-section {
    padding: 80px 0;
    background-color: var(--page-login-bg);
}

/* Promotions Section */
.page-login__promotions-section {
    padding: 80px 0;
    background-color: var(--page-login-deep-green);
}

.page-login__promo-image {
    width: 100%;
    height: auto;
    max-height: 300px; /* Constrain image height in card */
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
}

.page-login__promo-card .page-login__btn-primary {
    margin-top: 20px;
    width: auto; /* Allow button to size to content */
    align-self: center;
}

.page-login__cta-bottom {
    text-align: center;
    margin-top: 60px;
}

/* FAQ Section */
.page-login__faq-section {
    padding: 80px 0;
    background-color: var(--page-login-bg);
}

.page-login__faq-list {
    max-width: 800px;
    margin: 40px auto 0 auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.page-login__faq-item {
    background-color: var(--page-login-card-bg);
    border-radius: 12px;
    border: 1px solid var(--page-login-border-color);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    color: var(--page-login-text-main);
}

.page-login__faq-item summary {
    list-style: none; /* Hide default marker */
    padding: 20px 25px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 1.1em;
    color: var(--page-login-text-main);
}

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

.page-login__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.page-login__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    margin-left: 15px;
    transition: transform 0.3s ease;
}

.page-login__faq-item[open] .page-login__faq-toggle {
    transform: rotate(45deg); /* Rotate '+' to 'x' or just change to '-' */
}

.page-login__faq-answer {
    padding: 0 25px 20px 25px;
    color: var(--page-login-text-secondary);
    font-size: 0.95em;
    line-height: 1.6;
    border-top: 1px solid var(--page-login-divider-color);
    margin-top: -1px; /* Overlap border for cleaner look */
}

/* CTA Section */
.page-login__cta-section {
    padding: 80px 0;
    text-align: center;
    background-color: var(--page-login-deep-green);
}

.page-login__cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 40px;
    flex-wrap: wrap;
}

/* Responsive Design - Desktop first, then adjust for smaller screens */
@media (min-width: 769px) {
    .page-login__hero-section {
        flex-direction: row; /* Horizontal layout for desktop */
        text-align: left;
        padding: 80px 20px;
        gap: 40px;
        align-items: center;
        justify-content: space-between;
    }

    .page-login__hero-content {
        flex: 1;
        margin-bottom: 0;
        text-align: left;
    }

    .page-login__hero-image-wrapper {
        flex: 1;
        margin-top: 0;
        max-width: 50%; /* Image takes half width */
    }

    .page-login__main-title {
        text-align: left;
    }

    .page-login__description {
        text-align: left;
    }

    .page-login__hero-buttons {
        justify-content: flex-start;
    }
}

/* Mobile Specific Styles */
@media (max-width: 768px) {
    .page-login {
        font-size: 15px;
        line-height: 1.5;
    }

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

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

    .page-login__main-title {
        font-size: clamp(1.8em, 8vw, 2.5em);
        margin-bottom: 15px;
    }

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

    .page-login__hero-buttons,
    .page-login__social-buttons,
    .page-login__cta-buttons {
        flex-direction: column;
        gap: 15px;
        width: 100%; /* Ensure button groups take full width */
    }

    .page-login__btn-primary,
    .page-login__btn-secondary,
.page-login__submit-button,
    .page-login__social-btn,
    .page-login a[class*="button"],
    .page-login a[class*="btn"] {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 20px !important;
        font-size: 0.95em !important;
    }

    .page-login__hero-image-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        margin-top: 20px;
    }

    .page-login__hero-image,
    .page-login img,
    .page-login video { /* Apply to all images/videos */
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
        box-sizing: border-box !important;
    }

    .page-login__section,
    .page-login__card,
    .page-login__container,
    .page-login__form-wrapper,
    .page-login__benefits-section,
    .page-login__security-section,
    .page-login__promotions-section,
    .page-login__faq-section,
    .page-login__cta-section,
    .page-login__video-section, /* If video was present */
    .page-login__video-container, /* If video was present */
    .page-login__video-wrapper /* If video was present */
    {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow: hidden !important; /* Prevent horizontal scroll */
    }

    .page-login__section-title {
        font-size: 2em;
        padding-top: 30px;
    }

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

    .page-login__form-wrapper {
        padding: 30px 20px;
    }

    .page-login__faq-item summary {
        font-size: 1em;
        padding: 15px 20px;
    }

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

    .page-login__benefit-icon {
        width: 150px; /* Adjust min size for mobile if needed, but still >= 200px if possible */
        height: 150px;
    }
}