/* style/download.css */
.page-download {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #F2FFF6; /* Text Main */
    background-color: #08160F; /* Background */
    padding-top: 10px; /* Small top padding, assuming body handles --header-offset */
}

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

.page-download__hero-section {
    position: relative;
    padding: 60px 0;
    text-align: center;
    overflow: hidden;
    background-color: #08160F; /* Background */
}

.page-download__hero-content {
    max-width: 800px;
    margin: 0 auto 40px;
    position: relative;
    z-index: 2;
}

.page-download__main-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem); /* Using clamp for responsive H1 */
    font-weight: 700;
    color: #F2FFF6; /* Text Main */
    margin-bottom: 20px;
    line-height: 1.2;
}

.page-download__subtitle {
    font-size: 1.15rem;
    color: #A7D9B8; /* Text Secondary */
    margin-bottom: 30px;
}

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

.page-download__btn-primary,
.page-download__btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    cursor: pointer;
    white-space: nowrap;
    box-sizing: border-box;
    min-width: 200px; /* Ensure minimum button width */
}

.page-download__btn-primary {
    background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%); /* Button color */
    color: #F2FFF6; /* Text Main */
    border: none;
}

.page-download__btn-primary:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
}

.page-download__btn-secondary {
    background: transparent;
    color: #2AD16F; /* Button color */
    border: 2px solid #2AD16F; /* Deep Green */
}

.page-download__btn-secondary:hover {
    background: #2AD16F;
    color: #F2FFF6;
}

.page-download__hero-image-wrapper {
    margin-top: 40px;
    position: relative;
    z-index: 1;
}

.page-download__hero-image {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    display: block; /* Ensure it behaves as a block element for max-width */
    margin: 0 auto;
}

.page-download__section-title {
    font-size: clamp(2rem, 4vw, 2.8rem);
    color: #F2FFF6; /* Text Main */
    text-align: center;
    margin-bottom: 25px;
    font-weight: 700;
}

.page-download__section-description {
    font-size: 1.1rem;
    color: #A7D9B8; /* Text Secondary */
    text-align: center;
    max-width: 900px;
    margin: 0 auto 50px;
}

/* General section styling */
.page-download__advantages-section,
.page-download__how-to-download-section,
.page-download__game-types-section,
.page-download__promotions-section,
.page-download__faq-section,
.page-download__contact-cta-section {
    padding: 80px 0;
}

.page-download__dark-bg {
    background-color: #08160F; /* Background */
    color: #F2FFF6; /* Text Main */
}

.page-download__light-bg {
    background-color: #11271B; /* Card BG */
    color: #F2FFF6; /* Text Main */
}

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

.page-download__card {
    background-color: #11271B; /* Card BG */
    border: 1px solid #2E7A4E; /* Border */
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #F2FFF6; /* Text Main */
    height: 100%; /* Ensure cards are same height in a row */
    box-sizing: border-box;
}

.page-download__card-icon {
    width: 100%; /* Max width for image within card */
    max-width: 250px;
    height: auto;
    border-radius: 8px;
    margin-bottom: 20px;
    min-height: 200px; /* Enforce min image size */
    object-fit: cover;
}

.page-download__card-title {
    font-size: 1.5rem;
    color: #F2FFF6; /* Text Main */
    margin-bottom: 15px;
    font-weight: 600;
}

.page-download__card-text {
    font-size: 1rem;
    color: #A7D9B8; /* Text Secondary */
    flex-grow: 1; /* Allow text to grow */
}

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

.page-download__step-card {
    text-align: left;
    padding: 35px;
}

.page-download__step-list {
    list-style: none;
    padding: 0;
    margin-bottom: 30px;
    counter-reset: step-counter;
}

.page-download__step-list li {
    font-size: 1rem;
    color: #A7D9B8; /* Text Secondary */
    margin-bottom: 15px;
    position: relative;
    padding-left: 30px;
}

