/* style/resources.css */

:root {
  --primary-color: #26A9E0;
  --secondary-color: #FFFFFF;
  --login-color: #EA7C07;
  --background-color-dark: #000000;
  --text-color-light: #ffffff;
  --text-color-dark: #333333;
  --header-offset: 120px; /* Default value, will be overridden by shared.css */
}

/* Base styles for the page content area */
.page-resources {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-color-light); /* Default text color for dark body background */
  background-color: var(--background-color-dark);
  padding-top: var(--header-offset, 120px); /* Ensure content is below fixed header */
}

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

.page-resources__section {
  padding: 60px 0;
  position: relative;
  z-index: 1;
}

.page-resources__section-title,
.page-resources__subsection-title {
  color: var(--primary-color);
  text-align: center;
  margin-bottom: 30px;
  font-size: 2.5em;
  font-weight: bold;
}

.page-resources__subsection-title {
  font-size: 1.8em;
  text-align: left;
  margin-top: 40px;
  margin-bottom: 20px;
  color: var(--secondary-color);
}

.page-resources__paragraph {
  margin-bottom: 15px;
  color: var(--text-color-light);
}

.page-resources__list {
  list-style: disc inside;
  margin-bottom: 15px;
  padding-left: 20px;
  color: var(--text-color-light);
}

.page-resources__list-item {
  margin-bottom: 8px;
  color: var(--text-color-light);
}

/* Hero Section */
.page-resources__hero-section {
  position: relative;
  width: 100%;
  height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  padding: 0 20px; /* Add padding for mobile responsiveness */
  box-sizing: border-box;
}

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

.page-resources__hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 0;
}

.page-resources__hero-title {
  font-size: 3.5em;
  color: var(--secondary-color);
  margin-bottom: 20px;
  z-index: 1;
  position: relative;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-resources__hero-description {
  font-size: 1.2em;
  color: var(--secondary-color);
  margin-bottom: 40px;
  z-index: 1;
  position: relative;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-resources__hero-buttons {
  z-index: 1;
  position: relative;
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Buttons */
.page-resources__btn-primary,
.page-resources__btn-secondary {
  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, border-color 0.3s ease;
  text-align: center;
  box-sizing: border-box;
  max-width: 100%; /* Ensure responsiveness */
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text breaking */
}

.page-resources__btn-primary {
  background-color: var(--primary-color);
  color: var(--secondary-color);
  border: 2px solid var(--primary-color);
}

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

.page-resources__btn-secondary {
  background-color: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.page-resources__btn-secondary:hover {
  background-color: var(--primary-color);
  color: var(--secondary-color);
}

/* Content Grid for images and text blocks */
.page-resources__content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
  margin-top: 40px;
}

.page-resources__content-grid--reverse {
  grid-template-areas: "image text"; /* Default order */
}

.page-resources__content-grid--reverse .page-resources__text-block {
  grid-area: text;
}

.page-resources__content-grid--reverse .page-resources__image-wrapper {
  grid-area: image;
}

.page-resources__image-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-resources__image-content {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  object-fit: cover;
}

/* Video Section */
.page-resources__video-wrapper {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  margin: 40px auto;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  max-width: 1200px; /* Limit video width */
}

.page-resources__video-link-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  z-index: 2;
  text-decoration: none;
}

.page-resources__video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
  z-index: 1;
}

.page-resources__video-play-button {
  position: absolute;
  font-size: 5em;
  color: var(--secondary-color);
  opacity: 0.8;
  transition: opacity 0.3s ease;
  z-index: 3;
}

.page-resources__video-link-overlay:hover .page-resources__video-play-button {
  opacity: 1;
}

.page-resources__paragraph--video-caption {
  text-align: center;
  font-style: italic;
  margin-top: 10px;
  color: var(--text-color-light);
}

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

.page-resources__faq-item {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-resources__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  cursor: pointer;
  font-weight: bold;
  font-size: 1.1em;
  color: var(--secondary-color);
  background-color: rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  list-style: none; /* For details/summary */
}

.page-resources__faq-question::-webkit-details-marker {
  display: none;
}

.page-resources__faq-qtext {
  flex-grow: 1;
}

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

.page-resources__faq-item[open] .page-resources__faq-toggle {
  transform: rotate(45deg);
}

.page-resources__faq-answer {
  padding: 0 20px 20px 20px;
  color: var(--text-color-light);
}

/* CTA Section */
.page-resources__section--cta {
  background-color: var(--primary-color);
  text-align: center;
  padding: 80px 0;
  position: relative;
  overflow: hidden;
  margin-top: 60px;
}

.page-resources__cta-container {
  position: relative;
  z-index: 2;
}

.page-resources__cta-title {
  font-size: 3em;
  color: var(--secondary-color);
  margin-bottom: 20px;
}

.page-resources__cta-description {
  font-size: 1.2em;
  color: var(--secondary-color);
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

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

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

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

  .page-resources__section-title {
    font-size: 2em;
  }

  .page-resources__subsection-title {
    font-size: 1.6em;
  }

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

  .page-resources__content-grid--reverse {
    grid-template-areas: unset; /* Reset grid area order */
  }
}

@media (max-width: 768px) {
  .page-resources {
    font-size: 16px;
    line-height: 1.6;
    padding-top: var(--header-offset, 120px) !important; /* Ensure content is below fixed header on mobile */
  }

  .page-resources__container {
    padding: 0 15px !important;
  }

  .page-resources__hero-section {
    height: 500px;
  }

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

  .page-resources__hero-description {
    font-size: 1em;
  }

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

  .page-resources__btn-primary,
  .page-resources__btn-secondary,
  .page-resources a[class*="button"],
  .page-resources a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-resources__section-title {
    font-size: 1.8em;
  }

  .page-resources__subsection-title {
    font-size: 1.4em;
  }

  .page-resources__image-content,
  .page-resources video,
  .page-resources__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-resources__image-wrapper,
  .page-resources__video-wrapper,
  .page-resources__section,
  .page-resources__card,
  .page-resources__container,
  .page-resources__cta-buttons,
  .page-resources__button-group,
  .page-resources__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important; /* Prevent horizontal scroll */
  }

  .page-resources__faq-question {
    font-size: 1em;
    padding: 15px;
  }

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

  .page-resources__cta-title {
    font-size: 2.2em;
  }

  .page-resources__cta-description {
    font-size: 1em;
  }
}

@media (max-width: 480px) {
  .page-resources__hero-section {
    height: 400px;
  }

  .page-resources__hero-title {
    font-size: 2em;
  }

  .page-resources__hero-description {
    font-size: 0.9em;
  }

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

  .page-resources__subsection-title {
    font-size: 1.2em;
  }

  .page-resources__btn-primary,
  .page-resources__btn-secondary {
    padding: 12px 20px;
    font-size: 1em;
  }
}