/* style/about.css */

/* Base styles for the about page */
.page-about {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333333; /* Default text color for light background */
    background-color: #ffffff; /* Explicitly set for clarity */
}

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

.page-about__section {
    padding: 80px 0;
    text-align: center;
}

.page-about__section-title {
    font-size: 2.8em;
    margin-bottom: 40px;
    color: #017439; /* Brand color for titles */
    font-weight: bold;
}

/* Hero Section */
.page-about__hero-section {
    position: relative;
    width: 100%;
    height: 100vh; /* Full viewport height */
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    text-align: center;
    overflow: hidden;
    padding-top: var(--header-offset, 120px); /* Ensure content is below fixed header */
}

.page-about__hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.page-about__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-about__hero-content {
    position: relative;
    z-index: 3;
    max-width: 900px;
}

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

.page-about__hero-description {
    font-size: 1.4em;
    margin-bottom: 40px;
    color: #f0f0f0;
}

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

/* Buttons */
.page-about__btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1em;
    transition: background-color 0.3s ease, color 0.3s ease;
    cursor: pointer;
    box-sizing: border-box; /* Crucial for responsive buttons */
}

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

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

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

.page-about__btn-secondary:hover {
    background-color: #ffffff;
    color: #017439;
}

.page-about__btn-video-cta {
    margin-top: 30px;
}

.page-about__btn-large {
    padding: 18px 40px;
    font-size: 1.2em;
}

/* Content Grid */
.page-about__content-grid {
    display: flex;
    align-items: center;
    gap: 40px;
    text-align: left;
    margin-top: 40px;
}

.page-about__content-grid:nth-of-type(odd) {
    flex-direction: row;
}

.page-about__content-grid:nth-of-type(even) {
    flex-direction: row-reverse; /* Alternate image/text on even sections */
}

.page-about__text-block {
    flex: 1;
    padding: 20px 0;
}

.page-about__text-block p {
    margin-bottom: 15px;
    font-size: 1.1em;
}

.page-about__image-block {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.page-about__image {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Dark Sections */
.page-about__dark-section {
    background-color: #017439; /* Primary brand color */
    color: #ffffff;
}

.page-about__dark-section .page-about__section-title {
    color: #ffffff;
}

.page-about__dark-section .page-about__link {
    color: #FFFF00; /* Contrast for links on dark background */
}

.page-about__dark-section .page-about__link:hover {
    text-decoration: underline;
}

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

.page-about__feature-card {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 10px;
    text-align: left;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    color: #ffffff;
    height: 100%; /* Ensure cards have equal height */
    box-sizing: border-box;
}

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

.page-about__feature-card p {
    font-size: 1.05em;
    margin-bottom: 20px;
    flex-grow: 1;
}

.page-about__feature-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-top: auto; /* Push image to bottom of card */
}

/* Video Section */
.page-about__video-section {
    padding: 60px 0;
    text-align: center;
    background-color: #017439; /* Ensure consistent dark background */
    color: #ffffff;
}

.page-about__video-title {
    font-size: 2.2em;
    margin-bottom: 30px;
    color: #ffffff;
}

.page-about__video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    max-width: 900px; /* Limit video width */
    margin: 0 auto;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.page-about__video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    cursor: pointer; /* Indicate it's clickable */
}

.page-about__video-description {
    font-size: 1.1em;
    margin-top: 20px;
    color: #f0f0f0;
}

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

.page-about__faq-item {
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.page-about__faq-item summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    cursor: pointer;
    font-size: 1.2em;
    font-weight: bold;
    color: #333333;
    outline: none;
    list-style: none; /* Remove default marker */
}

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

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

.page-about__faq-item[open] .page-about__faq-toggle {
    transform: rotate(45deg); /* Rotate + to become X or - */
}

.page-about__faq-answer {
    padding: 0 25px 20px 25px;
    font-size: 1.05em;
    color: #555555;
}

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

/* Final CTA Section */
.page-about__cta-final {
    padding: 100px 0;
}

.page-about__cta-content {
    max-width: 800px;
    margin: 0 auto;
}

.page-about__cta-description {
    font-size: 1.3em;
    margin-bottom: 40px;
    color: #f0f0f0;
}

/* Links */
.page-about__link {
    color: #017439;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-about__link:hover {
    color: #005f2e;
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-about__hero-title {
        font-size: 3em;
    }
    .page-about__hero-description {
        font-size: 1.2em;
    }
    .page-about__section-title {
        font-size: 2.5em;
    }
    .page-about__content-grid {
        flex-direction: column;
        gap: 30px;
    }
    .page-about__content-grid:nth-of-type(even) {
        flex-direction: column; /* Reset alternating order for mobile */
    }
    .page-about__image-block,
    .page-about__text-block {
        flex: none;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .page-about__section {
        padding: 60px 0;
    }
    .page-about__hero-section {
        height: 80vh;
        padding-top: var(--header-offset, 120px) !important; /* Mobile header offset */
    }
    .page-about__hero-title {
        font-size: 2.2em;
    }
    .page-about__hero-description {
        font-size: 1em;
    }
    .page-about__hero-cta-buttons {
        flex-direction: column;
        gap: 15px;
    }
    .page-about__btn {
        width: 100%;
        max-width: 300px; /* Limit button width for better appearance */
        margin: 0 auto; /* Center buttons */
        padding: 12px 20px;
        font-size: 1em;
        max-width: 100% !important; /* Responsive buttons */
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }
    .page-about__btn-primary,
    .page-about__btn-secondary {
        max-width: 100% !important; /* Ensure buttons don't overflow */
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-about__hero-cta-buttons {
        flex-wrap: wrap !important;
        gap: 10px !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    .page-about__section-title {
        font-size: 2em;
    }
    .page-about__feature-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .page-about__feature-card {
        padding: 20px;
    }
    .page-about__feature-title {
        font-size: 1.5em;
    }
    .page-about__faq-item summary {
        font-size: 1.1em;
        padding: 15px 20px;
    }
    .page-about__faq-answer {
        padding: 0 20px 15px 20px;
    }
    .page-about__video-section {
        padding-top: var(--header-offset, 120px) !important; /* Mobile video section header offset */
        padding-left: 15px;
        padding-right: 15px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
    }
    .page-about video,
    .page-about__video {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-about__video-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
    }
    /* Global content area image and container responsive styles */
    .page-about img {
        max-width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-about__section,
    .page-about__card,
    .page-about__container,
    .page-about__content-grid,
    .page-about__feature-grid,
    .page-about__faq-list,
    .page-about__cta-content {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow-x: hidden !important; /* Prevent horizontal scroll */
    }
}

@media (max-width: 480px) {
    .page-about__hero-title {
        font-size: 1.8em;
    }
    .page-about__hero-description {
        font-size: 0.9em;
    }
    .page-about__section-title {
        font-size: 1.8em;
    }
    .page-about__feature-title {
        font-size: 1.3em;
    }
    .page-about__btn {
        padding: 10px 15px;
        font-size: 0.9em;
    }
}

/* Ensure no filter on images */
.page-about img {
    filter: none !important;
}

/* Specific styles for text contrast on light background */
.page-about p,
.page-about li,
.page-about__text-block p,
.page-about__faq-answer p {
    color: #333333;
}

/* Ensure content area images are not too small */
.page-about__content-area img,
.page-about__story-mission .page-about__image,
.page-about__team .page-about__image,
.page-about__responsible-gambling .page-about__image,
.page-about__support-community .page-about__image,
.page-about__future-vision .page-about__image {
    min-width: 200px;
    min-height: 200px;
    object-fit: cover;
}