/* ==============================================================
   통바이블 리뉴얼 — 레퍼런스: heritade.com 벤토 카드 UI
   · 플랫 캔버스 배경 + 흰색 라운드 카드(20px) + 5px 카드 간격
   · EN 눈썹 + KR 제목 페어, 대형 디스플레이 타이포, 마키
   · 시니어 보정: Pretendard, 본문 18px+, 고대비, 48px 터치영역
   ============================================================== */

:root {
  --canvas: #111111;      /* 페이지 배경 — heritade 메인(body.main) 블랙 */
  --light: #F0F0F0;
  --black: #111111;
  --deep: #202020;
  --dark: #8A8A8A;
  --gray: #E0E0E0;
  --white: #FFFFFF;
  --point: #FFD80C;       /* 포인트 옐로 (heritade --point 동일) */

  --fs-base: 1.15rem;     /* 18.4px */
  --radius: 20px;
  --radius-s: 15px;
  --gap: 5px;
  --pad: clamp(1.6rem, 3vw, 3.1rem);
}

/* 글자 크기 조절(가− / 가+) 단계 — JS가 html에 클래스를 붙임 */
html { font-size: 100%; scroll-behavior: smooth; }
/* 앵커 이동 시 고정 헤더에 가려지지 않도록 도착 지점에 여유 확보 */
[id] { scroll-margin-top: 6.8rem; }
html.font-lv2 { font-size: 112.5%; }
html.font-lv3 { font-size: 125%; }

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: "Pretendard Variable", Pretendard, -apple-system, "Malgun Gothic", sans-serif;
  font-size: var(--fs-base);
  line-height: 1.7;
  letter-spacing: -0.25px;
  color: var(--black);
  background: var(--canvas);
  word-break: keep-all;
  overflow-x: hidden;
}

/* ===== 자연스러운 한국어 줄바꿈 =====
   keep-all(어절 단위) + balance/pretty(어색한 외톨이 단어 방지)
   .nb = 의미 단위로 묶어 중간에서 끊기지 않게 하는 덩어리 */
h1, h2, h3, .sec-title .kr, .join-body strong { text-wrap: balance; }
p, dd, .sec-desc { text-wrap: pretty; }
.nb { white-space: nowrap; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; cursor: pointer; }
ul, li { list-style: none; }
button { font-family: inherit; cursor: pointer; background: transparent; border: 0; }

::selection { background: var(--point); }

/* ==============================================================
   인트로 스크린 — 첫 진입 애니메이션 (heritade .screen)
   ① 검은 화면에서 글자 깜빡임 → ② 노란 곡면(돔)이 아래에서
   차오르며 화면을 덮음 → ③ 전체가 위로 걷히며 본문 등장
   ============================================================== */
.screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--black);
  overflow: hidden;
  transition: transform 0.85s cubic-bezier(0.76, 0, 0.24, 1);
}
/* 아래에서 차오르는 노란 돔 곡면 */
.screen-curve {
  position: absolute;
  left: -10vw;
  top: 100%;
  width: 120vw;
  height: 140vh;
  background: var(--point);
  border-radius: 50% 50% 0 0 / 14vh 14vh 0 0;
  transition: transform 0.75s cubic-bezier(0.65, 0, 0.35, 1);
}
.screen.cover .screen-curve { transform: translateY(-120vh); }

.screen-text { position: relative; z-index: 2; display: flex; gap: 0.32em; transition: transform 0.45s ease, opacity 0.45s ease; }
.screen.cover .screen-text { transform: translateY(-70px); opacity: 0; }
.screen-text span {
  font-size: clamp(2rem, 6vw, 4.5rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--white);
  line-height: 1;
  animation: intro-blink 0.65s infinite alternate;
}
.screen-text span:nth-child(1) { animation-delay: 0s; }
.screen-text span:nth-child(2) { animation-delay: 0.07s; }
.screen-text span:nth-child(3) { animation-delay: 0.14s; }
.screen-text span:nth-child(4) { animation-delay: 0.21s; }
.screen-text span:nth-child(5) { animation-delay: 0.28s; }
.screen-text span:nth-child(6) { animation-delay: 0.35s; }
.screen-text span:nth-child(7) { animation-delay: 0.42s; }
.screen-text span:nth-child(8) { animation-delay: 0.49s; }
.screen-text span:nth-child(9) { animation-delay: 0.56s; }
.screen-text span:nth-child(10) { animation-delay: 0.63s; }
@keyframes intro-blink { from { opacity: 1; } to { opacity: 0; } }

