@font-face {
    font-family: 'notosanskr-bold_0';
    src: url('webfont/notosanskr-bold_0.otf') format('opentype');
}
@font-face {
    font-family: 'notosanskr-regular_0';
    src: url('webfont/notosanskr-regular_0.otf') format('opentype');
}
@font-face {
    font-family: 'notoserifkr-light';
    src: url('webfont/notoserifkr-light.otf') format('opentype');
}

/* rem base setting */
html { font-size: 16px; }

:root {
  --font-hero-display: 4.17rem;
  --font-display1: 14.58rem;
  --font-display2: 8.33rem;
  --font-display3: 5.56rem;
  --font-h1: 2.22rem;
  --font-h2: 1.67rem;
  --font-h3: 1.39rem;
  --font-p1: 1.67rem;
  --font-p2: 1.25rem;
  --font-p3: 1rem;

  /* ── 새 컬러 팔레트 (밝은 아이보리 + 네이비 포인트) ── */
  --color-primary: #1e3a6f;          /* LIVE 버튼/포인트 네이비 */
  --color-primary-dark: #16294f;     /* 진한 네이비 (호버용) */
  --color-text-main: #2a2a2a;        /* 본문 진한 글자 */
  --color-text-sub: #6b6b6b;         /* 보조 회색 글자 */
  --color-text-light: #9a9a9a;       /* 더 옅은 회색 */
  --color-bg-base: #ffffff;          /* 메인 화이트 배경 */
  --color-bg-soft: #f7f5f0;          /* 부드러운 아이보리 */
  --color-bg-pastel: #e6ecf2;        /* 다음세대 파스텔 블루 */
  --color-navy-deep: #0d1b3e;        /* 갤러리용 다크 네이비 */
  --color-border-light: #e5e5e5;     /* 카드 테두리/구분선 */
  --color-border-trans: rgba(255, 255, 255, 0.3);

  --font-family: 'WantedSans', 'Apple SD Gothic Neo', sans-serif;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-family);
  background-color: #fff;
  color: var(--color-text-main);
}
body *{font-family: 'notosanskr-regular_0';}
.notosanskrBold{font-family: 'notosanskr-bold_0';}
.notosanskrLight{font-family: 'notoserifkr-light';}

a{text-decoration:none!important;color:inherit;}


