/* style/about.css */

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

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

/* Section titles */
.page-about__section-title {
    font-size: 2.5em;
    color: #ffffff; /* Default for dark sections */
    text-align: center;
    margin-bottom: 40px;
    font-weight: bold;
}

.page-about__section-intro {
    font-size: 1.1em;
    text-align: center;
    max-width: 800px;
    margin: 0 auto 50px auto;
    color: rgba(255, 255, 255, 0.8);
}

/* Sub-titles */
.page-about__sub-title {
    font-size: 1.8em;
    font-weight: bold;
    margin-top: 30px;
    margin-bottom: 15px;
    color: #017439; /* Brand color for headings in light sections */
}

/* Buttons */
.page-about__btn-primary,
.page-about__btn-secondary {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
    box-sizing: border-box;
    max-width: 100%;
    white-space: normal;
    word-wrap: break-word;
}

.page-about__btn-primary {
    background: #C30808; /* Custom color for Register/Login */
    color: #FFFF00; /* Custom font color for Register/Login */
    border: 2px solid #C30808;
}

.page-about__btn-primary:hover {
    background: #a30606;
    border-color: #a30606;
}

.page-about__btn-secondary {
    background: #ffffff;
    color: #017439;
    border: 2px solid #017439;
}

.page-about__btn-secondary:hover {
    background: #f0f0f0;
    color: #005a2d;
    border-color: #005a2d;
}

/* Color contrast enforcement */
.page-about__dark-section {
    background-color: #1a1a1a; /* Slightly lighter than body background for contrast */
    color: #ffffff;
    padding: 80px 0;
}

.page-about__light-bg {
    background-color: #ffffff;
    color: #333333;
    padding: 80px 0;
}

.page-about__light-bg .page-about__section-title,
.page-about__light-bg .page-about__section-intro {
    color: #333333;
}

.page-about__light-bg .page-about__sub-title {
    color: #017439;
}

/* Hero Section */
.page-about__hero-section {
    position: relative;
    padding-top: 120px; /* Internal padding, assuming shared handles body padding-top */
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    text-align: center;
    background-color: #017439; /* Primary brand color for hero background */
    padding-bottom: 80px;
}

.page-about__hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    opacity: 0.3; /* Make background image subtle */
}

.page-about__hero-content {
    position: relative;
    z-index: 1;
    max-width: 900px;
    padding: 20px;
}

.page-about__hero-title {
    font-size: 3.5em;
    margin-bottom: 20px;
    font-weight: bold;
    color: #ffffff;
}

.page-about__hero-description {
    font-size: 1.3em;
    margin-bottom: 40px;
    color: rgba(255, 255, 255, 0.9);
}

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

/* Vision & Mission Section */
.page-about__vision-mission-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.page-about__vision-mission-text p {
    margin-bottom: 15px;
    color: #555555;
}

.page-about__vision-mission-image-wrapper {
    text-align: center;
}

.page-about__vision-mission-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Why Us Section */
.page-about__feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.page-about__feature-card {
    background-color: rgba(255, 255, 255, 0.08); /* Light background for dark section cards */
    padding: 30px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.page-about__feature-card:hover {
    transform: translateY(-5px);
}

.page-about__feature-icon {
    width: 100%;
    max-width: 400px;
    height: auto;
    border-radius: 5px;
    margin-bottom: 20px;
    object-fit: cover;
    min-height: 200px; /* Ensure images are not too small */
}

.page-about__card-title {
    font-size: 1.5em;
    font-weight: bold;
    margin-bottom: 15px;
    color: #ffffff;
}

.page-about__feature-card p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 15px;
}

.page-about__feature-card ul {
    list-style: none;
    padding: 0;
    text-align: left;
    width: 100%;
    margin-top: auto; /* Push list to bottom */
}

.page-about__feature-card ul li {
    background: rgba(255, 255, 255, 0.1);
    padding: 8px 15px;
    margin-bottom: 8px;
    border-radius: 4px;
    color: #ffffff;
    font-size: 0.95em;
}