.page-download__step-list li::before {
    content: counter(step-counter);
    counter-increment: step-counter;
    position: absolute;
    left: 0;
    top: 0;
    background-color: #13994A; /* Deep Green */
    color: #F2FFF6; /* Text Main */
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.page-download__qr-code-wrapper {
    margin: 30px auto;
    width: 200px; /* Fixed width for QR code */
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #fff; /* White background for QR code */
    border-radius: 8px;
    padding: 10px;
}

.page-download__qr-code {
    width: 100%;
    height: 100%;
    object-fit: contain;
    min-width: 200px;
    min-height: 200px;
}

.page-download__btn-full-width {
    width: 100%;
    max-width: 100%; /* Ensure it doesn't overflow */
    margin-top: auto; /* Push button to bottom if card height varies */
}

.page-download__game-type-card {
    padding-bottom: 20px; /* Adjust padding for button */
}

.page-download__game-type-card .page-download__btn-secondary {
    margin-top: 20px;
}

.page-download__cta-buttons--center {
    margin-top: 50px;
}

.page-download__flex-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* FAQ Styling */
details.page-download__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  border: 1px solid #2E7A4E; /* Border */
  overflow: hidden;
  background: #11271B; /* Card BG */
}
details.page-download__faq-item summary.page-download__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease;
  color: #F2FFF6; /* Text Main */
}
details.page-download__faq-item summary.page-download__faq-question::-webkit-details-marker {
  display: none;
}
details.page-download__faq-item summary.page-download__faq-question:hover {
  background: #1E3A2A; /* Slightly darker for hover */
}
.page-download__faq-qtext {
  flex: 1;
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  color: #F2FFF6; /* Text Main */
}
.page-download__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: #2AD16F; /* Button color */
  flex-shrink: 0;
  margin-left: 15px;
  width: 28px;
  text-align: center;
}
details.page-download__faq-item .page-download__faq-answer {
  padding: 0 20px 20px;
  background: #0A4B2C; /* Deep Green for answer background */
  border-radius: 0 0 5px 5px;
  color: #A7D9B8; /* Text Secondary */
}
.page-download__faq-answer p {
    margin-top: 0;
    margin-bottom: 10px;
}
.page-download__faq-answer a {
    color: #57E38D; /* Glow color for links */
    text-decoration: underline;
}
.page-download__faq-answer a:hover {
    color: #2AD16F;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-download__main-title {
        font-size: clamp(2.2rem, 6vw, 3rem);
    }
    .page-download__section-title {
        font-size: clamp(1.8rem, 5vw, 2.5rem);
    }
    .page-download__advantages-section,
    .page-download__how-to-download-section,
    .page-download__game-types-section,
    .page-download__promotions-section,
    .page-download__faq-section,
    .page-download__contact-cta-section {
        padding: 60px 0;
    }
}

@media (max-width: 768px) {
    .page-download {
        font-size: 16px;
        line-height: 1.6;
    }
    .page-download__container {
        padding: 0 15px;
    }
    .page-download__hero-section {
        padding: 40px 0;
        padding-left: 0;
        padding-right: 0;
    }
    .page-download__hero-content {
        padding: 0 15px;
    }
    .page-download__main-title {
        font-size: clamp(1.8rem, 7vw, 2.5rem);
        margin-bottom: 15px;
    }
    .page-download__subtitle {
        font-size: 1rem;
        margin-bottom: 25px;
    }
    .page-download__cta-buttons {
        flex-direction: column;
        gap: 15px;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-download__btn-primary,
    .page-download__btn-secondary {
        max-width: 100% !important;
        width: 100% !important;
        padding: 12px 20px;
        font-size: 1rem;
        white-space: normal !important;
        word-wrap: break-word !important;
        min-width: unset;
    }
    .page-download__hero-image-wrapper {
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-download__section-title {
        font-size: clamp(1.6rem, 6vw, 2.2rem);
        margin-bottom: 20px;
    }
    .page-download__section-description {
        font-size: 0.95rem;
        margin-bottom: 40px;
    }
    .page-download__advantages-grid,
    .page-download__game-types-grid,
    .page-download__promo-grid,
    .page-download__download-steps {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    .page-download__card {
        padding: 25px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    }
    .page-download__card-icon {
        max-width: 180px;
        margin-bottom: 15px;
        min-height: 150px;
    }
    .page-download__card-title {
        font-size: 1.3rem;
        margin-bottom: 10px;
    }
    .page-download__card-text {
        font-size: 0.95rem;
    }
    .page-download__qr-code-wrapper {
        width: 180px;
        height: 180px;
        padding: 8px;
        margin: 25px auto;
    }
    .page-download__qr-code {
        min-width: 180px;
        min-height: 180px;
    }
    .page-download__step-card {
        padding: 25px;
    }
    .page-download__step-list li {
        font-size: 0.95rem;
        margin-bottom: 12px;
        padding-left: 25px;
    }
    .page-download__step-list li::before {
        width: 20px;
        height: 20px;
        font-size: 0.8rem;
    }
    details.page-download__faq-item summary.page-download__faq-question { padding: 15px; }
    .page-download__faq-qtext { font-size: 1rem; }
    .page-download__faq-toggle { font-size: 20px; width: 24px; }
    details.page-download__faq-item .page-download__faq-answer { padding: 0 15px 15px; }

    /* Ensure all images are responsive */
    .page-download img {
      max-width: 100% !important;
      width: 100% !important;
      height: auto !important;
    }
    /* All containers with padding */
    .page-download__section,
    .page-download__card,
    .page-download__container,
    .page-download__hero-section,
    .page-download__advantages-section,
    .page-download__how-to-download-section,
    .page-download__game-types-section,
    .page-download__promotions-section,
    .page-download__faq-section,
    .page-download__contact-cta-section {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-download__hero-section .page-download__container {
        padding-left: 0;
        padding-right: 0;
    }
    .page-download__hero-image-wrapper {
        padding-left: 15px;
        padding-right: 15px;
    }
}