/* 카드 레이아웃 관련(모터센스 예시) */
.card-wrapper {
  width: 100%;
  max-width: 2030px;  /* 최대 폭 */
  margin: 0 auto;     /* 가운데 정렬 */
  box-sizing: border-box;
}

/* 카드 개별 스타일 */
.case-card {
  width: 100%;          /* 그리드 칸 가득 */
  max-width: 363px;     /* 최대 너비 */
  height: 485px;
  border: 1px solid #d6e7f2;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.04);
  border-radius: 30px;
  padding: 24px 24px 0 24px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  background-color: #fff;
  position: relative;
  margin-bottom: 20px;
}

.card-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* 정확히 4열 */
  gap: 20px;                              /* 카드 간 간격 */
  width: 100%;
  max-width: calc((363px * 4) + (20px * 3)); /* 카드 너비*4 + 간격*3 */
  margin: 0 auto;                         /* 가운데 정렬 (전체를) */
  box-sizing: border-box;

}

.case-content {
  font-weight: bold;
  padding-bottom: 20px;
  z-index: 1;
}

.case-button {
  padding: 10px 16px;
  background-color: #0047AB;
  color: #fff;
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  font-size: 16px;
}

.case-button-wrap {
  margin-top: 20px;
  margin-bottom: 20px;
}

.case-title {
  font-size: 28px;
  line-height: 1.4;
  color: #222;
  margin-bottom: 30px;
}

.case-link {
  margin-bottom: 20px;
  color: #0047AB;
  text-decoration: none;
  border-bottom: 1px solid #0047AB;
  font-weight: 500;
  font-size: 16px;
}

.case-image {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  border-bottom-left-radius: 30px;
  border-bottom-right-radius: 30px;
  overflow: hidden;
  z-index: 0;
}

.case-image img {
  width: 100%;
  max-height: 300px;
  height: auto;
  object-fit: cover;
  display: block;
}