.screen.leave { transform: translateY(-140vh); }
@media (prefers-reduced-motion: reduce) {
  .screen { display: none; }
}

/* ===== 화면 전체 프레임 (heritade #smooth-wrapper 10px, 좌우 꽉 채움) ===== */
.frame {
  padding: 10px;
  width: 100%;
}

/* ===== 카드 공통 ===== */
.card {
  background: var(--white);
  border-radius: var(--radius);
}
.card.dark { background: var(--deep); color: var(--white); } /* 다크 캔버스와 구분되는 딥 그레이 */
.card.point { background: var(--point); }

/* ===== 카드 행 (5px 간격) ===== */
.row {
  display: grid;
  gap: var(--gap);
  margin-top: var(--gap);
}

.pc-only { display: inline; }

/* ===== 이미지 플레이스홀더 ===== */
.img-placeholder {
  position: relative;
  background: repeating-linear-gradient(45deg, #E4E4E4 0 14px, #EDEDED 14px 28px);
  min-height: 200px;
}
.img-placeholder::after {
  content: attr(data-label);
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1rem;
  color: var(--dark);
  font-size: 0.95rem;
}
.placeholder-text { color: var(--dark); font-size: 0.9em; }

/* ===== EN + KR 타이틀 페어 (heritade 패턴) ===== */
.sec-title .en {
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--dark);
  margin-bottom: 0.5rem;
}
.sec-title .kr {
  font-size: clamp(1.6rem, 2.6vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.3;
  color: inherit;
}
/* 캔버스(다크) 위에 바로 놓이는 큰 섹션 제목 — 흰 글자 */
.sec-title.big { padding: clamp(2.5rem, 5vw, 4.5rem) var(--pad) 1.4rem; }
.sec-title.big .kr { font-size: clamp(2rem, 3.6vw, 3rem); color: var(--white); }
.card.dark .sec-title .en, .card.dark .placeholder-text { color: #9A9A9A; }
.sec-desc { color: var(--dark); margin-top: 0.6rem; }

/* ==============================================================
   헤더 — 흰색 라운드 카드 바
   ============================================================== */
.header {
  position: sticky;
  top: 10px;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 5rem;
  padding: 0.6rem 1.1rem 0.6rem 1.6rem;
  box-shadow: 0 10px 30px rgba(17, 17, 17, 0.07);
}

.logo { display: flex; align-items: center; gap: 0.6rem; font-weight: 800; }
.logo-mark {
  display: grid;
  place-items: center;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  background: var(--black);
  color: var(--point);
  font-size: 1.2rem;
}
.logo-text { font-size: 1.4rem; letter-spacing: -0.02em; }

.gnb ul { display: flex; gap: 0.15rem; }
.gnb a {
  display: inline-flex;
  align-items: center;
  min-height: 3.2rem;
  padding: 0.3rem 1.15rem;
  font-size: 1.25rem;
  font-weight: 700;
  border-radius: 100px;
  transition: background 0.2s;
}
.gnb a:hover, .gnb a:focus-visible { background: var(--light); }

.header-tools { display: flex; align-items: center; gap: 0.6rem; }

.font-control { display: flex; gap: 0.35rem; }
.font-control button {
  min-width: 3rem;
  min-height: 3rem;
  border: 1.5px solid var(--gray);
  border-radius: 100px;
  background: var(--white);
  font-size: 1rem;
  font-weight: 700;
  color: var(--black);
  transition: border-color 0.2s, background 0.2s;
}
.font-control button:hover { border-color: var(--black); }
.font-control small { font-size: 0.8em; font-weight: 800; }

/* 검정 알약 CTA (heritade "제작 문의하기" 버튼) */
.header-cta {
  display: inline-flex;
  align-items: center;
  min-height: 3.2rem;
  padding: 0.4rem 1.5rem;
  border-radius: 100px;
  background: var(--black);
  color: var(--white);
  font-size: 1.02rem;
  font-weight: 700;
  transition: background 0.2s, color 0.2s;
}
.header-cta:hover { background: var(--point); color: var(--black); }

/* 모바일 메뉴 버튼 — "메뉴" 글자 병기 */
.menu-toggle {
  display: none;
  align-items: center;
  gap: 0.5rem;
  min-height: 3.2rem;
  padding: 0.4rem 1.1rem;
  border: 1.5px solid var(--black);
  border-radius: 100px;
  color: var(--black);
  font-size: 1.02rem;
  font-weight: 700;
}
.menu-toggle-icon { display: inline-flex; flex-direction: column; gap: 4px; }
.menu-toggle-icon i {
  width: 18px; height: 2.5px;
  background: var(--black);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}
.menu-open .menu-toggle-icon i:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.menu-open .menu-toggle-icon i:nth-child(2) { opacity: 0; }
.menu-open .menu-toggle-icon i:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ==============================================================
   비주얼 — 슬로건 카드 + 배너 슬라이드 카드
   ============================================================== */
.visual {
  display: grid;
  grid-template-columns: minmax(24rem, 2fr) 3fr;
  gap: var(--gap);
  margin-top: var(--gap);
  align-items: stretch;
}

.slogan {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: var(--pad);
  min-height: 30rem;
}
.slogan-kr {
  font-size: 1.18rem;
  font-weight: 500;
  padding-bottom: 1.4rem;
  border-bottom: 1px solid var(--black);
}
/* 대형 타이포 여러 줄 — 회색+검정 섞음, 通 알약 (heritade 스타일) */
.slogan-display {
  margin: auto 0;
  padding: 2.6rem 0 2.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.slogan-display .line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.2em;
  font-size: clamp(2.7rem, 4.8vw, 5.2rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--black);
  text-transform: uppercase;
}
.slogan-display .gray { color: #B0B0B0; }
.slogan-display .dot { font-style: normal; color: var(--point); }
.slogan-display .pill {
  display: inline-grid;
  place-items: center;
  font-size: 0.55em;
  width: 3.2em;
  height: 1.55em;
  border-radius: 100px;
  background: var(--black);
  color: var(--point);
  font-weight: 800;
  letter-spacing: 0;
}

.slogan-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 3.4rem;
  font-size: 1.1rem;
  font-weight: 700;
  align-self: flex-start;
  padding: 0.5rem 1.7rem;
  border-radius: 14px;
  background: var(--point);
  color: var(--black);
  transition: background 0.2s, color 0.2s;
}
.slogan-link:hover { background: var(--black); color: var(--point); }

.slogan-foot {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  margin-top: 2rem;
  font-size: 0.95rem;
  color: var(--dark);
}
.slogan-foot > span:first-child { flex-shrink: 0; }
.slogan-foot > span:first-child::after { content: "·"; margin-left: 0.35rem; }

/* ===== 메인 슬라이드 배너 카드 ===== */
.visual-media {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.banner-slider {
  position: relative;
  overflow: hidden;
  flex: 1;
  background: var(--gray);
}
.banner-track { display: flex; height: 100%; transition: transform 0.55s ease; }
.banner-slide { flex: 0 0 100%; display: block; }
.banner-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
a.banner-slide:focus-visible { outline: 3px solid var(--point); outline-offset: -3px; }

/* 큰 좌우 화살표 — 시니어가 누르기 쉽게 */
.banner-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 3.2rem;
  height: 3.2rem;
  border-radius: 50%;
  background: rgba(17, 17, 17, 0.55);
  color: var(--white);
  font-size: 1.9rem;
  line-height: 1;
  display: grid;
  place-items: center;
  padding-bottom: 0.25rem;
  transition: background 0.2s;
}
.banner-arrow:hover { background: var(--black); }
.banner-arrow.prev { left: 0.9rem; }
.banner-arrow.next { right: 0.9rem; }

.banner-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  flex-wrap: wrap;
  background: var(--white);
}
.banner-dots { display: flex; gap: 0.55rem; flex-wrap: wrap; }
.banner-dots button {
  width: 0.95rem;
  height: 0.95rem;
  border-radius: 50%;
  background: var(--gray);
  transition: background 0.2s, transform 0.2s;
}
.banner-dots button.on { background: var(--black); transform: scale(1.25); }
.banner-pause {
  min-height: 2.6rem;
  padding: 0.25rem 1rem;
  border: 1.5px solid var(--gray);
  border-radius: 100px;
  color: var(--deep);
  font-size: 0.92rem;
  font-weight: 600;
}
.banner-pause:hover { border-color: var(--black); }

/* ==============================================================
   통바이블이란? — who 카드 + 스탯 카드들
   ============================================================== */
#tongbible { grid-template-columns: 2fr 1fr 1fr 1fr; }
.who, .stat {
  padding: var(--pad);
  min-height: 24rem;
  display: flex;
  flex-direction: column;
}
.who-text { margin-top: auto; padding-top: 2rem; font-size: 1.25rem; font-weight: 500; }
.stat p { margin-top: 1.1rem; color: var(--deep); font-size: 1.02rem; }
.card.point .stat p { color: var(--black); }
.stat-num {
  margin-top: auto;
  padding-top: 1.5rem;
  font-size: clamp(3rem, 4.5vw, 4.5rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
}
.stat-num span { font-size: 1.05rem; font-weight: 700; margin-left: 0.35rem; letter-spacing: 0; }
.stat-link {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  align-self: flex-start;
  min-height: 3.2rem;
  padding: 0.4rem 1.5rem;
  border-radius: 100px;
  background: var(--black);
  color: var(--white);
  font-weight: 700;
  transition: opacity 0.2s;
}
.stat-link:hover { opacity: 0.82; }

/* ==============================================================
   마키 — 대형 흐르는 타이포 (canvas 위 흰 글자)
   ============================================================== */
.marquee {
  overflow: hidden;
  padding: clamp(2.5rem, 6vw, 5.5rem) 0;
  white-space: nowrap;
}
.marquee-inner { display: inline-flex; animation: marquee 30s linear infinite; }
.marquee-inner span {
  font-size: clamp(5rem, 13vw, 12rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.05em;
  color: var(--white);
  white-space: nowrap;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee-inner { animation: none; }
}

/* ==============================================================
   짧은 말씀 영상 · 쇼츠 — 가로 스크롤 스트립
   ============================================================== */
.shorts-wrap {
  margin-top: var(--gap);
  padding: var(--pad);
}
.shorts-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
}
.shorts-nav { display: flex; gap: 0.5rem; }
.shorts-nav button {
  width: 3.2rem;
  height: 3.2rem;
  border-radius: 50%;
  border: 1.5px solid var(--gray);
  background: var(--white);
  color: var(--black);
  font-size: 1.7rem;
  line-height: 1;
  display: grid;
  place-items: center;
  padding-bottom: 0.2rem;
  transition: background 0.2s, border-color 0.2s;
}
.shorts-nav button:hover { background: var(--point); border-color: var(--point); }

.shorts-strip {
  display: flex;
  gap: 1rem;
  margin-top: 1.6rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 0.8rem;
  -webkit-overflow-scrolling: touch;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
.shorts-strip.dragging {
  cursor: grabbing;
  scroll-snap-type: none;
  scroll-behavior: auto;
}
.shorts-strip::-webkit-scrollbar { height: 8px; }
.shorts-strip::-webkit-scrollbar-track { background: var(--light); border-radius: 100px; }
.shorts-strip::-webkit-scrollbar-thumb { background: var(--gray); border-radius: 100px; }
.shorts-strip::-webkit-scrollbar-thumb:hover { background: var(--black); }

.shorts-card {
  flex: 0 0 auto;
  width: clamp(15rem, 18.5vw, 26rem);
  scroll-snap-align: start;
  border-radius: var(--radius-s);
  overflow: hidden;
  background: var(--light);
}
/* 데스크톱: 등록된 쇼츠 전부가 화면 좌우에 딱 맞게 (JS가 --shorts-count 지정)
   단, 개수가 많아지면 최소 12rem을 지키고 옆으로 스와이프 */
@media (min-width: 64.01rem) {
  .shorts-card {
    width: max(12rem, calc((100% - (var(--shorts-count, 7) - 1) * 1rem) / var(--shorts-count, 7)));
  }
  .shorts-strip { padding-bottom: 0.4rem; }
}
.shorts-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 16;
  display: block;
  background: var(--deep);
  overflow: hidden;
}
.shorts-thumb img { width: 100%; height: 100%; object-fit: cover; }
.shorts-thumb .play-badge { position: absolute; inset: 0; display: grid; place-items: center; }
.shorts-thumb .play-badge span {
  width: 3.6rem;
  height: 3.6rem;
  border-radius: 50%;
  background: rgba(17, 17, 17, 0.85);
  color: var(--white);
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  padding-left: 0.25rem;
  transition: transform 0.2s, background 0.2s, color 0.2s;
}
.shorts-thumb:hover .play-badge span { transform: scale(1.1); background: var(--point); color: var(--black); }
.shorts-card iframe {
  width: 100%;
  aspect-ratio: 9 / 16;
  border: 0;
  display: block;
}

/* ==============================================================
   교회와 사역 — work 카드 3장
   ============================================================== */
.work-row { grid-template-columns: repeat(4, 1fr); }
.work { overflow: hidden; display: flex; flex-direction: column; transition: transform 0.25s, box-shadow 0.25s; }
.work:hover { transform: translateY(-5px); box-shadow: 0 16px 34px rgba(17, 17, 17, 0.22); }
.work-media { aspect-ratio: 4 / 3; min-height: 0; overflow: hidden; }
.work-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.work:hover .work-media img { transform: scale(1.05); }
.work-body { padding: 1.4rem 1.7rem 1.6rem; flex: 1; }
.work-body h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 0.5rem; letter-spacing: -0.02em; }
.work-body p { color: var(--deep); margin-bottom: 0.7rem; font-size: 1.02rem; }
.work-info { font-size: 1rem; }
.text-link {
  font-weight: 700;
  border-bottom: 2px solid var(--point);
  padding-bottom: 0.1rem;
}
.text-link:hover { opacity: 0.7; }

/* ==============================================================
   커뮤니티 · 소식 — 게시판 카드 + 도구 카드 + 콘텐츠 배너
   ============================================================== */
.news-row { grid-template-columns: repeat(2, 1fr); }

.board-card { padding: var(--pad); display: flex; flex-direction: column; }
.board-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--black);
  margin-bottom: 0.4rem;
}
.board-head h3 { font-size: 1.4rem; font-weight: 800; letter-spacing: -0.02em; }
.board-more {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--dark);
  transition: color 0.2s;
}
.board-more:hover { color: var(--black); }

