/* #region 홈 공통 */
.home_section {
  margin-bottom: 6rem;
}

.home_section_title {
  color: #222;
  text-align: center;
  /* font-family: "GyeonggiBatang", sans-serif; */
  font-size: 2.6rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.home_section_sub_title {
  color: #666;
  text-align: center;
  font-size: 1.4rem;
  font-weight: 400;
  margin-bottom: 3rem;
}

.home_swiper_item {
  border-radius: 0.4rem;
  overflow: hidden;
}

.swiper_img_box {
  background-color: #fff;
  border-radius: 0.4rem;
  overflow: hidden;
  position: relative;
  border: 0.1rem solid #dfdfdf;
  border-radius: 1rem;
}

.swiper_left_arrow {
  display: none;
}

.home_card {
  width: 100%;
  padding: 6rem 2.6rem;
  border-radius: 1rem;
  margin-bottom: 1rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 0.6rem;
  position: relative;
  overflow: hidden;
}

.home_card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
}

/* 중앙 배너 PC/모바일 이미지 전환 */
.center_banner_wrapper {
  position: relative;
}

.center_banner_wrapper img {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  object-fit: contain;
}

.center_banner_pc {
  display: block;
}

.center_banner_mobile {
  display: none;
}

/* 모바일 이미지가 있을 때만 480px 이하에서 전환 */
@media screen and (max-width: 480px) {
  .center_banner_wrapper.has_mobile_image .center_banner_pc {
    display: none !important;
  }
  
  .center_banner_wrapper.has_mobile_image .center_banner_mobile {
    display: block !important;
  }
  
  /* 모바일 이미지가 없으면 PC 이미지 계속 표시 */
  .center_banner_wrapper:not(.has_mobile_image) .center_banner_pc {
    display: block !important;
  }
}

.home_card p {
	  color: #666;
	  font-size: 1.4rem;
	  font-weight: 400;
	  letter-spacing: -0.036rem;
	  position: relative;
	  z-index: 2;
}

/* #endregion 홈 공통 */

/* #region 상단 베너 */
.home_section.main_banner_section {
  margin-bottom: 0;
  margin-top: -8rem;
}

.home_top_banner {
  /* width: 80%; */
  height: 420px;
  overflow: hidden;
  margin: 0 auto;
  position: relative;
}

.home_top_banner .swiper-wrapper {
  display: flex;
  align-items: center;
}

.home_top_banner .swiper-slide {
  display: block;
  width: 600px !important;
  height: 420px !important;
  flex-shrink: 0;
}

.home_top_banner .swiper-slide img {
  width: 100%;
  height: 100%;
  object-fit: fill;
  display: block;
}

/* 메인 배너 PC/모바일 이미지 전환 */
.home_top_banner .banner_pc_img {
  display: block;
}

.home_top_banner .banner_mobile_img {
  display: none !important;
}

/* PC에서는 모바일 이미지 숨김 (명시적으로) */
@media screen and (min-width: 769px) {
  .home_top_banner .banner_mobile_img {
    display: none !important;
  }
  
  .home_top_banner .banner_pc_img {
    display: block !important;
  }
}

/* 모바일 이미지가 있을 때만 모바일에서 전환 */
@media screen and (max-width: 768px) {
  .home_top_banner .swiper-slide .banner_pc_img:not(.no-mobile-image) {
    display: none !important;
  }
  
  .home_top_banner .swiper-slide .banner_mobile_img {
    display: block !important;
  }
  
  /* 모바일 이미지가 없으면 PC 이미지 계속 표시 */
  .home_top_banner .swiper-slide .banner_pc_img.no-mobile-image {
    display: block !important;
  }
}

/* 배너 컨트롤 UI */
.home_top_banner_controls {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex !important;
  align-items: center;
  gap: 1.6rem;
  padding: 0.8rem 1.6rem;
  border-radius: 0.8rem;
  z-index: 100;
  pointer-events: auto;
  visibility: visible;
  opacity: 1;
}

.banner_control_play_pause {
  width: 3.2rem;
  height: 3.2rem;
  border: 1px solid #E0E0E0;
  border-radius: 1rem;
  background-color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: all 0.2s ease;
}

.banner_control_play_pause:hover {
  background-color: #F5F5F5;
}

.banner_control_play_pause svg {
  color: #000000;
  width: 1.2rem;
  height: 1.1rem;
}

.banner_control_progress {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  min-width: 20rem;
}

.banner_progress_bar {
  flex: 1;
  height: 0.4rem;
  background-color: #E0E0E0;
  border-radius: 0.2rem;
  overflow: hidden;
  position: relative;
}