/* 태블릿 (992px 이하) - 3열 */
@media (max-width: 992px) {
  .card-container {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* 중간 화면 (768px 이하) - 2열 */
@media (max-width: 768px) {
  .card-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .card-container {
    grid-template-columns: 1fr;
    justify-items: center; /* 카드 가운데 정렬 */
    padding: 20px;          /* 좌우 여백 확보 */
    max-width: 100%;
  }

  .case-card {
    width: 100%;
    max-width: 363px;
  }
}

/* 카드 레이아웃 관련(LAVO 예시) */
.about-intro {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
  font-size: 22px;
  line-height: 1.8;
  padding: 0 16px;
  box-sizing: border-box;
}

.about-highlight {
  font-weight: 600;
  color: #005f99; /* 강조 색상 */
}

.card {
  flex: 1 1 320px;
  max-width: 370px;
  background-color: #fff;
  border: none;
  box-shadow: none;
  overflow: hidden;      /* 중요: 이미지 둥근 모서리 위해 꼭 필요 */
  box-sizing: border-box;
  padding-bottom: 20px;
  border-radius: 25px;   /* 카드 전체 둥근 모서리 추가 (필요 시) */
}

/* 기존 스타일 유지 */
.card-image {
  width: 370px;         /* 고정 너비 */
  height: 370px;        /* 고정 높이 */
  object-fit: cover;    /* 영역 꽉 채우면서 비율 유지 */
  display: block;
  border-radius: 25px; /* 상하좌우 모두 둥글게 */
  margin: 0 auto;        /* 가운데 정렬 */
}

.card-title {
  font-size: 20px;
  font-weight: bold;
  padding: 15px 0 8px;
  color: #005f99;
}

.card-list {
  font-size: 18px;
  list-style: none;  /* 불릿 제거 */
  padding-left: 0;   /* 기본 들여쓰기 제거 */
  margin: 0;
}

.card-list li {
  position: relative;
  padding-left: 1em;        /* dot 공간 확보 */
  text-indent: 0em;        /* 줄바꿈 시 dot에 맞게 들여쓰기 */
  line-height: 1.6;
}

.card-list li::before {
  content: "\2022"; /* ← Bullet 기호 (•) 유니코드 */
  position: absolute;
  left: 0;
  top: 0;
  font-size: 1em;
  line-height: 1.6;
  color: #003366; /* 필요 시 컬러 변경 가능 */
}

/* 900px 이하: 2열 배치 */
@media (max-width: 900px) {
  .card {
    flex: 1 1 calc(50% - 20px);
    max-width: calc(50% - 20px);
  }
}
/* 992px 이하: 태블릿 이하 2열 배치 등 조정 */
@media (max-width: 992px) {
  .card {
    flex: 1 1 50%;
    max-width: 50%;
  }
}

/* 768px 이하: 더 작은 화면 대응 */
@media (max-width: 768px) {
  .card {
    flex: 1 1 100%;
    max-width: 100%;
    padding: 0 10px;
    box-sizing: border-box;
    margin: 0 auto;
  }

  .card-image {
    width: 100%;
    height: auto;
    border-radius: 15px;
    display: block;
  }

  .card-list {
    margin-bottom: 20px;
  }

  .col-md-4:last-child .card-list {
    margin-bottom: 0;
  }
}

/* 600px 이하: 1열 배치 */
@media (max-width: 600px) {
  .card {
    flex: 1 1 100%;
    max-width: 100%;
    padding: 0 10px;        /* 좌우 여백 줄이기 또는 필요에 따라 조절 */
    box-sizing: border-box; /* 패딩 포함 너비 계산 */
    margin: 0 auto;         /* 카드 가운데 정렬 */
  }
  .card-image {
    width: 100%;            /* 부모 너비에 딱 맞춤 */
    height: auto;           /* 비율 유지 */
    border-radius: 15px;    /* 라운드 조절 */
    display: block;
  }
  /* 마지막 카드가 아닌 .card 내부 .card-list에만 아래쪽 여백 주기 */
  .card-list {
      margin-bottom: 20px;
    }

    /* col-md-4 중 마지막 것 안의 .card-list만 여백 제거 */
    .col-md-4:last-child .card-list {
      margin-bottom: 0;
    }
}


#section-cardImg .feature-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* 최소폭 300px으로 줄임 */
  gap: 40px;
  justify-content: center;
  padding: 0 16px;
  max-width: 1600px; /* 충분히 넓게 */
  margin-left: auto;
  margin-right: auto;
}

#section-cardImg .feature-card {
  position: relative;
  width: 100%;
}

#section-cardImg .feature-card img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  border-radius: 25px;
}

#section-cardImg .overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.5);
  display: flex;
  flex-direction: column;      /* 세로 방향으로 쌓기 */
  justify-content: center;
  align-items: center;
  color: #fff;
  z-index: 10;
  pointer-events: none;
  border-radius: 25px;
}

/* 메인 타이틀 느낌 스타일 */
#section-cardImg .overlay p.title-main {
  margin-bottom: 20px;       /* 아래 마진 */
  font-weight: bold !important;          /* 굵게 (bold) */
  font-size: 36px; !important;           /* 기존 크기 유지 */
  color: #fff;
  text-align: center !important;;
  padding: 0 16px !important;;
  line-height: 1.6;
}

/* 내용 텍스트 스타일 */
#section-cardImg .overlay p.title-sub {
  font-size: 20px !important;;           /* 적당한 크기 */
  color: #fff;
  text-align: center !important;;
  padding: 0 16px !important;;
  line-height: 1.6 !important;;
}

/* 992px 이하: 2열 */
@media (max-width: 992px) {
  #section-cardImg .feature-card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  #section-cardImg .feature-card-grid .overlay p {
    font-size: 24px;
  }
}


/* 576px 이하: 1열 */
@media (max-width: 576px) {
  #section-cardImg .feature-card-grid {
    grid-template-columns: 1fr;
  }
  #section-cardImg .overlay p.title-main {
    margin-bottom: 20px;       /* 아래 마진 */
    font-weight: bold !important;          /* 굵게 (bold) */
    font-size: 30px; !important;           /* 기존 크기 유지 */
    color: #fff;
    text-align: center !important;;
    padding: 0 16px !important;;
    line-height: 1.6;
  }
}