.board-list { display: flex; flex-direction: column; }
.board-list li { border-bottom: 1px solid var(--light); }
.board-list li:last-child { border-bottom: 0; }
.board-list a {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-height: 3.5rem;
  padding: 0.5rem 0;
  transition: color 0.2s;
}
.board-list .b-title {
  flex: 1;
  font-size: 1.05rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.board-list .b-date { flex-shrink: 0; font-size: 0.92rem; color: var(--dark); }
.board-list .b-go { flex-shrink: 0; color: var(--dark); transition: color 0.2s; }
.board-list a:hover .b-title { color: var(--black); text-decoration: underline; text-underline-offset: 3px; }
.board-list a:hover .b-go { color: var(--black); }

/* 성경 읽기 도구 — 2열 알약 박스 (마우스오버 색 변화) */
.tools-wrap { margin-top: var(--gap); padding: var(--pad); }
.tool-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.8rem;
  margin-top: 1.8rem;
}
.tool-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  min-height: 4rem;
  padding: 0.7rem 1.8rem;
  border: 1.5px solid var(--gray);
  border-radius: 100px;
  font-size: 1.1rem;
  font-weight: 700;
  transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
}
.tool-pill .tp-go { color: var(--dark); transition: color 0.2s; }
.tool-pill:hover {
  background: var(--point);
  border-color: var(--point);
  color: var(--black);
  transform: translateY(-2px);
}
.tool-pill:hover .tp-go { color: var(--black); }