.banner_progress_fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background-color: #222;
  transform-origin: left;
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.banner_progress_counter {
  display: flex;
  align-items: center;
  font-size: 1.4rem;
  font-weight: 500;
  white-space: nowrap;
}

.banner_current_num {
  color: #333333;
  font-weight: 600;
}

.banner_separator {
  color: #999999;
  margin: 0 0.2rem;
}

.banner_total_num {
  color: #D3D4DA;
}

.banner_control_nav {
  display: flex;
  gap: 0.4rem;
}

.banner_control_prev,
.banner_control_next {
  width: 3.2rem;
  height: 3.2rem;
  border: 1px solid #E0E0E0;
  border-radius: 1rem;
  background-color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: all 0.2s ease;
}

.banner_control_prev:hover,
.banner_control_next:hover {
  background-color: #F5F5F5;
}

.banner_control_prev svg,
.banner_control_next svg {
  color: #000000;
  width: 0.8rem;
  height: 1rem;
}

.banner_control_prev.swiper-button-disabled,
.banner_control_next.swiper-button-disabled {
  opacity: 0.35;
  cursor: auto;
  pointer-events: none;
}


/* #endregion 상단 베너 */

/* #region 베스트 상품 */
.best_swiper {
  padding: 0 3rem;
}

.best_swiper .item_card_name,
.best_swiper .item_card_price_box {
  padding-left: 1rem;
}

/* #endregion 베스트 상품 */

/* #region MD 추천상품 */
.md_recommend_swiper {
  padding: 0 7rem;
}

.md_recommend_swiper .home_swiper_item {
  background-color: #F7F7F7;
  border-radius: 1.4rem;
}

.md_recommend_swiper .swiper_img_box {
  border-radius: 1.4rem;
  overflow: hidden;
}

.md_recommend_swiper .swiper_item_content {
  padding: 1.2rem;
}

.md_recommend_swiper .item_card_name {
  margin-top: 0;
}

/* .md_recommend_swiper .item_card_price_box {
  display: flex;
  align-items: center;
  gap: 0.8rem;
} */

/* .md_recommend_swiper .swiper_left_arrow {
  display: block;
  width: 1rem;
} */

/* #endregion MD 추천상품 */

/* #region 카테고리별 상품 리스트 */
.category_rankings_grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media screen and (min-width: 768px) {
  .category_rankings_grid {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2.4rem;
  }
}

.category_ranking_card {
  background-color: #FFFFFF;
  border: 0.1rem solid #E3E3E3;
  border-radius: 1rem;
  padding: 0;
  overflow: hidden;
}

.category_ranking_header {
  background-color: color-mix(in srgb, var(--color-primary) 30%, white);
  color: #333;
  font-size: 1.6rem;
  font-weight: 600;
  padding: 1.2rem 1.6rem;
  text-align: center;
}

.category_ranking_main_item {
  display: block;
  text-decoration: none;
  color: inherit;
  padding-bottom: 1rem;
}

.category_ranking_main_img {
  width: 100%;
  margin-bottom: 1.2rem;
  border-radius: 0.4rem;
  overflow: hidden;
  background-color: #F7F7F7;
}

.category_ranking_main_img img {
  width: 100%;
  height: auto;
  display: block;
}

.category_ranking_item_name {
  font-size: 1.8rem;
  font-weight: 500;
  color: #333;
  margin-bottom: 0.3rem;
  line-height: 1.4;
  padding-left: 1.5rem;
}

.category_ranking_item_name span {
  color: #666;
}

.category_ranking_price_box {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding-left: 1.5rem;
}

.category_ranking_cust_price {
  color: #999;
  text-decoration: line-through;
}

.category_ranking_price {
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--color-primary);
}

.category_ranking_sub_items {
  display: flex;
  flex-direction: column;
}

.category_ranking_sub_item {
  display: flex;
  gap: 1.2rem;
  text-decoration: none;
  color: inherit;
  padding: 1.2rem;
  border-top: 1px solid #DDDDDD;
}

.category_ranking_sub_img {
  width: 8rem;
  min-width: 8rem;
  height: 8rem;
  border-radius: 0.4rem;
  overflow: hidden;
  background-color: #FFFFFF;
}

.category_ranking_sub_img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category_ranking_sub_info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.category_ranking_sub_info .category_ranking_item_name {
  margin-bottom: 0.6rem;
}

.category_ranking_sub_info .category_ranking_price_box {
  gap: 0.6rem;
}

