/* style/match-analysis.css */

:root {
  --primary-color: #26A9E0;
  --secondary-color: #FFFFFF;
  --login-color: #EA7C07;
  --background-color: #FFFFFF;
  --text-dark: #333333;
  --text-light: #f0f0f0;
  --card-bg-dark: rgba(255, 255, 255, 0.08);
  --card-bg-light: #FFFFFF;
  --border-color: #e0e0e0;
}

/* Body background is var(--black-color) from shared.css, which is dark. */
/* Therefore, default text color for main content should be light. */
.page-match-analysis {
  color: var(--text-light); /* Light text for dark body background */
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  background-color: transparent; /* Body handles actual background */
}

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

.page-match-analysis__section-title {
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 700;
  text-align: center;
  margin-bottom: 40px;
  color: var(--secondary-color); /* White for dark sections */
  line-height: 1.2;
}

.page-match-analysis__sub-title {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 600;
  margin-top: 30px;
  margin-bottom: 20px;
  color: var(--secondary-color); /* White for dark sections */
}

.page-match-analysis__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 10px; /* Small top padding, body handles header offset */
  padding-bottom: 60px;
  background-color: #1a1a1a; /* A dark background for the hero section */
  overflow: hidden;
}

.page-match-analysis__hero-image-wrapper {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
}

.page-match-analysis__hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.4); /* Darken image for text readability */
}

.page-match-analysis__hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 900px;
  padding: 40px 20px;
  box-sizing: border-box;
}

.page-match-analysis__main-title {
  font-size: clamp(32px, 5vw, 58px);
  font-weight: 800;
  color: var(--secondary-color);
  margin-bottom: 20px;
  line-height: 1.1;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.page-match-analysis__description {
  font-size: clamp(16px, 2vw, 20px);
  color: var(--text-light);
  margin-bottom: 30px;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

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

.page-match-analysis__btn-primary,
.page-match-analysis__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  min-width: 180px;
  text-align: center;
  box-sizing: border-box;
  max-width: 100%; /* Ensure responsiveness */
  white-space: normal;
  word-wrap: break-word;
}

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

.page-match-analysis__btn-primary:hover {
  background-color: #1e87b7;
  border-color: #1e87b7;
  transform: translateY(-2px);
}

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

.page-match-analysis__btn-secondary:hover {
  background-color: var(--primary-color);
  color: var(--secondary-color);
  transform: translateY(-2px);
}

.page-match-analysis__btn-full-width {
  width: 100%;
  max-width: 300px; /* Limit max width for aesthetic */
  margin-top: 20px;
}

.page-match-analysis__introduction-section,
.page-match-analysis__methods-section,
.page-match-analysis__mistakes-section,
.page-match-analysis__conclusion-section {
  padding: 60px 0;
  background-color: var(--card-bg-light); /* Light background for contrast */
  color: var(--text-dark); /* Dark text on light background */
}

.page-match-analysis__introduction-section .page-match-analysis__section-title,
.page-match-analysis__methods-section .page-match-analysis__section-title,
.page-match-analysis__mistakes-section .page-match-analysis__section-title,
.page-match-analysis__conclusion-section .page-match-analysis__section-title {
  color: var(--text-dark); /* Dark title on light background */
}

.page-match-analysis__introduction-section a,
.page-match-analysis__methods-section a,
.page-match-analysis__mistakes-section a,
.page-match-analysis__conclusion-section a {
  color: var(--primary-color);
  text-decoration: none;
}

.page-match-analysis__introduction-section a:hover,
.page-match-analysis__methods-section a:hover,
.page-match-analysis__mistakes-section a:hover,
.page-match-analysis__conclusion-section a:hover {
  text-decoration: underline;
}

.page-match-analysis__core-factors-section,
.page-match-analysis__application-section,
.page-match-analysis__faq-section {
  padding: 60px 0;
  background-color: #1a1a1a; /* Dark background for these sections */
  color: var(--text-light); /* Light text on dark background */
}

.page-match-analysis__core-factors-section .page-match-analysis__section-title,
.page-match-analysis__application-section .page-match-analysis__section-title,
.page-match-analysis__faq-section .page-match-analysis__section-title {
  color: var(--secondary-color); /* White title on dark background */
}

.page-match-analysis__core-factors-section a,
.page-match-analysis__application-section a,
.page-match-analysis__faq-section a {
  color: var(--primary-color);
  text-decoration: none;
}

.page-match-analysis__core-factors-section a:hover,
.page-match-analysis__application-section a:hover,
.page-match-analysis__faq-section a:hover {
  text-decoration: underline;
}

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

.page-match-analysis__card {
  background-color: var(--card-bg-dark); /* Slightly transparent dark card */
  border-radius: 10px;
  padding: 25px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: var(--text-light);
}

.page-match-analysis__card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.page-match-analysis__card-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
}