/* 콘텐츠 배너 — heritade식 컬러 카드 (큰 타이포 + 원형 화살표) */
.content-row { grid-template-columns: repeat(4, 1fr); }
.content-banner {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 13rem;
  padding: 1.7rem;
  background: var(--deep);
  color: var(--white);
  overflow: hidden;
  transition: transform 0.25s, box-shadow 0.25s;
}
.content-banner:hover { transform: translateY(-5px); box-shadow: 0 16px 34px rgba(17, 17, 17, 0.25); }
.content-banner.point { color: var(--black); }
.content-banner .cb-en {
  position: absolute;
  top: 1.6rem;
  left: 1.7rem;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.7);
}
.content-banner.point .cb-en { color: rgba(17, 17, 17, 0.6); }
.content-banner strong { font-size: 1.6rem; font-weight: 800; letter-spacing: -0.02em; }
.content-banner .cb-arrow {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
  width: 3rem;
  height: 3rem;
  border: 1.5px solid rgba(255, 255, 255, 0.55);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  transition: background 0.25s, color 0.25s, border-color 0.25s, transform 0.25s;
}
.content-banner.point .cb-arrow { border-color: rgba(17, 17, 17, 0.5); }
.content-banner:hover .cb-arrow {
  background: var(--point);
  border-color: var(--point);
  color: var(--black);
  transform: rotate(-45deg);
}
.content-banner.point:hover .cb-arrow { background: var(--black); border-color: var(--black); color: var(--point); }

