*, *::before, *::after {
  box-sizing: border-box;   /* padding/border가 너비에 포함되도록 해서 화면 밖으로 밀려나는 것 방지 */
}

html, body {
  height: 100%;
  overflow-x: hidden;   /* 가로 스크롤바 원천 차단 */
}
body {
  font-family: 'Noto Sans KR', sans-serif;
  margin: 0;
  padding: 0;
  background-color: #fff;
  color: #333;

  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* 헤더 */
header {
  background-color: #fff;
  padding: 20px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);   /* 로고 때문에 컬럼이 화면보다 넓어지는 것 방지 */
  align-items: center;
  width: 100%;
}

.logo {
  justify-self: start;
  margin-left: 60px;
  margin-top: 30px;
  width: 300px;
  height: auto;
  transition: transform 0.2s ease;
}

.logo:hover {
  transform: scale(1.04);
}

.logo:active {
  transform: scale(0.96);
}

body.home .logo:hover,
body.home .logo:active {
  transform: none;
}

/* 네비게이션 */
nav {
  justify-self: center;
  margin-top: 45px;
}

/* 메뉴(ABOUT · PORTFOLIO · CONTACT) 전체 블록의 위치 */
nav ul {
  list-style: none;
  display: flex;
  justify-content: center;
  margin-top: 0;
  padding: 0;

}
/* 메뉴 항목 박스(ABOUT, PORTFOLIO, CONTACT 각각의 박스)를 조절 */
nav ul li {
    margin: 0 20px;
}

/* 메뉴 글씨 */
nav ul li a {
  text-decoration: none;
  color: #4a4a4a;
  font-size: 13px;
  font-weight: bold;
  transition: color 0.2s ease;
  padding-top: 0;
}

nav ul li a:hover {
  color: #fff;
}

/* PORTFOLIO 드롭다운 */
.has-dropdown {
  position: relative;
}

/* 버튼과 드롭다운 사이 여백 구간에서도 마우스오버가 유지되도록 하는 투명 영역 */
.has-dropdown::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 16px;
}

.dropdown {
  display: flex;
  position: absolute;
  top: calc(100% + 16px);   /* 버튼과의 간격을 띄움 */
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  background-color: rgba(50, 50, 50, 0.95);   /* 회색 -> 좀 더 절제된 차콜 톤 */
  border-radius: 8px;
  min-width: 0;
  padding: 5px 13px;
  z-index: 10;

  flex-direction: row;
  gap: 0;

  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
}

.dropdown::before {
  content: "";
  position: absolute;
  top: -6px;
  left: 50%;
  width: 12px;
  height: 12px;
  background-color: rgba(50, 50, 50, 0.95);
  transform: translateX(-50%) rotate(45deg);
}

.has-dropdown:hover .dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.dropdown-link {
  display: block;
  text-align: center;
  padding: 2px 10px;
  color: #fff;
  font-size: 11px;
  font-weight: bold;
  text-decoration: none;
  letter-spacing: 1.2px;
  white-space: nowrap;
  position: relative;
}

.dropdown-link + .dropdown-link::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 14px;
  background-color: rgba(255, 255, 255, 0.3);
}

.dropdown-link:hover {
  color: #bbb;
}

.active-page {
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* 메인 사진 */
.hero {
  text-align: center;
  padding: 40px 20px 60px;
  background-color: #fff;
}

.hero img {
  max-width: 1280px;   /* 화면보다 커지지 않도록 상한선만 둠 */
  width: 100%;         /* 화면 크기에 맞게 자동으로 줄어듦 */
  height: auto;    /* 세로는 비율에 맞게 자동 */
  display: block;
  margin: 25px auto 0;
}

/* 홈(index) 화면만: 스크롤 없이 뷰포트 한 화면에 딱 맞추기 */
body.home {
  height: 100vh;
  overflow: hidden;
}

body.home .hero {
  flex: 1;
  min-height: 0;   /* flex 자식이 내용에 밀려 넘치지 않도록 */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px 20px 60px;   /* 하단 여백을 넉넉히 줘서 사진이 회색 바에 바로 붙지 않도록 함 */
}

body.home .hero-slideshow {
  position: relative;
  width: 100%;
  height: 100%;
  max-width: 1280px;
}

body.home .hero-slideshow img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 1.7s ease;
  margin: 0;
}

body.home .hero-slideshow img.active {
  opacity: 1;
}

/* 슬라이드쇼 마지막 컷에서만 살짝 나타나는 다시보기 아이콘 */
.replay-hint {
  position: absolute;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.4);
  pointer-events: none;   /* 클릭은 항상 컨테이너 전체가 받도록 */

  opacity: 0;
  transition: opacity 0.4s ease;
}

.replay-hint.show {
  opacity: 1;
}

.replay-icon {
  color: #fff;
  font-size: 17px;
  line-height: 1;
}