.page-match-analysis__card-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 15px;
}

.page-match-analysis__method-item {
  background-color: var(--card-bg-light);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 30px;
  margin-bottom: 30px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  color: var(--text-dark);
}

.page-match-analysis__method-title {
  font-size: 26px;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 15px;
}

.page-match-analysis__method-item ul {
  list-style-type: disc;
  margin-left: 20px;
  margin-bottom: 15px;
}

.page-match-analysis__method-item li {
  margin-bottom: 8px;
}

.page-match-analysis__content-grid {
  display: flex;
  gap: 40px;
  align-items: flex-start;
}

.page-match-analysis__content-text {
  flex: 1;
}

.page-match-analysis__content-image {
  flex: 1;
  min-width: 300px;
}

.page-match-analysis__image {
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-match-analysis__mistake-card {
  background-color: var(--card-bg-light);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 30px;
  margin-bottom: 25px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  color: var(--text-dark);
}

.page-match-analysis__mistake-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 15px;
}

.page-match-analysis__faq-list {
  margin-top: 40px;
}

.page-match-analysis__faq-item {
  background-color: var(--card-bg-dark);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  color: var(--text-light);
}

.page-match-analysis__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  color: var(--secondary-color);
  background-color: rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.page-match-analysis__faq-question:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.page-match-analysis__faq-item[open] .page-match-analysis__faq-question {
  border-bottom: 1px solid var(--primary-color);
}

.page-match-analysis__faq-toggle {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary-color);
  transition: transform 0.3s ease;
}

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

.page-match-analysis__faq-answer {
  padding: 15px 25px 20px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-light);
}

.page-match-analysis__faq-item details > summary {
  list-style: none;
}

.page-match-analysis__faq-item details > summary::-webkit-details-marker {
  display: none;
}

.page-match-analysis__cta-buttons--bottom {
  margin-top: 40px;
}

/* Responsive styles */
@media (max-width: 992px) {
  .page-match-analysis__content-grid {
    flex-direction: column;
    align-items: center;
  }

  .page-match-analysis__content-image {
    margin-top: 30px;
  }

  .page-match-analysis__card-image {
    height: auto;
  }
}

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

  .page-match-analysis__hero-content {
    padding: 20px 15px;
  }

  .page-match-analysis__main-title {
    font-size: clamp(28px, 8vw, 48px);
  }

  .page-match-analysis__description {
    font-size: clamp(15px, 4vw, 18px);
  }

  .page-match-analysis__section-title {
    font-size: clamp(24px, 7vw, 38px);
    margin-bottom: 30px;
  }

  .page-match-analysis__sub-title {
    font-size: clamp(20px, 6vw, 28px);
  }

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

  .page-match-analysis__btn-primary,
  .page-match-analysis__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 20px;
    font-size: 16px;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-match-analysis__container {
    padding: 0 15px;
  }

  .page-match-analysis__hero-section,
  .page-match-analysis__introduction-section,
  .page-match-analysis__core-factors-section,
  .page-match-analysis__methods-section,
  .page-match-analysis__application-section,
  .page-match-analysis__mistakes-section,
  .page-match-analysis__faq-section,
  .page-match-analysis__conclusion-section {
    padding: 40px 0;
  }

  /* Mobile image responsiveness */
  .page-match-analysis img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-match-analysis__section,
  .page-match-analysis__card,
  .page-match-analysis__container,
  .page-match-analysis__hero-image-wrapper,
  .page-match-analysis__content-image {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
  
  .page-match-analysis__hero-image-wrapper {
    padding-left: 0;
    padding-right: 0;
  }

  .page-match-analysis__hero-section {
    padding-top: 10px !important; /* body already handles --header-offset */
  }

  .page-match-analysis__faq-question {
    font-size: 16px;
    padding: 15px 20px;
  }

  .page-match-analysis__faq-answer {
    padding: 10px 20px 15px;
  }

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

  .page-match-analysis__card {
    padding: 20px;
  }

  .page-match-analysis__method-item,
  .page-match-analysis__mistake-card {
    padding: 20px;
  }
}