/* ==============================================================
   말씀 영상 — 흰 카드 안 영상 그리드
   ============================================================== */
.media-wrap, .sponsor-wrap {
  margin-top: var(--gap);
  padding: var(--pad);
}
.video-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
  margin-top: 2rem;
}
.video-card {
  background: var(--light);
  border-radius: var(--radius-s);
  overflow: hidden;
}
.video-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--deep);
  width: 100%;
  display: block;
  border-radius: var(--radius-s) var(--radius-s) 0 0;
  overflow: hidden;
}
.video-thumb img { width: 100%; height: 100%; object-fit: cover; }
.video-thumb .play-badge { position: absolute; inset: 0; display: grid; place-items: center; }
.video-thumb .play-badge span {
  width: 4.2rem;
  height: 4.2rem;
  border-radius: 50%;
  background: rgba(17, 17, 17, 0.85);
  color: var(--white);
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  padding-left: 0.3rem;
  transition: transform 0.2s, background 0.2s, color 0.2s;
}
.video-thumb:hover .play-badge span { transform: scale(1.08); background: var(--point); color: var(--black); }
.video-card iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; display: block; }
.video-card-title { padding: 1rem 1.3rem 1.2rem; font-size: 1.08rem; font-weight: 700; }
/* 주소가 비어 있는 영상 자리 안내 */
.video-thumb.is-empty {
  background: repeating-linear-gradient(45deg, #E4E4E4 0 14px, #EDEDED 14px 28px);
  cursor: default;
}
.video-thumb.is-empty .empty-note {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--dark);
  font-size: 0.95rem;
  padding: 1rem;
  text-align: center;
}