.category_ranking_go_btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  width: 90%;
  height: 5.2rem;
  background-color: #FFFFFF;
  border: 0.1rem solid #DDDDDD;
  border-radius: 0.4rem;
  font-size: 1.4rem;
  font-weight: 500;
  color: #333;
  text-decoration: none;
  transition: background-color 0.2s ease;
  margin: 0 auto 1.5rem auto;
}

.category_ranking_go_btn:hover {
  background-color: #F7F7F7;
}

.category_ranking_go_btn svg {
  width: 0.8rem;
  height: 1.4rem;
}

/* #endregion 카테고리별 상품 리스트 */

/* #region 홈 배너 섹션 */
.home_banner_section {
  margin-top: 6rem;
  position: relative;
}

.home_banner_section_header {
  position: absolute;
  top: -5rem;
  right: 0;
  z-index: 10;
}

.home_banner_admin_btn {
  display: inline-block;
  padding: 0.8rem 1.6rem;
  background-color: var(--color-primary);
  color: #FFFFFF;
  font-size: 1.4rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 0.4rem;
  transition: all 0.2s ease;
}

.home_banner_admin_btn:hover {
  background-color: #000;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.home_banner_grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.6rem;
}

.home_banner_card {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  min-height: 20rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.home_banner_card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
}

.home_banner_card.banner_bg_pink {
  background-color: #FFE5E5;
  background-image: 
    radial-gradient(circle at 20% 30%, rgba(255, 182, 193, 0.3) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(255, 192, 203, 0.2) 0%, transparent 50%);
}

.home_banner_card.banner_bg_gray {
  background-color: #F5F5F5;
}

.home_banner_card.banner_bg_teal {
  background-color: #E0F7FA;
}

.home_banner_card.banner_bg_white {
  background-color: #FFFFFF;
  border: 0.1rem solid #E3E3E3;
}

.home_banner_link {
  display: block;
  text-decoration: none;
  color: inherit;
  width: 100%;
  height: 100%;
}

.home_banner_image_full {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.home_banner_image_full img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* 하단 배너 PC/모바일 이미지 전환 */
.home_banner_pc_img {
  display: block;
}

.home_banner_mobile_img {
  display: none !important;
}

/* PC에서는 모바일 이미지 숨김 (명시적으로) */
@media screen and (min-width: 769px) {
  .home_banner_mobile_img {
    display: none !important;
  }
  
  .home_banner_pc_img {
    display: block !important;
  }
}

/* 모바일 이미지가 있을 때만 모바일에서 전환 */
@media screen and (max-width: 768px) {
  .home_banner_image_full .home_banner_pc_img:not(.no-mobile-image) {
    display: none !important;
  }
  
  .home_banner_image_full .home_banner_mobile_img {
    display: block !important;
  }
  
  /* 모바일 이미지가 없으면 PC 이미지 계속 표시 */
  .home_banner_image_full .home_banner_pc_img.no-mobile-image {
    display: block !important;
  }
}

/* #endregion 홈 배너 섹션 */

@media screen and (max-width: 768px) {
  .home_top_banner .swiper-slide {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 600 / 420;
  }

  .home_top_banner_controls {
    display: none !important;
  }

  .banner_control_play_pause,
  .banner_control_prev,
  .banner_control_next {
    width: 2.8rem;
    height: 2.8rem;
  }

  .banner_control_progress {
    min-width: 15rem;
    gap: 1rem;
  }

  .banner_progress_counter {
    font-size: 1.2rem;
  }

  .home_banner_grid {
    gap: 1rem !important;
  }
}

@media screen and (max-width: 768px) {
  .home_section {
    margin-bottom: 3rem;
  }
  .home_section.main_banner_section {
    margin-left: 0;
    margin-right: 0;
    width: 100%;
    margin-top: 0;
  }

  .home_section_banner img {
    width: 70px;
  }

  .home_top_banner {
    width: 100%;
    height: 200px;
    margin-top: 0rem;
    margin-left: 0;
    margin-right: 0;
  }

  .home_top_banner .swiper-slide {
    width: 100% !important;
    height: 200px !important;
  }

  .home_banner_card {
    height: 14rem;
    min-height: 10rem !important;
  }

  .best_swiper .item_card_name, .best_swiper .item_card_price_box {
    padding-left: 0;
  }
}

@media screen and (max-width: 480px) {
  .home_top_banner .swiper-slide {
    width: 100% !important;
    height: 100% !important;
  }
}

@media screen and (min-width: 768px) {

  /* #region 홈 공통 */
  .home_section {
    margin-bottom: 8rem;
  }

  .home_section_title {
    font-size: 3.0rem;
  }

  .home_section_sub_title {
    font-size: 1.6rem;
  }

  .home_card {
    width: 100%;
    padding: 3.8rem 4.8rem;
    margin-bottom: 2rem;
  }

  .home_card h5 {
    font-size: 2.4rem;
  }

  .home_card p {
    font-size: 1.6rem;
  }

  /* #endregion 홈 공통 */

  /* #region 카테고리별 상품 리스트 */
  .category_rankings_grid {
    gap: 3.2rem;
  }

  /* #endregion 카테고리별 상품 리스트 */

  /* #region 홈 배너 섹션 */
  .home_banner_grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }

  /* #endregion 홈 배너 섹션 */
}