.transition-base { transition: all 0.3s ease; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-1 { flex: 1; }
.ml-2-px { margin-left: 0.125rem; }
.ml-3-px { margin-left: 0.1875rem; }
.mr-32pct { margin-right: 32%; }

.slider .slider-dots .each-dot.active{background:#fff !important;}
.slider .move-btn{background: rgba(0, 0, 0, 0.3) !important;position: absolute;top: 50%;margin-top: -52px;cursor: pointer;padding: 30px 30px !important;border-radius: 50% !important;}
.slider .move-btn.prev-btn {left: 1% !important;}
.slider .move-btn.next-btn {right: 1% !important;}


/* ── 1. HEADER ── */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 6.22rem;
  background: transparent;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: none;
}

.header-container {
  max-width: 75rem;
  width: 100%;
  padding: 1.5rem 1.33rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: inset 0 -0.0625rem 0 var(--color-border-trans);
  height: 100%;
  box-sizing: border-box;
}

.header-logo-box { display: flex; align-items: center; gap: 0.55rem; }
.header-logo-sp { border: 0.0625rem solid white; font-size: 1rem; font-weight: 700; padding: 0.11rem 0.28rem; color: #fff; }
.header-logo-text { font-size: 1.39rem; font-weight: 700; color: #fff; }
.header-nav { display: flex; gap: 1.44rem; align-items: center; }
.header-nav-link { font-size: 1.25rem; color: rgba(255, 255, 255, 0.88); text-decoration: none; white-space: nowrap; }
.header-right-box { display: flex; align-items: center; gap: 0.88rem; }
.header-auth-text { font-size: 1rem; color: #fff; cursor: pointer; }
.header-menu-btn { cursor: pointer; color: #fff; }


/* ── 2. HERO ── */
.hero {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 51vw;
  min-height: 600px;
  overflow: hidden;
}

.hero-bg-container {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
}

.slider .slider-wrapper .slide p {
    margin: 0;
    height: 100% !important;
}
.hero-bg-container .bx-wrapper { height: 100% !important; margin: 0 !important; }
.hero-bg-container .bx-viewport { height: 100% !important; }
.hero-bg-container ul.slider,
.hero-bg-container ul.slider li.slide,
.hero-bg-container .slide a {
    height: 100% !important; width: 100% !important; display: block !important;
}
.hero-bg-container .slide img {
    width: 100% !important; height: 100% !important;
    object-fit: cover !important; object-position: center !important; display: block !important;
}
.hero-bg-container .bx-controls img,
.hero-bg-container .move-btn img {
    width: auto !important; height: auto !important; object-fit: none !important;
}

.hero-content {
  position: absolute;
  bottom: 8rem;
  left: 0; right: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  pointer-events: none;
}

.hero-bg-container .slider-dots,
.hero-bg-container .bx-wrapper .bx-pager {
    bottom: 5rem !important;
    z-index: 50 !important;
}

/* 아이콘 6개를 항상 한 줄로 유지 (줄바꿈으로 박스가 위로 튀는 현상 방지) */
.hero-icon-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: clamp(0.5rem, 1.1vw, 1.25rem);
  justify-items: center;
  max-width: 75rem; width: 100%;
  margin: 0 auto;
  padding: 0 1rem; box-sizing: border-box; pointer-events: auto;
}

.hero-icon-grid > a {
  display: block;
  width: 100%;
  min-width: 0; /* 그리드 칸이 내용물 때문에 안 줄어드는 것 방지 */
}

.hero-icon-box {
  width: 100%;
  max-width: 8.625rem;
  height: auto;
  aspect-ratio: 1 / 1;
  margin: 0 auto;
  padding: 0.5rem;
  box-sizing: border-box;
  background: #ffffff;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 0.4rem; cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s;
  box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.08);
}
.hero-icon-box:hover {
  transform: translateY(-0.5rem);
  box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.12);
}
.hero-icon-label {
  font-size: clamp(0.75rem, 1.05vw, 1rem);
  line-height: 1.25;
  text-align: center;
  word-break: keep-all;
  color: var(--color-text-main);
  font-weight: 600;
}
.hero-icon-svg {
  width: clamp(1.6rem, 2.6vw, 2.75rem);
  height: clamp(1.6rem, 2.6vw, 2.75rem);
  display: block;
}


/* ── 3. SERMON & COMMUNITY ── */
.section-sermon-community {
  background: var(--color-bg-soft);
  position: relative;
  z-index: 5;
  padding-top: 0;
  padding-bottom: 3rem;
}

.section-sermon-community__bg {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0;
  opacity: 1;
}

.sermon-container {
  max-width: 75rem; margin: 0 auto; padding: 0 1rem;
  display: flex; flex-direction: row; gap: 0; position: relative; z-index: 2;
}

.sermon-image-wrapper {
  width: 48%; flex-shrink: 0; margin-top: -3.75rem;
  position: relative; z-index: 20; overflow: visible;
}
.sermon-image {
  width: 100%; height: 21.25rem;
  object-fit: cover; object-position: center top; display: block;
  box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.1);
}

.sermon-play-btn {
  position: absolute; bottom: 5%; right: 8%;
  width: 4.0625rem; height: 4.0625rem; border-radius: 50%;
  background: #d65a3a;
  border: none;
  display: flex; align-items: center; justify-content: center; cursor: pointer;
  box-shadow: 0 0.25rem 0.75rem rgba(214, 90, 58, 0.4);
}

.sermon-info-wrapper {
  flex: 1; padding: 3rem 3rem;
  display: flex; flex-direction: column; justify-content: center;
}
.sermon-title { font-size: 2.5rem; font-weight: 700; color: var(--color-text-main); }
.sermon-subtitle {
  font-size: 1rem; color: var(--color-primary);
  margin-bottom: 2rem; font-weight: 600;
}

.sermon-btn-grid { display: flex; gap: 0.55rem; flex-wrap: wrap; }

.sermon-btn-live {
  width: 6.75rem; height: 6.75rem; border: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 0.375rem; cursor: pointer;
  background: var(--color-primary);
  transition: transform 0.3s, background 0.3s;
}
.sermon-btn-live:hover {
  transform: translateY(-0.375rem);
  background: var(--color-primary-dark);
}
.sermon-btn-live span { font-size: 1rem; color: #fff; font-weight: 600; }

.sermon-btn-worship {
  width: 6.75rem; height: 6.75rem;
  border: 0.0625rem solid var(--color-border-light);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 0.125rem; cursor: pointer;
  background: #ffffff;
  transition: transform 0.3s, border-color 0.3s;
}
.sermon-btn-worship:hover {
  transform: translateY(-0.375rem);
  border-color: var(--color-primary);
}
.sermon-btn-worship span {
  text-align: center; font-size: 1rem;
  color: var(--color-text-main); font-weight: 500;
}


/* ── 커뮤니티 컨테이너 & 그리드 ── */
.community-container {
  max-width: 75rem; margin: 0 auto;
  padding-top: 4rem;
  padding-bottom: 4rem;
  padding-left: 1rem;
  padding-right: 1rem;
  position: relative; z-index: 2;
}

.community-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.community-grid a {
    display: block;
    text-decoration: none;
}

.community-card {
  cursor: pointer; position: relative;
  transition: transform 0.3s;
}
.community-card:hover { transform: translateY(-0.25rem); }

.community-card-img-wrapper {
    overflow: hidden;
    margin-bottom: 0 !important;
}

.community-card-img-wrapper img,
.community-card-img {
    width: 100% !important;
    height: 15rem !important;
    object-fit: cover !important;
    display: block !important;
    transition: transform 0.3s;
    clip-path: polygon(0 0, 100% 0, 100% 100%, 70% 100%, 70% 78%, 0 78%) !important;
    -webkit-clip-path: polygon(0 0, 100% 0, 100% 100%, 70% 100%, 70% 78%, 0 78%) !important;
}

.community-card:hover .community-card-img-wrapper img,
.community-card:hover .community-card-img {
    transform: scale(1.03);
}

.community-card-label-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.44rem;
    margin-top: -2.5rem !important;
    position: relative;
    z-index: 5 !important;
}

.community-card-label {
    color: var(--color-primary);
    font-size: 1rem;
    letter-spacing: 0.06em;
    font-weight: 600;
}

.mr-32pct {
    margin-right: 32%;
}

.community-card-title {
    font-size: 1.39rem;
    font-weight: 700;
    color: var(--color-text-main);
    margin-bottom: 0.33rem;
}

.community-card-desc {
    font-size: 1rem;
    color: var(--color-text-sub);
}


/* ── 4. GALLERY ── */
.gallery {
  background: var(--color-navy-deep);
  padding-top: 6rem;
  padding-bottom: 6rem;
  overflow: hidden;
  position: relative;
}

.gallery-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; opacity: 1; }

