/* style/resources.css */

/* --- General Page Styling --- */
.page-resources {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Dark body background #1a1a2e, so text is white */
  background-color: transparent; /* Body background handled by shared.css */
}

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

.page-resources__section {
  padding: 60px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.page-resources__section--intro {
  background-color: rgba(1, 116, 57, 0.1); /* Slight brand color tint for contrast */
}

.page-resources__section--strategies {
  background-color: rgba(0, 0, 0, 0.2);
}

.page-resources__section--how-to-play {
  background-color: rgba(1, 116, 57, 0.15);
}

.page-resources__section--other-games {
  background-color: rgba(0, 0, 0, 0.25);
}

.page-resources__section--faq {
  background-color: rgba(1, 116, 57, 0.2);
}

.page-resources__section--cta {
  background-color: #017439; /* Brand primary color for CTA */
  color: #ffffff;
  padding: 80px 0;
  text-align: center;
}

.page-resources__heading {
  font-size: 2.5em;
  color: #ffffff;
  text-align: center;
  margin-bottom: 40px;
  font-weight: bold;
}

.page-resources__paragraph {
  font-size: 1.1em;
  margin-bottom: 20px;
  color: #f0f0f0;
}

.page-resources__highlight {
  color: #FFFF00; /* Highlight color for keywords */
  font-weight: bold;
}

.page-resources__link {
  color: #FFFF00; /* Link color for visibility */
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-resources__link:hover {
  color: #C30808; /* Hover effect with login/register color */
  text-decoration: underline;
}

/* --- Hero Section --- */
.page-resources__hero-section {
  position: relative;
  width: 100%;
  height: 600px; /* Fixed height for hero */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  color: #ffffff;
  padding-top: var(--header-offset, 120px); /* Fixed header offset */
  box-sizing: border-box;
}

.page-resources__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  filter: brightness(0.6); /* Darken image for text readability */
}

.page-resources__hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(rgba(0,0,0,0.5), rgba(1, 116, 57, 0.7)); /* Gradient overlay */
  z-index: 2;
}

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

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

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

.page-resources__hero-actions {
  display: flex;
  gap: 20px;
  justify-content: center;
}

/* --- Buttons --- */
.page-resources__btn-primary,
.page-resources__btn-secondary,
.page-resources__cta-button {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: all 0.3s ease;
  cursor: pointer;
  max-width: 100%; /* Ensures responsiveness */
  box-sizing: border-box; /* Includes padding in width calculation */
  white-space: normal; /* Allows text to wrap */
  word-wrap: break-word; /* Breaks long words */
}

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

.page-resources__btn-primary:hover {
  background-color: #ff3333;
  border-color: #ff3333;
}

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

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

/* --- Lists --- */
.page-resources__list,
.page-resources__ordered-list {
  list-style-type: disc;
  margin-left: 20px;
  margin-bottom: 20px;
  color: #f0f0f0;
}

.page-resources__ordered-list {
  list-style-type: decimal;
}

.page-resources__list-item {
  margin-bottom: 10px;
  font-size: 1.1em;
}

/* --- Image and Video Styling --- */
.page-resources__image-wrapper {
  margin: 40px 0;
  text-align: center;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  box-sizing: border-box;
}

.page-resources__image {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 8px;
  object-fit: cover;
  min-width: 200px; /* Minimum size requirement */
  min-height: 200px; /* Minimum size requirement */
}

.page-resources__video-wrapper {
  position: relative;
  width: 100%;
  max-width: 100%;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  margin: 40px 0;
  border-radius: 8px;
  box-sizing: border-box;
}

.page-resources__video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
  min-width: 200px; /* Minimum size requirement */
  min-height: 200px; /* Minimum size requirement */
}


/* --- Other Games Section --- */
.page-resources__game-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
  list-style: none;
  padding: 0;
}

