@font-face {
  font-family: "SUIT-Bold";
  src: url("fonts/SUIT-Bold.ttf") format("truetype");
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: "강원교육튼튼";
  src: url("fonts/강원교육튼튼.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "Pretendard-Regular";
  src: url("fonts/Pretendard-Regular.otf") format("opentype");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "SB 어그로 B";
  src: url("fonts/SB 어그로 B.ttf") format("truetype");
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: "SB 어그로 L";
  src: url("fonts/SB 어그로 L.ttf") format("truetype");
  font-weight: lighter;
  font-style: normal;
}

@font-face {
  font-family: "SB 어그로 M";
  src: url("fonts/SB 어그로 M.ttf") format("truetype");
  font-weight: medium;
  font-style: normal;
}

.mobile-br {
  display: none;
}

.zoom {
  transform: scale(1.05); /* 1.1배 확대 */
}

.zoom-target {
  transition: transform 0.5s ease-in-out; /* 부드러운 확대/축소 */
}

/* 기본적으로 보이지 않도록 설정 */
.slide-in {
  opacity: 0;
  transform: translateX(-200px); /* 기본 왼쪽에서 출발 */
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

/* 오른쪽에서 왼쪽으로 나타나는 효과 */
.slide-in-right {
  opacity: 0;
  transform: translateX(200px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

/* 활성화되면 자연스럽게 나타남 */
.active {
  opacity: 1;
  transform: translateX(0);
}

h2 {
  font-size: 4rem;
}
h3 {
  font-size: 3rem;
}
html {
  font-size: 10px;
}

body {
  position: relative;
  font-family: "Pretendard-Regular", sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f8f8f8;
  color: #333;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  overflow-x: hidden;
}

section {
  overflow: hidden;
  width: 100%;
}

.header {
  position: relative;
  width: 100%;
  height: 100vh;
  text-align: center;
  background: linear-gradient(135deg, #f1f1f1, #f7c8ff);
  color: #5e2750;
  padding: 0rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.header_content {
  width: 90rem;
  height: 30rem;
  padding: 12rem 3rem;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.3);
  z-index: 1500;
  border-radius: 10rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: rgba(255, 255, 255, 0.6); /* 반투명 흰색 배경 */
}

.header h1 {
  width: 40rem;
  position: relative;
  font-size: 5rem;
  z-index: 1000;
  animation: float 2s ease-in-out infinite; /* 둥둥 떠다니는 애니메이션 */
}
.header p {
  width: auto;
  position: relative;
  font-size: 2.3rem;
  color: rgb(116, 63, 102);
  z-index: 1000;
}
.header span {
  font-size: 2.7rem;
  font-weight: 600;
  z-index: 1000;
}

.main-img {
  position: absolute;
  width: 43rem;
  bottom: 1rem;
  left: 10rem;
  z-index: 500;
  opacity: 0.8;
  filter: drop-shadow(5px 5px 2px rgba(0, 0, 0, 0.7)); /* 기본 그림자 */
}
.main-img2 {
  position: absolute;
  width: 70rem;
  top: 1rem;
  right: 1rem;
  z-index: 400;
  opacity: 0.8;
  filter: drop-shadow(5px 5px 2px rgba(0, 0, 0, 0.7));
}

.logo img {
  max-width: 15rem;
}

/* 포트폴리오 섹션 스타일 */
.portfolio {
  text-align: center;
  padding: 5rem 2rem;
  user-select: none;
  width: 95%;
  height: 60rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.portfolio-text-box {
  width: 100%;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}
.portfolio h2 {
  color: #333;
}

.portfolio-more {
  position: absolute;
  font-size: 2.2rem;
  font-weight: 600;
  color: rgb(247, 247, 247);
  text-decoration: none;
  background-color: #ffcc00;
  padding: 1rem 2rem;
  border-radius: 1rem;
  box-shadow: 0 2px 5px rgb(255, 216, 41);
  right: 4rem;
  animation: float 2s ease-in-out infinite; /* 둥둥 떠다니는 애니메이션 */
}

.portfolio-more:hover {
  cursor: pointer;
  background-color: #ffd427;
}

.portfolio-container {
  width: 95%;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  cursor: grab;
  padding-bottom: 1rem;
  scroll-padding-left: 20rem; /* 🎯 스크롤 시 첫 번째 아이템이 잘리지 않게 설정 */
}
.portfolio-container:active {
  cursor: grabbing;
}
.portfolio-item {
  display: flex;
  align-items: center;
  cursor: pointer;
  width: 60rem;
  height: 40rem;
  transition: transform 0.3s ease-in-out;
}
.portfolio-item:first-child {
  margin-left: 140rem; /* 🎯 첫 번째 포트폴리오 항목 왼쪽 여백 추가 */
}
.portfolio-item:hover {
  transform: scale(1.05);
}
.portfolio-item img {
  width: 60rem;
  border-radius: 1rem;
  box-shadow: 0 0.4rem 0.8rem rgba(0, 0, 0, 0.1);
}
.lightbox {
  display: none;
  position: fixed;
  top: 5rem;
  left: 0;
  max-width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  z-index: 2000;
}
.lightbox img {
  max-width: 100%;
}
.lightbox-content {
  max-width: 100%;
  max-height: 80%;
}
.close {
  position: absolute;
  top: 2rem;
  right: 2rem;
  color: white;
  font-size: 2rem;
  cursor: pointer;
}

/* 블로그 섹션 스타일 */
.blog-section {
  background-image: url(./images/신비크리에이티브\ 블로그\ 이미지.png) !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  background-attachment: fixed; /* 고정 배경 */
  text-align: center;
  padding: 4rem 0;
  background: #f9f9f9;
  width: 100%;
  padding-bottom: 10rem;
}
.blog-text {
  color: #5e2750;
}
.blog-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
  padding: 4rem 0;
}

.blog-item {
  width: 30rem;
  background: white;
  border-radius: 1rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.3s ease-in-out;
  text-align: left;
  padding: 2rem 0;
}

.blog-item:hover {
  transform: translateY(-5px);
}

.blog-item a {
  text-decoration: none; /* 밑줄 없애기 */
  color: inherit; /* 기본 색 유지 */
  display: block;
}

.blog-item img {
  width: 100%;
  object-fit: cover;
}

.blog-item h3 {
  font-size: 1.8rem;
  margin: 1.5rem;
  height: 7rem;
  color: #333;
  overflow: hidden;
}

.blog-item p {
  font-size: 1.6rem;
  margin: 1rem 1.5rem;
  color: #666;
  height: 5.5rem;
  overflow: hidden;
}

.blog-date {
  font-size: 1.5rem;
  color: #999;
  margin-bottom: 1.5rem;
  display: block;
  margin-left: 2rem;
  margin-top: 2rem;
}

/* 리뷰 섹션 스타일 */
.kmong-reviews {
  overflow: hidden !important;
  text-align: center;
  padding: 3rem 0;
  width: 100%;
  height: 140rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: #fffcf0;
  padding: 5rem 0;
}
.kmong-reviews img {
  position: absolute;
  z-index: 500;
  width: 61.5rem;
}
.kmong-iframe {
  width: 50rem;
  max-width: 100%; /* 부모 요소보다 커지지 않게 */
  height: 105rem;
  border-radius: 1rem;
  padding: 1rem;
  z-index: 1000;
  border: none;
  padding: 0;
  margin: 0;
}

/* 하단의 정보 섹션 스타일 */
.footer {
  width: 100%;
  text-align: center;
  padding: 2rem 0;
  background-color: #333;
  color: white;
  font-size: 1.6rem;
  line-height: 2.4rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.footer a {
  color: #ffcc00;
  text-decoration: none;
  font-weight: bold;
}

.footer a:hover {
  text-decoration: underline;
}

.floating {
  animation: float 2s ease-in-out infinite alternate; /* 🔥 둥둥 애니메이션 */
}

/* 기본적으로 투명한 상태로 숨김 */
.fade-in {
  opacity: 0;
  transform: translateY(30px); /* 🔥 아래에서 위로 슬라이드 */
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

/* 스크롤 시 나타나는 효과 */
.fade-in.show {
  opacity: 1;
  transform: translateY(0);
}

@keyframes float {
  0% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(10px);
  } /* 10px 위아래로 움직임 */
  100% {
    transform: translateY(0);
  }
}

@media (max-width: 1700px) {
  .portfolio-item:first-child {
    margin-left: 170rem;
  }
}
@media (max-width: 1500px) {
  .portfolio-item:first-child {
    margin-left: 190rem;
  }
}
@media (max-width: 1366px) {
  .portfolio-item:first-child {
    margin-left: 210rem;
  }
}
@media (max-width: 1020px) {
  html {
    font-size: 1vw;
  }
  .portfolio-item:first-child {
    margin-left: 220rem;
  }
}
@media (max-width: 730px) {
  html {
    font-size: 1.3vw;
  }
  .header_content {
    width: 66rem;
  }
  .portfolio {
    padding: 0;
  }
  .portfolio-more {
    right: 0rem;
  }
  .portfolio-item:first-child {
    margin-left: 250rem;
  }
  .mobile-br {
    display: block;
  }

  footer {
    height: 25rem;
  }
  footer p {
    font-size: 2rem;
    margin: 1.5rem 0;
  }
}
@media (max-width: 580px) {
  html {
    font-size: 1.45vw;
  }

  .header_content {
    width: 100%;
    border-radius: 0;
    background-color: #fafafa;
    opacity: 0.9;
    position: absolute;
    top: 16rem;
  }
  .main-img {
    display: none;
  }
  .main-img2 {
    width: 60rem;
    right: 3rem;
    top: 70rem;
  }
  .portfolio {
    padding: 0;
  }
}
@media (max-width: 510px) {
  html {
    font-size: 1.55vw;
  }
  .header {
    height: 125rem;
  }
  .header_content {
    height: 50rem;
  }
  .header_content h1 {
    font-size: 5.5rem;
  }
  .header_content p {
    font-size: 2.6rem;
  }
  .portfolio {
    height: 90rem;
    padding-bottom: 10rem;
  }
  .portfolio-container {
    height: 100rem;
  }
  .portfolio-item {
    cursor: pointer;
    width: 100rem;
    height: 85rem;
    transition: transform 0.3s ease-in-out;
  }
  .portfolio-item:first-child {
    margin-left: 455rem;
  }
  .portfolio-item img {
    width: 100rem;
  }

  .blog-section {
    background-image: url(./images/신비크리에이티브\ 블로그\ 이미지.png) !important;
    background-position: center !important;
    background-repeat: repeat !important;
    background-size: auto !important;
  }
  .blog-text {
    font-size: 3rem;
  }
  .blog-item {
    width: 50rem;
    height: 60rem;
    padding: 1rem;
  }
  .blog-item img {
    height: 30rem;
  }
  .blog-item h3 {
    font-size: 2.5rem;
    height: 10rem;
  }
  .blog-item p {
    font-size: 2rem;
    height: 10rem;
  }
  .blog-date {
    font-size: 2rem;
  }

  .kmong-reviews img {
    width: 58.5rem;
  }
  .kmong-iframe {
    width: 48rem;
    max-width: 100%; /* 부모 요소보다 커지지 않게 */
    height: 98rem;
  }

  footer {
    height: 30rem;
  }
  footer p {
    font-size: 2.3rem;
    margin: 1.5rem 0;
  }
}
@media (max-width: 440px) {
  .portfolio-container {
    height: 60rem;
  }
  .blog-item {
    width: 50rem;
    height: 65rem;
  }
  .blog-item p {
    font-size: 2.5rem;
    height: 15rem;
  }
  .blog-date {
    font-size: 2.5rem;
  }
}