.gallery-flex { display: flex; flex-direction: row; align-items: flex-start; max-width: 100%; position: relative; z-index: 2; }

.gallery-left {
  width: 34%; min-width: 18.75rem; flex-shrink: 0;
  padding-right: 3rem; padding-left: max(1.5rem, calc(50vw - 36rem));
  box-sizing: border-box; padding-top: 2rem;
}

.gallery-subtitle { color: #bbbbbb; font-size: 1rem; font-weight: 600; }
.gallery-title { font-size: 2.5rem; font-weight: 700; color: #fff; margin-bottom: 0.33rem; }
.gallery-desc { color: #bbbbbb; font-size: 1rem; margin-bottom: 1rem; }

.gallery-right { flex: 1; min-width: 0; overflow: hidden; padding-left: 1rem; box-sizing: border-box; }

.gallery-dots {
  display: flex; gap: 0.625rem; margin-bottom: 0.75rem; padding-left: 0.25rem;
  position: relative !important; bottom: auto !important; justify-content: flex-start !important;
}
.gallery-dot { width: 0.5rem; height: 0.5rem; border-radius: 50%; background: rgba(255, 255, 255, 0.35); transition: all 0.3s ease; cursor: pointer; display: block; }
.gallery-dot.is-active { width: 1.5rem; border-radius: 0.25rem; background: #fafafa; }

.gallery-carousel-viewport { overflow: visible; }

.gallery-item { width: 23.75rem !important; flex-shrink: 0; }
.gallery-img-wrapper { width: 23.75rem; flex-shrink: 0; overflow: hidden; cursor: pointer; }
.gallery-img { width: 100%; height: 16.25rem; object-fit: cover; display: block; transition: transform 0.3s; }
.gallery-img-wrapper:hover .gallery-img { transform: scale(1.06); }


/* ── 5. NEXT GENERATION (밝은 파스텔 톤) ── */
.nextgen {
  position: relative;
  overflow: hidden;
  background: var(--color-bg-pastel);
}

.nextgen-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

/* 오버레이 제거됨 */

.nextgen-content {
  position: relative;
  z-index: 2;
  padding: 6rem 1rem;
  text-align: center;
}

.nextgen-label {
  font-size: 1rem;
  letter-spacing: 0.24em;
  color: var(--color-primary);
  margin-bottom: 0.55rem;
  font-weight: 600;
}

.nextgen-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-text-main);
  margin-bottom: 1rem;
}

.nextgen-desc {
  font-size: 1.25rem;
  color: var(--color-text-sub);
  margin: 0 auto 3rem;
  line-height: 1.8;
}

.nextgen-btn-grid {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.nextgen-btn {
  width: 11rem;
  height: 11rem;
  border-radius: 50%;
  border: 0.125rem solid var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
  font-size: 1.25rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  background: transparent;
  text-decoration: none;
}

.nextgen-btn:hover {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: #fff;
  transform: translateY(-0.375rem);
}


/* ── SCROLL-TO-TOP ── */
.scroll-top-btn {
  position: fixed; bottom: 1.5rem; right: 1.5rem;
  width: 2.625rem; height: 2.625rem;
  background: var(--color-primary); border: none;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; z-index: 300; transition: background 0.2s;
}
.scroll-top-btn:hover { background: var(--color-primary-dark); }


/* ── RESPONSIVE ── */
@media (max-width: 1484px) {
  .hero-icon-grid { max-width: 56rem; }
  .hero-icon-box { max-width: 6.625rem; }
}

@media (max-width: 1024px) {
  .hero { min-height: 500px; height: 50vh; }
  .hero-content { bottom: 2rem; }
  .header { height: 6.22rem; }
  .header-nav { gap: 1rem; }
  .header-nav-link { font-size: 0.875rem; }
  /* 6칸 한 줄 유지 — 박스만 축소 */
  .hero-icon-box { max-width: 6.25rem; }
  .hero-icon-svg { width: 2rem; height: 2rem; }
  .sermon-container { flex-direction: column; padding: 3rem 1.25rem 0; }
  .sermon-image-wrapper { width: 100%; margin-top: 0; }
  .sermon-image { height: 17.5rem; }
  .sermon-info-wrapper { padding: 2rem; }
  .sermon-title { font-size: 2rem; }
  .community-grid { grid-template-columns: repeat(2, 1fr); }
  .nextgen-title { font-size: 2rem; }
  .gallery-left { width: 30%; padding-left: 1rem; }
}

/* 2줄로 접히면 히어로를 덮어버리므로 이 구간까지는 계속 한 줄 유지 */
@media (max-width: 768px) {
  .hero-icon-grid { gap: 0.5rem; padding: 0 0.75rem; }
  .hero-icon-box { max-width: 5.5rem; padding: 0.375rem; gap: 0.25rem; }
  .hero-icon-svg { width: 1.625rem; height: 1.625rem; }
  .hero-icon-label { font-size: 0.75rem; line-height: 1.2; }
  .community-grid { grid-template-columns: 1fr; }
  .nextgen-btn-grid { gap: 1.25rem; }
  .nextgen-btn { width: 7rem; height: 7rem; font-size: 1.1rem; }
}

/* 모바일: 여기서부터만 3 x 2 배치 */
@media (max-width: 576px) {
  .slider .move-btn { padding: 15px 15px !important; border-radius: 50% !important; }
  .hero { min-height: 620px; height: 75vh; }
  .hero-content { bottom: 3.5rem; }
  .header { height: 4.5rem; }
  .header-container { padding: 1rem; }
  .hero-bg-container .slider-dots,
  .hero-bg-container .bx-wrapper .bx-pager {
    bottom: 1.2rem !important;
    z-index: 50 !important;
  }
  .header-logo-sp { font-size: 0.875rem; }
  .header-logo-text { font-size: 1.25rem; }
  .logo-wrap { width: 165px; padding: 10px; }
  .hero-icon-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.6rem; padding: 0 1rem; }
  .hero-icon-box { max-width: 6.5rem; padding: 0.5rem; gap: 0.35rem; }
  .hero-icon-svg { width: 1.75rem; height: 1.75rem; }
  .hero-icon-label { font-size: 0.8rem; }
  .sermon-image { height: 13.75rem; }
  .sermon-play-btn { width: 3.125rem; height: 3.125rem; }
  .sermon-info-wrapper { padding: 2rem 0; }
  .sermon-title { font-size: 1.75rem; }
  .sermon-subtitle { font-size: 1.25rem; margin-bottom: 1rem; }
  .sermon-btn-live,
  .sermon-btn-worship { width: 5rem; height: 5rem; }
  .sermon-btn-live span,
  .sermon-btn-worship span { font-size: 0.875rem; }
  .community-container { padding: 3rem 1.25rem; }
  .community-grid { gap: 1.5rem; }
  .nextgen-content { padding: 3rem 1rem; }
  .nextgen-title { font-size: 1.75rem; }
  .nextgen-desc { font-size: 1rem; margin-bottom: 1.5rem; }
  .nextgen-btn-grid { gap: 1rem; }
  .nextgen-btn { width: 9.25rem; height: 9.25rem; font-size: 1.2rem; }
  .gallery { padding-top: 3rem; padding-bottom: 3rem; }
  .gallery-flex { flex-direction: column; }
  .gallery-left { width: 100%; padding-left: 1.25rem; padding-right: 0; padding-top: 0; padding-bottom: 2rem; }
  .gallery-subtitle { font-size: 1rem; }
  .gallery-title { font-size: 1.75rem; }
  .gallery-right { width: 100%; padding-left: 1.25rem; }
  .gallery-dots { padding-left: 1rem; }
  .gallery-carousel-viewport { padding-left: 1rem; }
}