/* 포트폴리오 섹션 */
.portfolio {
  padding: 60px 40px 20px;
  flex: 1 0 auto;   /* 갤러리 페이지에서도 footer가 항상 맨 아래에 위치하도록 */
}

#info {
  padding: 60px 40px;
  flex: 1 0 auto;
}

.info-intro {
  text-align: center;
  margin-bottom: 50px;
}

.info-intro .info-title {
  font-size: 24px;
  font-weight: bold;
  color: #333;
  margin-bottom: 12px;
}

.info-intro .info-desc {
  font-size: 14px;
  color: #777;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  max-width: 900px;
  margin: 0 auto;
}

.info-card {
  padding: 30px;
  background-color: #fafafa;
  border-radius: 8px;
}

.info-card-title {
  font-size: 16px;
  font-weight: bold;
  color: #333;
  margin-bottom: 14px;
  letter-spacing: 0.5px;
}

.info-card-text {
  font-size: 13px;
  line-height: 1.8;
  color: #666;
}

.portfolio-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 30px;
}

.tab-btn {
  padding: 7px 14px;
  border: none;
  background-color: #f2f2f2;
  color: #333;
  font-weight: bold;
  font-size: 11px;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.tab-btn.active {
  background-color: #000;
  color: #fff;
}

.tab-btn:hover {
  background-color: #555;
  color: #fff;
}

.tab-btn.active:hover {
  background-color: #000;
  color: #fff;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-auto-rows: 8px;
  gap: 18px;
}

.portfolio-item {
  overflow: hidden;
}

.portfolio-item img {
  width: 100%;
  height: auto;   /* 원본 비율 그대로 유지 */
  display: block;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.portfolio-item img:hover {
  transform: scale(1.03);
}

/* 사진 크게 보기 (라이트박스) */
.lightbox {
  display: flex;
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.9);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 40px;

  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
}

.lightbox.open {
  opacity: 1;
  visibility: visible;
}

.lightbox img {
  max-width: 100%;
  max-height: 100%;
  display: block;
  transform: scale(0.92);
  transition: transform 0.3s ease;
}

.lightbox.open img {
  transform: scale(1);
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 32px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  line-height: 1;
  z-index: 1002;
}

.lightbox-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #fff;
  font-size: 32px;
  cursor: pointer;
  padding: 16px 20px;
  user-select: none;
  z-index: 1001;
  transition: opacity 0.2s ease;
  opacity: 0.75;
}

.lightbox-arrow:hover {
  opacity: 1;
}

.lightbox-prev {
  left: 12px;
}

.lightbox-next {
  right: 12px;
}

/* 푸터 */
footer {
  background-color: #B0B0B0;
  padding: clamp(19px, 2.5vh, 31px) clamp(24px, 4vw, 60px);
  border-top: 1px solid #ddd;

  position: relative;   /* 아이콘을 정중앙에 절대 배치하기 위한 기준점 */
  width: 100%;

  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: clamp(4px, 0.6vh, 10px);
}