/* ==============================================================
   참여·후원 — 알약 카드 4장 + 검정 전화 카드
   ============================================================== */
.join-row { grid-template-columns: repeat(4, 1fr); }
/* 이미지 배경 + 다크 오버레이 카드 (아이콘 없이) */
.join-item {
  position: relative;
  display: block;
  min-height: 21rem;
  overflow: hidden;
  color: var(--white);
}
.join-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.62) saturate(0.9);
  transition: transform 0.55s ease, filter 0.4s ease;
}
.join-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17,17,17,0.15) 30%, rgba(17,17,17,0.72) 100%);
}
.join-item:hover .join-bg { transform: scale(1.06); filter: brightness(0.5) saturate(1); }
.join-body {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.3rem;
  padding: 1.7rem;
}
.join-en {
  position: absolute;
  top: 1.6rem;
  left: 1.7rem;
  font-size: 0.88rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: rgba(255, 255, 255, 0.75);
}
.join-body strong { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.02em; color: var(--white); }
.join-desc { font-size: 1.02rem; color: rgba(255, 255, 255, 0.82); }
.join-arrow {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
  width: 3rem;
  height: 3rem;
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  color: var(--white);
  transition: background 0.25s, color 0.25s, border-color 0.25s, transform 0.25s;
}
.join-item:hover .join-arrow {
  background: var(--point);
  border-color: var(--point);
  color: var(--black);
  transform: rotate(-45deg);
}