@media screen and (min-width: 900px) {

  /* #region 상단 베너 */
  .home_top_banner {
    height: 60rem;
    aspect-ratio: unset;
    max-width: 1824px;
    margin-left: auto;
    margin-right: auto;
    padding-right: 0;
    padding-left: 0;
  }

  .home_top_banner .common_swiper_prev {
    left: calc(50vw - 912px - 2rem);
  }

  .home_top_banner .common_swiper_next {
    right: calc(50vw - 912px - 2rem);
  }

  /* #endregion 상단 베너 */
}

@media screen and (min-width: 1024px) {

  /* #region 홈 공통 */
  .home_section {
    margin-bottom: 7rem;
  }

  .home_section_title {
    font-size: 3.2rem;
  }

  .swiper_img_box {
    border-radius: 1rem;
    border: 0.1rem solid #dfdfdf;
  }

  .width_max_1280_mobile .common_swiper_prev,
  .width_max_1280 .common_swiper_prev {
    left: 0;
  }

  .width_max_1280_mobile .common_swiper_next,
  .width_max_1280 .common_swiper_next {
    right: 0;
  }

  .home_card {
    padding: 6.8rem 7.4rem;
    border-radius: 1rem;
    margin-bottom: 4rem;
  }

  .home_card h5 {
    font-size: 2.8rem;
  }

  .home_card p {
    font-size: 1.8rem;
  }

  /* #endregion 홈 공통 */

  /* #region 베스트 상품 */
  .best_swiper {
    padding: 0 2.5rem;
  }

  .best_swiper .swiper-slide img {
    border-radius: 2rem;
  }

  /* #endregion 베스트 상품 */

  /* #region MD 추천상품 */
  .md_recommend_swiper {
    padding: 0;
  }

  .md_recommend_swiper .swiper_item_content {
    padding: 2.6rem 3rem;
  }
  /* #endregion MD 추천상품 */

  /* #region 카테고리별 상품 리스트 */
  .category_rankings_grid {
    gap: 3.2rem;
  }

  .category_ranking_header {
    font-size: 1.8rem;
    padding: 1.4rem 2rem;
  }

  .category_ranking_price {
    font-size: 2.4rem;
  }

  .category_ranking_sub_item {
    padding: 1.6rem;
  }

  .category_ranking_sub_img {
    width: 10rem;
    min-width: 10rem;
    height: 10rem;
  }

  .category_ranking_sub_info .category_ranking_price {
    font-size: 2.4rem;
  }

  .category_ranking_go_btn {
    height: 5.6rem;
    font-size: 1.6rem;
  }

  /* #endregion 카테고리별 상품 리스트 */
}

@media screen and (min-width: 1200px) {

  /* #region 홈 공통 */
  .swiper_left_arrow {
    display: block;
  }

  /* #endregion 홈 공통 */

  /* #region 카테고리별 상품 리스트 */
  .category_rankings_grid {
    gap: 4rem;
  }

  /* #endregion 카테고리별 상품 리스트 */
}

@media screen and (min-width: 1400px) {

  /* #region 카테고리별 상품 리스트 */
  .category_rankings_grid {
    gap: 1.5rem;
  }

  /* #endregion 카테고리별 상품 리스트 */

  /* #region 홈 배너 섹션 */
  .home_banner_grid {
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 2.4rem;
  }

  .home_banner_card {
    min-height: 28rem;
  }

  .home_banner_admin_btn {
    font-size: 1.6rem;
    padding: 1rem 2rem;
  }

  /* #endregion 홈 배너 섹션 */

  /* #region 홈 배너 섹션 */
  .home_banner_grid {
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 1rem;
  }

  .home_banner_card {
    min-height: 24rem;
  }

  /* #endregion 홈 배너 섹션 */
}
