/* Challenges Section */
.challenges-section {
  padding: 4vw 0 2vw 0;
  display: flex;
  align-items: flex-start;
  justify-content: center;

  background-image: url("../images/backgrounds/onayamihaikei.png") !important;
  background-repeat: no-repeat !important;
  background-size: 300% 100% !important;
  background-position: center center !important;
  min-height: 100vh;
  height: auto;
}

.challenges-section .section-container {
  max-width: 100vw;
  padding: 0 5vw;
}

/* スマホでの幅調整 */
@media (max-width: 768px) {
  .challenges-section .section-container {
    max-width: 100vw;
    padding: 0 7.5vw;
  }
}

@media (max-width: 480px) {
  .challenges-section .section-container {
    max-width: 100vw;
    padding: 0 5vw;
  }
}

.challenges-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto;
  grid-template-areas:
    "one   two   three"
    "four  .     five";
  gap: clamp(2rem, 6vw, 5rem);
}

.challenges-grid .challenge-card:nth-child(1) {
  grid-area: one;
}

.challenges-grid .challenge-card:nth-child(2) {
  grid-area: two;
}

.challenges-grid .challenge-card:nth-child(3) {
  grid-area: three;
}

.challenges-grid .challenge-card:nth-child(4) {
  grid-area: four;
}

.challenges-grid .challenge-card:nth-child(5) {
  grid-area: five;
}

@media (max-width: 768px) {
  .challenges-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: auto auto auto;
    grid-template-areas:
      "one   two"
      "three four"
      "five  five";
  }
}

.challenge-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
  max-width: none;
}

.challenge-icon-wrapper {
  width: clamp(8rem, 12vw, 10rem);
  height: clamp(8rem, 12vw, 10rem);
  background-color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: clamp(1rem, 2vw, 1.5rem);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  padding: clamp(0.75rem, 1.5vw, 1rem);
}

.challenge-icon {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.challenges-row {
  display: grid;
  justify-content: center;
  gap: clamp(1.5rem, 4vw, 2rem);
  margin-top: clamp(1.5rem, 4vw, 2rem);
}

.challenges-row.row-3 {
  grid-template-columns: repeat(3, 1fr);
  max-width: 90vw;
  margin: 0 auto;
}

.challenges-row.row-2 {
  grid-template-columns: repeat(2, 1fr);
  max-width: 50vw;
  margin: clamp(1.5rem, 4vw, 2rem) auto 0;
}

.challenge-description {
  font-family: "Inter-SemiBold", Helvetica;
  font-weight: 600;
  font-size: clamp(1rem, 2.2vw, 1.5rem);
  color: #192f60;
  margin: 0;
  line-height: 1.3;
}

.challenges-section .section-title {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  text-align: center;
  margin-bottom: clamp(2rem, 5vw, 3rem);
}

/* Solution Section */
.solution-section {
  padding: 60px 0;
  background-color: #ffffff;
  text-align: center;
}

.solution-section .section-title {
  font-size: 42px;
  color: #192f60;
  margin: 0;
  white-space: nowrap;
}

/* Responsive design for solution section title */
@media (max-width: 768px) {
  .solution-section .section-title {
    font-size: 24px;
  }
}

@media (max-width: 480px) {
  .solution-section .section-title {
    font-size: 18px;
  }
}

@media (max-width: 400px) {
  .solution-section .section-title {
    font-size: 18px;
    /* center text */
    text-align: center;
  }
}

@media (max-width: 360px) {
  .solution-section .section-title {
    font-size: 14px;
  }
}

@media (max-width: 320px) {
  .solution-section .section-title {
    font-size: 12px;
  }
}

/* Responsive adjustments */
@media (max-width: 1200px) {
  .challenges-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
  }

  .challenges-title {
    font-size: 36px;
  }
}

@media (max-width: 768px) {
  .challenges-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .challenge-icon-wrapper {
    width: 120px;
    height: 120px;
  }

  .challenge-icon {
    width: 100px;
    height: 100px;
  }

  .challenges-title {
    font-size: 28px;
  }

  .challenges-subtitle {
    font-size: 24px;
  }
}

/* Challenges Row Responsive */
@media (max-width: 768px) {
  .challenges-row.row-3 {
    grid-template-columns: repeat(3, 1fr);
    max-width: 85%;
    margin: 0 auto;
    gap: 10px;
  }

  .challenges-row.row-2 {
    grid-template-columns: repeat(2, 1fr);
    max-width: 60%;
    margin: 0 auto;
    gap: 10px;
  }

  .challenge-description {
    font-size: 10px;
    line-height: 1.2;
    padding: 0 3px;
  }

  .challenges-section .section-title {
    font-size: 28px;
  }

  .challenges-section {
    min-height: auto;
    padding: 30px 20px;
  }

  .challenges-section .section-container {
    max-width: 100%;
    padding: 0 20px;
  }

  .challenge-icon-wrapper {
    width: 80px;
    height: 80px;
  }

  .challenge-icon {
    width: 60px;
    height: 60px;
  }
}

@media (max-width: 480px) {
  .challenges-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .challenges-title {
    font-size: 24px;
  }

  .challenges-subtitle {
    font-size: 20px;
  }

  .challenge-description {
    font-size: 12px;
    line-height: 1.2;
    padding: 0 5px;
  }

  .challenges-section .section-title {
    font-size: 24px;
  }

  .challenges-section {
    padding: 20px 10px;
  }

  .challenges-row.row-3 {
    grid-template-columns: repeat(3, 1fr);
    max-width: 90%;
    margin: 0 auto;
    gap: 8px;
  }

  .challenges-row.row-2 {
    grid-template-columns: repeat(2, 1fr);
    max-width: 65%;
    margin: 0 auto;
    gap: 8px;
  }

  .challenge-icon-wrapper {
    width: 70px;
    height: 70px;
  }

  .challenge-icon {
    width: 50px;
    height: 50px;
  }

  .challenge-description {
    font-size: 9px;
    line-height: 1.1;
    padding: 0 2px;
  }
}