.call {
  margin-top: var(--gap);
  text-align: center;
  padding: clamp(3rem, 6vw, 5rem) var(--pad);
}
.call-label { font-size: 1.15rem; font-weight: 500; color: #C4C4C4; margin-bottom: 1rem; }
.call-number {
  display: inline-block;
  font-size: clamp(2.6rem, 7vw, 5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 0.5rem;
  transition: color 0.2s;
}
.call-number:hover { color: var(--point); }
.call-sub { color: #C4C4C4; font-size: 1rem; margin-top: 0.6rem; }
.call-sub a { color: var(--white); font-weight: 700; border-bottom: 1px solid var(--point); }

/* ===== 후원 배너 그리드 (heritade client-box) ===== */
.sponsor-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}
.sponsor-item {
  display: block;
  border: 1.5px solid var(--gray);
  border-radius: var(--radius-s);
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
a.sponsor-item:hover {
  border-color: var(--black);
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(17, 17, 17, 0.1);
}
.sponsor-item img { width: 100%; height: auto; display: block; }

/* ==============================================================
   오시는 길 — 지도 카드 + 정보 카드
   ============================================================== */
.location-row { grid-template-columns: 3fr 2fr; }
.location-map { min-height: 26rem; border-radius: var(--radius); overflow: hidden; }
.location-map iframe {
  width: 100%;
  height: 100%;
  min-height: 26rem;
  border: 0;
  display: block;
}
.map-links { display: flex; flex-wrap: wrap; gap: 0.7rem; margin-top: 2rem; }
.map-links a {
  display: inline-flex;
  align-items: center;
  min-height: 3.2rem;
  padding: 0.4rem 1.4rem;
  border-radius: 100px;
  border: 1.5px solid var(--gray);
  font-size: 1.02rem;
  font-weight: 700;
  transition: border-color 0.2s, background 0.2s;
}
.map-links a:hover { border-color: var(--black); background: var(--light); }
.location-info { padding: var(--pad); }
.location-info dl { margin-top: 1.5rem; }
.location-info dt {
  font-size: 0.95rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--dark);
  margin-top: 1.4rem;
}
.location-info dd { font-size: 1.1rem; margin-top: 0.2rem; }
.tel-link {
  font-size: 1.5rem;
  font-weight: 800;
  border-bottom: 2px solid var(--point);
}
.tel-link.sub { font-size: 1.15rem; font-weight: 700; }
.location-info dd a:not(.tel-link) { border-bottom: 1px solid var(--gray); }

/* ==============================================================
   푸터 — heritade식: 워드마크 + 정보 칩 / 전화 문의 바
   ============================================================== */
.footer-row {
  display: grid;
  grid-template-columns: 2.2fr 1fr;
  gap: var(--gap);
  margin-top: var(--gap);
  align-items: stretch;
}
.footer-main { padding: var(--pad); display: flex; flex-direction: column; }
.footer-wordmark {
  font-size: clamp(2.2rem, 3.6vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
}
.footer-wordmark .dot { color: var(--point); }

.footer-chips { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1.8rem; }
.chip {
  display: inline-flex;
  align-items: center;
  min-height: 3rem;
  padding: 0.45rem 1.2rem;
  border: 1.5px solid var(--gray);
  border-radius: 100px;
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--black);
}
a.chip { transition: border-color 0.2s, background 0.2s; }
a.chip:hover { border-color: var(--black); background: var(--light); }
.chip-point { background: var(--point); border-color: var(--point); font-weight: 800; }

.footer-copy { margin-top: 1.8rem; font-size: 0.92rem; color: var(--dark); }

/* 오른쪽 열: 문구 카드 + 전화 바 (레퍼런스의 뉴스레터 자리) */
.footer-side { display: flex; flex-direction: column; gap: var(--gap); }
.footer-cta { flex: 1; padding: 1.8rem; }
.footer-cta-en {
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--dark);
  margin-bottom: 0.5rem;
}
.footer-cta-kr { font-size: 1.25rem; font-weight: 800; letter-spacing: -0.02em; }

.footer-callbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0.7rem 0.7rem 1.6rem;
}
.callbar-num { font-size: clamp(1.4rem, 2vw, 1.8rem); font-weight: 800; letter-spacing: 0.01em; }
.callbar-btn {
  flex-shrink: 0;
  width: 3.8rem;
  height: 3.8rem;
  border-radius: 16px;
  background: var(--point);
  color: var(--black);
  display: grid;
  place-items: center;
  font-size: 1.35rem;
  transition: background 0.2s, color 0.2s, transform 0.2s;
}
.callbar-btn:hover { background: var(--black); color: var(--point); transform: scale(1.05); }