/* History Section */
.page-about__history-content {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.page-about__history-content > p {
    color: #555555;
    margin-bottom: 30px;
    width: 100%;
}

.page-about__history-image {
    max-width: 100%;
    width: 500px; /* Fixed width for better layout on desktop */
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    flex-shrink: 0; /* Prevent shrinking */
}

.page-about__milestone-item {
    background-color: #f9f9f9;
    padding: 20px;
    border-left: 5px solid #017439;
    margin-bottom: 20px;
    border-radius: 4px;
    flex-grow: 1; /* Allow to grow */
}

.page-about__milestone-year {
    font-size: 1.3em;
    color: #017439;
    margin-bottom: 10px;
}

.page-about__milestone-item p {
    color: #555555;
}

/* Responsible Gaming Section */
.page-about__responsible-gaming-content {
    display: flex;
    gap: 40px;
    align-items: center;
    flex-wrap: wrap;
}

.page-about__responsible-gaming-image {
    max-width: 100%;
    width: 500px; /* Fixed width for better layout on desktop */
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    flex-shrink: 0;
}

.page-about__responsible-gaming-text {
    flex-grow: 1;
}

.page-about__responsible-gaming-text p {
    margin-bottom: 15px;
    color: rgba(255, 255, 255, 0.8);
}

.page-about__responsible-gaming-text ul {
    list-style: disc;
    margin-left: 20px;
    margin-bottom: 20px;
    color: rgba(255, 255, 255, 0.9);
}

.page-about__responsible-gaming-text ul li {
    margin-bottom: 8px;
}

/* CTA Section */
.page-about__cta-section {
    background-color: #f0f0f0; /* Light background for CTA */
    color: #333333;
    padding: 80px 0;
}

.page-about__cta-section .page-about__section-title,
.page-about__cta-section .page-about__section-intro {
    color: #333333;
}

.page-about__cta-content {
    display: flex;
    gap: 40px;
    align-items: center;
    flex-wrap: wrap;
}

.page-about__cta-image {
    max-width: 100%;
    width: 500px; /* Fixed width for better layout on desktop */
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
}

.page-about__cta-text {
    flex-grow: 1;
    text-align: center;
}

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

/* FAQ Section */
.page-about__faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.page-about__faq-item {
    background-color: rgba(255, 255, 255, 0.08);
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.page-about__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    cursor: pointer;
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.page-about__faq-question:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

.page-about__faq-title {
    margin: 0;
    font-size: 1.2em;
    color: #ffffff;
}

.page-about__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    transition: transform 0.3s ease;
}

.page-about__faq-item.active .page-about__faq-toggle {
    transform: rotate(45deg);
}

.page-about__faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 20px;
    transition: max-height 0.3s ease, padding 0.3s ease;
    color: rgba(255, 255, 255, 0.7);
}

.page-about__faq-item.active .page-about__faq-answer {
    max-height: 1000px !important; /* Important to override any other max-height */
    padding: 20px;
    padding-top: 0;
}

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

/* Responsive Styles */
@media (max-width: 1024px) {
    .page-about__hero-title {
        font-size: 3em;
    }
    .page-about__section-title {
        font-size: 2em;
    }
    .page-about__vision-mission-grid,
    .page-about__history-content,
    .page-about__responsible-gaming-content,
    .page-about__cta-content {
        grid-template-columns: 1fr;
        flex-direction: column;
        text-align: center;
    }
    .page-about__vision-mission-image,
    .page-about__history-image,
    .page-about__responsible-gaming-image,
    .page-about__cta-image {
        width: 100%;
        max-width: 600px;
        margin: 0 auto 30px auto;
    }
    .page-about__history-content .page-about__milestone-item {
        width: 100%;
    }
    .page-about__cta-text {
        text-align: center;
    }
}

@media (max-width: 768px) {
    /* Ensure content area does not cause horizontal scroll */
    .page-about__container {
        padding: 0 10px;
    }

    .page-about__dark-section,
    .page-about__light-bg {
        padding: 50px 0;
    }

    .page-about__hero-section {
        padding-top: var(--header-offset, 120px) !important; /* Ensure header offset for mobile */
        min-height: 500px;
    }

    .page-about__hero-title {
        font-size: 2.5em;
    }

    .page-about__hero-description {
        font-size: 1.1em;
    }

    .page-about__hero-buttons {
        flex-direction: column;
        gap: 15px;
    }

    .page-about__btn-primary,
    .page-about__btn-secondary {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 15px;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    .page-about__section-title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }

    .page-about__section-intro {
        font-size: 1em;
        margin-bottom: 40px;
    }

    .page-about__sub-title {
        font-size: 1.5em;
    }

    /* Images responsiveness for content area */
    .page-about img {
        max-width: 100% !important;
        height: auto !important;
        display: block !important;
    }

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

    .page-about__feature-icon {
        min-height: 200px; /* Enforce min size for content images */
    }

    .page-about__vision-mission-image,
    .page-about__history-image,
    .page-about__responsible-gaming-image,
    .page-about__cta-image {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        margin: 0 auto 20px auto !important;
    }

    .page-about__cta-buttons {
        flex-direction: column;
        gap: 15px;
    }

    .page-about__faq-question {
        padding: 15px;
    }

    .page-about__faq-title {
        font-size: 1.1em;
    }

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

    .page-about__faq-item.active .page-about__faq-answer {
        padding: 15px;
        padding-top: 0;
    }

    /* Ensure all content containers have proper mobile padding and max-width */
    .page-about__section,
    .page-about__card,
    .page-about__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-about__hero-section,
    .page-about__vision-mission-section,
    .page-about__why-us-section,
    .page-about__history-section,
    .page-about__responsible-gaming-section,
    .page-about__cta-section,
    .page-about__faq-section {
        padding-left: 0;
        padding-right: 0;
    }
}