/* 그레이스퀘어 Save The Date — 실제 SVG path + 핸드라이팅 애니메이션 (하객용) */
.theme-4-wrap .theme_title .handwriting-svg-wrap {
  width: calc(100% - 30px);
  margin: 0 auto;
  position: relative;
  z-index: 1;
  padding: 8px 0 12px;
}
.theme-4-wrap .theme_title .handwriting-svg {
  width: 100%;
  display: block;
  overflow: visible;
  filter: drop-shadow(1px 2px 4px rgba(0,0,0,0.4)) drop-shadow(0px 1px 1px rgba(0,0,0,0.2));
}
.theme-4-wrap .theme_title .hw-letter {
  fill: none;
  stroke: #fff;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0;
}
.theme-4-wrap .theme_title .hw-letter.hw-animated {
  opacity: 1;
  -webkit-animation:
    hw-draw var(--hw-dur) ease-out var(--hw-del) forwards,
    hw-fill 0.3s ease var(--hw-fill-del) forwards;
  animation:
    hw-draw var(--hw-dur) ease-out var(--hw-del) forwards,
    hw-fill 0.3s ease var(--hw-fill-del) forwards;
}
@-webkit-keyframes hw-draw {
  to { stroke-dashoffset: 0; }
}
@keyframes hw-draw {
  to { stroke-dashoffset: 0; }
}
@-webkit-keyframes hw-fill {
  to { fill: #fff; stroke-width: 0; }
}
@keyframes hw-fill {
  to { fill: #fff; stroke-width: 0; }
}
/* 원본 Save The Date 이미지 숨김 (SVG로 대체) */
.theme-4-wrap .theme_title > img {
  display: none !important;
}
/* 타이틀 문구: We are Getting Married (피그마 1:39568, Tangerine Bold 2줄) — 폭 축소로 우측 상단 신랑/신부명 침범 방지 */
.theme-4-wrap .theme_title .handwriting-svg-wrap.hw-gm {
  width: 65%;
  padding: 4px 0 10px;
}
/* Tangerine은 획이 가늘어 그리기 단계 윤곽선 두께를 얇게 */
.theme-4-wrap .theme_title .handwriting-svg-wrap.hw-gm .hw-letter {
  stroke-width: 1.5;
}
/* Tangerine 굵기 보강: 채움 완료 후에도 흰색 stroke(1.6)를 남겨 글자를 굵게 */
.theme-4-wrap .theme_title .handwriting-svg-wrap.hw-gm .hw-letter.hw-animated {
  -webkit-animation:
    hw-draw var(--hw-dur) ease-out var(--hw-del) forwards,
    hw-fill-gm 0.3s ease var(--hw-fill-del) forwards;
  animation:
    hw-draw var(--hw-dur) ease-out var(--hw-del) forwards,
    hw-fill-gm 0.3s ease var(--hw-fill-del) forwards;
}
@-webkit-keyframes hw-fill-gm {
  to { fill: #fff; stroke-width: 1.6; }
}
@keyframes hw-fill-gm {
  to { fill: #fff; stroke-width: 1.6; }
}

/*calendar & countdown*/
.preview-calendar-wrap {
  padding: 2.5rem 0;
}
.preview-calendar-wrap .preview-inner-wrap {
  text-align: center;
}
.preview-calendar-title {
  margin-bottom: 1.5rem;
}
.preview-calendar-title .calendar-subtitle {
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  color: #999;
  margin-bottom: 0.3rem;
  font-style: italic;
}
.preview-calendar-title h2 {
  font-size: 1.25rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  margin: 0;
}
.preview-calendar-title .calendar-datetime {
  font-size: 1em !important;
}
.calendar-box {
  max-width: 320px;
  margin: 0 auto 1.5rem;
}
.calendar-month {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.8rem;
}
.calendar-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.calendar-table th {
  font-size: 0.75rem;
  font-weight: 500;
  color: #888;
  padding: 0.5rem 0;
  border-bottom: 1px solid #e0e0e0;
}
.calendar-table td {
  font-size: 0.85rem;
  padding: 0.6rem 0;
  color: #333;
}
.calendar-table .other-month {
  color: #ccc;
}
.calendar-table .sun,
.calendar-table th.sun {
  color: #d94040;
}
.calendar-table .sat,
.calendar-table th.sat {
  color: #d94040;
}
.wedding-day-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-color: #b8a89a;
  color: #fff;
  font-weight: 600;
}
.countdown-box {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 1.2rem;
}
.countdown-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 60px;
  padding: 10px 0;
  border: 1px solid #ddd;
  border-radius: 8px;
  background: #fff;
}
.countdown-label {
  font-size: 0.6rem;
  color: #999;
  letter-spacing: 0.08em;
  margin-bottom: 2px;
}
.countdown-value {
  font-size: 1.4rem;
  font-weight: 600;
  color: #333;
}
.countdown-message {
  font-size: 0.85rem;
  color: #666;
  margin: 0;
}
.countdown-heart {
  color: #b8a89a;
  margin: 0 2px;
}
.countdown-dday {
  color: #b8a89a;
  font-weight: 700;
}

/* 사진 효과 파티클 오버레이 */
.photo-effect-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  pointer-events: none;
  z-index: 10;
  overflow: hidden;
}
.photo-effect-particle {
  position: absolute;
  top: 0; left: 0;
  pointer-events: none;
  will-change: transform, opacity;
  opacity: 0;
}

/* ===== 방명록 작성하기 모달 디자인 ===== */
/* 모달 제목: 방명록 작성하기 */
.guestbook-write-modal .modal-title {
  color: #111111;
  font-size: 18px;
  font-family: "BookkMyungjo", "JejuMyeongjo", serif;
  font-weight: 700;
  word-wrap: break-word;
}
/* 입력 항목 라벨: 이름 / 내용 / 비밀번호 */
.guestbook-write-modal .form-group > .col-form-label {
  color: #111111;
  font-size: 13px;
  font-family: "BookkMyungjo", "JejuMyeongjo", serif;
  font-weight: 700;
  word-wrap: break-word;
}
/* 입력 필드 텍스트 */
.guestbook-write-modal .form-control {
  color: #111111;
  font-size: 13px;
  font-family: "Pretendard", sans-serif;
  font-weight: 400;
}
/* 입력 필드 플레이스홀더: 이름/내용/비밀번호 입력 안내 문구 */
.guestbook-write-modal .form-control::placeholder {
  color: rgba(17, 17, 17, 0.30);
  font-size: 10px;
  font-family: "Pretendard", sans-serif;
  font-weight: 400;
  word-wrap: break-word;
}
.guestbook-write-modal .form-control::-webkit-input-placeholder {
  color: rgba(17, 17, 17, 0.30);
  font-size: 10px;
  font-family: "Pretendard", sans-serif;
  font-weight: 400;
}
.guestbook-write-modal .form-control::-moz-placeholder {
  color: rgba(17, 17, 17, 0.30);
  font-size: 10px;
  font-family: "Pretendard", sans-serif;
  font-weight: 400;
  opacity: 1;
}
/* 등록하기 버튼 */
.guestbook-write-modal .btn-dark {
  color: white;
  font-size: 13px;
  font-family: "BookkMyungjo", "JejuMyeongjo", serif;
  font-weight: 700;
  word-wrap: break-word;
}

/* ===== 페이지 로딩 오버레이 ===== */
/* 페이지 로딩(window load)이 완료될 때까지 전체 화면을 덮는 로딩중 화면 */
#pageLoadingOverlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 99999;
  background: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  opacity: 1;
  transition: opacity 0.4s ease;
}
/* 로딩 완료 시 fade-out 용 클래스 */
#pageLoadingOverlay.loaded {
  opacity: 0;
  pointer-events: none;
}
/* 회전 스피너 */
#pageLoadingOverlay .loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #e5e5e5;
  border-top-color: #b08c6e;
  border-radius: 50%;
  animation: pageLoadingSpin 0.9s linear infinite;
}
/* 로딩중 안내 문구 */
#pageLoadingOverlay .loading-text {
  color: #999;
  font-size: 13px;
  font-family: "Pretendard", sans-serif;
  letter-spacing: 2px;
}
@keyframes pageLoadingSpin {
  to { transform: rotate(360deg); }
}