/* 왼쪽 정보 텍스트 블록 */
.footer-left {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.footer-left p {
  margin: 0 0 2px 0;
  line-height: 1.45;
}

.footer-left .hours {
  color: #444;
  font-weight: bold;
  font-size: 11px;
}

.footer-left .closed {
  color: #777;
  font-size: 10px;
  margin-bottom: clamp(4px, 0.7vh, 8px);
}

.footer-left .info {
  color: #fff;
  font-size: 9px;
}

.footer-left .copyright {
  color: #8c8c8c;
  font-size: 8px;
  margin-top: clamp(5px, 0.9vh, 10px);
}

.footer-left .biz-info {
  color: #fff;
  font-size: 9px;
}
.footer-left .biz-info strong {
  font-weight: bold;
}

/* 오른쪽: 문의 버튼 */
.footer-right {
  display: flex;
  align-items: center;
}

.social-icons {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  gap: 14px;
}

.icon-circle {
  width: clamp(25px, 2.8vh, 32px);
  height: clamp(25px, 2.8vh, 32px);
  border-radius: 50%;
  border: 2px solid #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.icon-circle svg {
  display: block;
  width: clamp(12px, 1.4vh, 14px);
  height: clamp(12px, 1.4vh, 14px);
}

.contact-btn {
  background-color: #ffe812;
  color: #000;
  font-weight: bold;
  padding: clamp(6px, 0.9vh, 10px) clamp(18px, 2.2vh, 27px);
  border-radius: 40px;
  text-decoration: none;
  font-size: clamp(12px, 1.2vh, 14px);
  letter-spacing: 1px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.contact-btn:hover {
  background-color: #ffdb00;
}

/* ABOUT 섹션 - 스크롤 없이 한 화면에 들어오도록 압축 구성 */
#about {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  padding: 0;
}

.about-photo {
  flex: 0 0 auto;
}

.about-quote-mark {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 90px;
  color: #999;
  line-height: 1;
  margin-top: 60px;
  margin-bottom: -20px;
  text-align: center;
}

.about-photo img {
  width: 100%;
  height: 32vh;
  object-fit: cover;
  object-position: center 32%;
  display: block;
  filter: grayscale(100%);   /* 참고 이미지처럼 흑백 톤. 원하지 않으면 이 줄을 지우면 됨 */
}

.about-text {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  max-width: 680px;
  margin: 0 auto;
  padding: 0 20px 20px;
  text-align: center;
}

.about-text .quote {
  font-style: italic;
  font-size: 13px;
  color: #444;
  line-height: 1.5;
  margin-bottom: 16px;
}

.about-text .slogan {
  font-size: 17px;
  font-weight: bold;
  color: #4a4a4a;   /* 검정 -> 진한 회색 */
  margin-bottom: 14px;
}

.about-text p {
  font-size: 13px;
  line-height: 1.5;
  color: #666;
  margin-bottom: 12px;
}

.about-text .highlight {
  font-size: 13px;
  font-weight: bold;
  color: #4a4a4a;   /* 검정 -> 진한 회색 */
  line-height: 1.8;
  margin-top: 4px;
}

/* =========================================
   모바일 반응형 (화면 너비 768px 이하)
   ========================================= */
@media (max-width: 768px) {

  /* 헤더: 로고+메뉴 세로로 쌓기 */
  header {
    grid-template-columns: 1fr;
    justify-items: center;
    padding: 16px;
    row-gap: 10px;
  }

  .logo {
    justify-self: center;
    margin-left: 0;
    margin-top: 0;
    width: 180px;
  }

  nav {
    justify-self: center;
    margin-top: 0;
  }

  nav ul li {
    margin: 0 10px;
  }

  nav ul li a {
    font-size: 12px;
  }

  /* 모바일(터치 화면)은 :hover가 없어서 드롭다운이 안 열리므로
     WEDDING / ETC 서브메뉴를 항상 펼쳐진 상태로 보이게 함 */
  .has-dropdown::after {
    display: none;
  }

  .dropdown {
    position: static;
    transform: none;
    background-color: transparent;
    box-shadow: none;
    padding: 2px 0 0;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .dropdown::before {
    display: none;
  }

  .dropdown-link {
    color: #999;
    font-size: 10px;
    padding: 2px 8px;
  }

  .dropdown-link:hover,
  .dropdown-link.active-page {
    color: #333;
  }

  .dropdown-link + .dropdown-link::before {
    background-color: rgba(0, 0, 0, 0.2);
  }

  /* PORTFOLIO 메뉴 li를 세로 flex로 만들어서
     WEDDING | ETC가 PORTFOLIO 글자 밑 정중앙에 오도록 함
     (이렇게 안 하면 li 너비가 불균등해져서 전체 메뉴 간격이 틀어짐) */
  .has-dropdown {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  /* 홈 화면: 뷰포트 고정 대신 자연스러운 스크롤 허용 (모바일 주소창 높이 변화 대응) */
  body.home {
    height: auto;
    min-height: 100vh;
    overflow: visible;
  }

  body.home .hero {
    flex: none;
    height: auto;
    padding: 20px 12px 40px;
  }

  body.home .hero-slideshow {
    position: relative;
    width: 100%;
    max-width: 100%;
    height: auto;
    aspect-ratio: 3 / 2;
  }

  /* 포트폴리오 갤러리: 5열 -> 2열 */
  .portfolio {
    padding: 14px 16px 20px;
  }

  .portfolio-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    grid-auto-rows: 4px;
  }

  .portfolio-tabs {
    gap: 6px;
    margin-bottom: 18px;
  }

  .tab-btn {
    padding: 7px 12px;
    font-size: 10px;
  }

  .lightbox {
    padding: 10px;
  }

  .lightbox-arrow {
    font-size: 24px;
    padding: 10px 12px;
  }

  /* INFO 페이지: 카드 2열 -> 1열 */
  #info {
    padding: 30px 16px;
  }

  .info-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .info-intro .info-title {
    font-size: 19px;
  }

  /* ABOUT 페이지 */
  #about {
    height: auto;
  }

  .about-photo img {
    height: 30vh;
  }

  .about-quote-mark {
    font-size: 60px;
    margin-top: 30px;
  }

  .about-text {
    padding: 0 20px 30px;
  }

  /* 푸터: 세로로 쌓기 */
  footer {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px;
  }

  .footer-left {
    align-items: center;
    text-align: center;
    order: 1;
  }

  .social-icons {
    position: static;
    transform: none;
    order: 2;
  }

  .footer-right {
    order: 3;
  }
}

/* 좁은 화면(작은 폰) 추가 보정 */
@media (max-width: 400px) {
  .logo {
    width: 150px;
  }

  nav ul li {
    margin: 0 6px;
  }

  nav ul li a {
    font-size: 11px;
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .info-card {
    padding: 20px;
  }
}