/* ===== 맨 위로 버튼 ===== */
.to-top {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 90;
  min-height: 2.7rem;
  padding: 0.45rem 1rem;
  border-radius: 100px;
  background: var(--white);
  color: var(--black);
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(17, 17, 17, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}
.to-top.show { opacity: 1; pointer-events: auto; }

/* ===== 스크롤 리빌 (heritade fade-anim, data-delay 지원) ===== */
.fade-anim {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.fade-anim.on { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .fade-anim { opacity: 1; transform: none; transition: none; }
}

/* ==============================================================
   반응형
   ============================================================== */
@media (max-width: 80rem) {
  /* 이 폭에서는 후원 배너가 3열이면 답답해서 2열로 */
  .sponsor-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 74rem) {
  #tongbible { grid-template-columns: 1fr 1fr; }
  .who { grid-column: 1 / -1; min-height: 0; }
  .who-text { padding-top: 1.4rem; }
  .stat { min-height: 19rem; }
  /* 홀수로 남는 세미나·교재 카드는 가로 전체를 차지해 빈칸 방지 */
  .stat.point { grid-column: 1 / -1; min-height: 0; }
  .stat.point .stat-link { margin-top: 1.6rem; }
  /* 교회와 사역 4카드 → 2열 */
  .work-row { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 64rem) {
  .visual { grid-template-columns: 1fr; }
  .slogan { min-height: 0; }
  .slogan-display { padding: 3rem 0 2.4rem; }
  .banner-slide img { aspect-ratio: 1920 / 500; height: auto; }
  .banner-slider { flex: none; }
  .work-row { grid-template-columns: repeat(2, 1fr); }
  .join-row { grid-template-columns: repeat(2, 1fr); }
  .join-item { min-height: 12rem; }
  .video-grid { grid-template-columns: repeat(2, 1fr); }
  .sponsor-grid { grid-template-columns: repeat(2, 1fr); }
  .content-row { grid-template-columns: repeat(2, 1fr); }
  .location-row { grid-template-columns: 1fr; }
  .location-map { min-height: 20rem; }
  .location-map iframe { min-height: 20rem; }
  .footer-row { grid-template-columns: 1fr; }
  .pc-only { display: none; }
}

@media (max-width: 48rem) {
  .frame { padding: 5px; }
  .header { top: 5px; padding: 0.5rem 0.8rem 0.5rem 1.1rem; }
  .header-cta { display: none; }

  /* --- 모바일 메뉴: 헤더 아래 카드로 크게 펼침 --- */
  .menu-toggle { display: inline-flex; }
  .gnb {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    right: 0;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: 0 18px 40px rgba(17, 17, 17, 0.16);
    display: none;
  }
  .menu-open .gnb { display: block; }
  .gnb ul { flex-direction: column; padding: 0.7rem; gap: 0.15rem; }
  .gnb a {
    display: flex;
    width: 100%;
    min-height: 3.9rem;
    font-size: 1.4rem;
    border-radius: var(--radius-s);
    padding: 0.5rem 1.2rem;
  }
  .shorts-card { width: min(72vw, 20rem); }
  .gnb li + li a { border-top: 1px solid #EEEEEE; }

  .banner-slide img { aspect-ratio: 1000 / 500; }
  .banner-arrow { width: 2.8rem; height: 2.8rem; font-size: 1.6rem; }

  #tongbible { grid-template-columns: 1fr; }
  .stat { min-height: 0; }
  .stat-num { padding-top: 2rem; }
  .join-row { grid-template-columns: 1fr; }
  .join-item { min-height: 0; gap: 0.3rem; }
  .join-icon { margin-bottom: 0.5rem; }
  .video-grid, .sponsor-grid { grid-template-columns: 1fr; }
  .work-row { grid-template-columns: 1fr; }
  .news-row { grid-template-columns: 1fr; }
  .tool-grid { grid-template-columns: 1fr; }
  .tool-pill { min-height: 3.6rem; padding: 0.6rem 1.4rem; }
  .content-row { grid-template-columns: repeat(2, 1fr); }
  .content-banner { min-height: 10rem; padding: 1.3rem; }
  .content-banner strong { font-size: 1.35rem; }
  .font-control button { min-width: 2.8rem; }
  .logo-text { font-size: 1.25rem; }
}