.page-resources__game-item {
  background-color: rgba(255, 255, 255, 0.08); /* Card background */
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.page-resources__game-item:hover {
  transform: translateY(-5px);
  background-color: rgba(255, 255, 255, 0.15);
}

.page-resources__game-title {
  font-size: 1.8em;
  margin-bottom: 15px;
  color: #FFFF00; /* Highlight game titles */
}

.page-resources__game-title a {
  color: inherit;
  text-decoration: none;
}

.page-resources__game-title a:hover {
  text-decoration: underline;
}

.page-resources__game-description {
  font-size: 1em;
  color: #e0e0e0;
}

/* --- FAQ Section --- */
.page-resources__faq-list {
  margin-top: 40px;
}

.page-resources__faq-item {
  background-color: rgba(255, 255, 255, 0.08); /* Card background */
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.page-resources__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  cursor: pointer;
  background-color: rgba(1, 116, 57, 0.3); /* Brand color for question background */
  transition: background-color 0.3s ease;
}

.page-resources__faq-question:hover {
  background-color: rgba(1, 116, 57, 0.5);
}

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

.page-resources__faq-toggle {
  font-size: 1.8em;
  font-weight: bold;
  color: #FFFF00;
  transition: transform 0.3s ease;
}

.page-resources__faq-item.active .page-resources__faq-toggle {
  transform: rotate(45deg); /* Rotate for 'x' or '-' effect */
}

.page-resources__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 25px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  color: #e0e0e0;
}

.page-resources__faq-item.active .page-resources__faq-answer {
  max-height: 1000px !important; /* Sufficiently large value */
  padding: 15px 25px 25px;
}

.page-resources__faq-answer .page-resources__paragraph {
  margin-bottom: 0;
}

/* --- CTA Section --- */
.page-resources__container--flex {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}

.page-resources__cta-content {
  max-width: 800px;
}

.page-resources__cta-content .page-resources__heading {
  margin-bottom: 20px;
}

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


/* --- Responsive Design --- */
@media (max-width: 1024px) {
  .page-resources__hero-title {
    font-size: 3em;
  }
  .page-resources__hero-description {
    font-size: 1.1em;
  }
  .page-resources__heading {
    font-size: 2em;
  }
}

@media (max-width: 768px) {
  .page-resources {
    font-size: 16px;
    line-height: 1.6;
  }

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

  .page-resources__hero-title {
    font-size: 2.2em;
    margin-bottom: 15px;
  }

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

  .page-resources__hero-actions {
    flex-direction: column;
    gap: 15px;
  }

  .page-resources__btn-primary,
  .page-resources__btn-secondary,
  .page-resources__cta-button {
    max-width: 100% !important;
    width: 100% !important;
    padding: 12px 20px;
    font-size: 1em;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-resources__container,
  .page-resources__image-wrapper,
  .page-resources__video-wrapper,
  .page-resources__game-list,
  .page-resources__faq-list,
  .page-resources__cta-actions {
    padding-left: 15px;
    padding-right: 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .page-resources__section {
    padding: 40px 0;
  }

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

  .page-resources__paragraph,
  .page-resources__list-item,
  .page-resources__game-description {
    font-size: 1em;
  }

  .page-resources__image {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    min-width: 200px !important;
    min-height: 200px !important;
  }

  .page-resources__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
    min-width: 200px !important;
    min-height: 200px !important;
  }

  .page-resources__game-list {
    grid-template-columns: 1fr;
  }

  .page-resources__faq-question {
    padding: 15px 20px;
  }

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

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

  .page-resources__faq-item.active .page-resources__faq-answer {
    padding: 15px 20px 20px;
  }
}

@media (max-width: 480px) {
  .page-resources__hero-section {
    height: 400px;
  }
  .page-resources__hero-title {
    font-size: 1.8em;
  }
  .page-resources__hero-description {
    font-size: 0.9em;
  }
  .page-resources__btn-primary,
  .page-resources__btn-secondary,
  .page-resources__cta-button {
    padding: 10px 15px;
    font-size: 0.9em;
  }
}