/* 폰트 CSS 는 header.php 의 <link> 로 병렬 로드한다.
   여기서 @import 하면 style.css 를 다 받은 뒤에야 폰트를 받으러 가 렌더가 그만큼 늦어진다. */
:root {
  --green: #00A04A; --green-bright: #00C853; --green-bg: #F6FAF7;
  --green-soft: #E4F3E9; --ink: #12241A; --ink-soft: #5D7867;
  --blue: #0F4C9C; --white: #fff; --radius: 14px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: "NanumSquareRound", -apple-system, "Malgun Gothic", sans-serif;
  color: var(--ink); background: var(--white); line-height: 1.65; word-break: keep-all;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* 헤더 */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.92);
  backdrop-filter: blur(8px); border-bottom: 1px solid var(--green-soft); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 800; letter-spacing: 2px; }
.logo img { height: 26px; }
.nav { display: flex; gap: 22px; align-items: center; font-weight: 700; font-size: 15px; }
.nav a:hover { color: var(--green); }
.nav .btn { padding: 8px 18px; font-size: 14px; }
.nav-toggle { display: none; background: none; border: 0; font-size: 24px; cursor: pointer; }

/* 버튼 */
.btn { display: inline-block; background: var(--green); color: #fff; font-weight: 800;
  padding: 13px 28px; border-radius: 999px; border: 0; cursor: pointer; font-size: 16px;
  transition: transform .15s, box-shadow .15s; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0,160,74,.3); }
.btn-dark { background: var(--ink); color: var(--green-bright); }
.btn-outline { background: #fff; color: var(--green); border: 2px solid var(--green); }

/* 섹션 */
.section { padding: 88px 0; scroll-margin-top: 64px; }
.section-alt { background: var(--green-bg); }
.section-label { color: var(--green); font-weight: 800; letter-spacing: 3px; font-size: 13px;
  text-transform: uppercase; margin-bottom: 12px; }
.section h2 { font-size: clamp(26px, 4vw, 38px); font-weight: 800; line-height: 1.35; margin-bottom: 16px; }
.section .lead { color: var(--ink-soft); font-size: 17px; max-width: 640px; }

/* 히어로 — 풀스크린 영상 배경 */
.hero { position: relative; overflow: hidden; min-height: calc(100svh - 60px);
  display: flex; align-items: center; padding: 72px 0; background: #0a1810; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-overlay { position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(6,19,12,.76) 0%, rgba(6,19,12,.62) 45%, rgba(6,19,12,.84) 100%); }
.hero-content { position: relative; z-index: 1; text-align: center; }
.hero-badge { display: inline-block; background: rgba(255,255,255,.14); color: #fff; font-weight: 800;
  font-size: 14px; letter-spacing: 1px; padding: 8px 18px; border-radius: 999px;
  border: 1.5px solid rgba(255,255,255,.5); margin-bottom: 20px; backdrop-filter: blur(6px); }
.hero h1 { font-size: clamp(34px, 6vw, 62px); font-weight: 800; line-height: 1.3; color: #fff;
  text-shadow: 0 2px 24px rgba(0,0,0,.4); }
.hero h1 .accent { color: var(--green-bright); }
.hero .sub { color: #dcebe1; font-size: clamp(16px, 2.2vw, 19px); margin: 20px 0 30px;
  text-shadow: 0 1px 12px rgba(0,0,0,.4); }
.hero .store-badges { justify-content: center; }
.hero-proof { margin-top: 20px; font-size: 14px; font-weight: 700; color: #b9d2c2; }
.hero-float { position: absolute; font-size: 30px; opacity: .85; animation: heroFloat 5s ease-in-out infinite; pointer-events: none; }
.hero-float.f1 { top: 14%; right: 6%; animation-delay: 0s; }
.hero-float.f2 { bottom: 20%; right: 40%; animation-delay: 1.6s; font-size: 24px; }
.hero-float.f3 { top: 24%; left: 55%; animation-delay: 3.2s; font-size: 26px; }
@keyframes heroFloat {
  0%, 100% { transform: translateY(0) rotate(-4deg); }
  50% { transform: translateY(-14px) rotate(5deg); }
}
.btn-pulse { animation: btnPulse 2.4s ease-in-out infinite; }
@keyframes btnPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,160,74,.35); }
  55% { box-shadow: 0 0 0 12px rgba(0,160,74,0); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-float, .btn-pulse { animation: none; }
}
.store-badges { display: flex; gap: 12px; flex-wrap: wrap; }

/* 카드·그리드 */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 40px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 40px; }
.pull-quote { margin: 48px auto 0; max-width: 620px; text-align: center; font-size: clamp(18px, 2.6vw, 24px);
  font-weight: 800; line-height: 1.55; color: var(--ink); }
.pull-quote em { font-style: normal; color: var(--green); }
.card { background: #fff; border-radius: var(--radius); padding: 32px 26px;
  box-shadow: 0 4px 24px rgba(18,36,26,.06); }
.card .emoji { font-size: 38px; margin-bottom: 14px; }
.card h3 { font-size: 19px; margin-bottom: 8px; }
.card p { color: var(--ink-soft); font-size: 15px; }
.step-num { display: inline-block; background: var(--green); color: #fff; font-weight: 800;
  width: 28px; height: 28px; border-radius: 50%; text-align: center; line-height: 28px;
  font-size: 14px; margin-bottom: 12px; }

/* 사례 */
.case-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; margin-top: 40px; }
.case-card { border-radius: var(--radius); overflow: hidden; background: #fff;
  box-shadow: 0 4px 24px rgba(18,36,26,.08); }
.case-card img { width: 100%; height: 210px; object-fit: cover; }
.case-card .body { padding: 20px 22px; }
.case-card h3 { font-size: 18px; }
.case-card p { color: var(--ink-soft); font-size: 14px; margin-top: 6px; }

/* 사례 갤러리 팝업 */
.case-clickable { cursor: pointer; transition: transform .15s, box-shadow .15s; }
.case-clickable:hover { transform: translateY(-4px); box-shadow: 0 10px 32px rgba(18,36,26,.14); }
.case-more { display: inline-block; margin-top: 10px; color: var(--green); font-size: 13px; font-weight: 800; }
.case-modal { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; }
.case-modal[hidden] { display: none; }
.case-modal-backdrop { position: absolute; inset: 0; background: rgba(6,19,12,.82); }
.case-modal-box { position: relative; background: #fff; border-radius: var(--radius); max-width: 780px;
  width: calc(100% - 32px); max-height: 92vh; overflow-y: auto; padding: 20px 24px 28px; }
.cm-close { position: absolute; top: 12px; right: 14px; background: none; border: 0; font-size: 22px;
  cursor: pointer; color: var(--ink-soft); z-index: 2; }
.cm-stage { position: relative; margin-top: 14px; }
.cm-img { width: 100%; max-height: 56vh; object-fit: contain; border-radius: 10px; background: #0a1810; }
.cm-nav { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,.92);
  border: 0; width: 42px; height: 42px; border-radius: 50%; font-size: 24px; font-weight: 800;
  cursor: pointer; color: var(--ink); box-shadow: 0 2px 12px rgba(0,0,0,.25); }
.cm-prev { left: 10px; } .cm-next { right: 10px; }
.cm-nav[disabled] { opacity: 0; pointer-events: none; }
.cm-counter { text-align: center; font-size: 13px; color: var(--ink-soft); margin-top: 8px; font-weight: 700; }
.case-modal h3 { font-size: 20px; margin-top: 14px; }
.cm-desc { color: var(--ink-soft); font-size: 15px; margin-top: 8px; }

/* SNS — 유튜브·인스타 각각 한 줄씩 (임베드 높이가 달라 섞으면 그리드가 엉킴) */
.sns-sub { font-size: 15px; font-weight: 800; color: var(--ink-soft); letter-spacing: 1px;
  margin: 44px 0 16px; }
.sns-sub:first-of-type { margin-top: 40px; }
.sns-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px;
  align-items: start; }
.yt-embed { aspect-ratio: 16/9; border-radius: var(--radius); overflow: hidden; }
.yt-embed iframe { width: 100%; height: 100%; border: 0; }
.insta-row .instagram-media { margin: 0 !important; min-width: 0 !important; }

/* CTA 밴드 */
.cta-band { background: linear-gradient(150deg, #00B04F, #00953F); color: #fff; text-align: center; padding: 88px 0;
  scroll-margin-top: 64px; }
.cta-band h2 { font-size: clamp(26px, 4vw, 40px); font-weight: 800; margin-bottom: 24px; }

/* 푸터 */
.site-footer { background: var(--ink); color: #9DB3A5; padding: 48px 0 36px; font-size: 14px; }
.site-footer a:hover { color: var(--green-bright); }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; margin-bottom: 18px; font-weight: 700; }
.footer-sns { display: flex; gap: 14px; margin: 14px 0; flex-wrap: wrap; }
.footer-sns a { border: 1px solid #33513F; padding: 5px 14px; border-radius: 999px; font-size: 13px; }

/* 가이드 */
.faq-item { border-bottom: 1px solid var(--green-soft); padding: 26px 0; }
.faq-item h3 { font-size: 18px; color: var(--green); margin-bottom: 12px; }
.faq-item ul, .safety-list { list-style: none; }
.faq-item li, .safety-list li { position: relative; padding-left: 22px; margin-bottom: 8px; color: var(--ink-soft); font-size: 15px; }
.faq-item li::before, .safety-list li::before { content: "·"; position: absolute; left: 6px; color: var(--green); font-weight: 800; }
.safety-list { margin-top: 28px; }

/* 제휴 상점 */
.store-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; margin-top: 40px; }
.store-card { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: 0 4px 24px rgba(18,36,26,.07); }
.store-card img { width: 100%; height: 150px; object-fit: cover; }
.store-card .body { padding: 18px 20px; }
.store-card .cat { display: inline-block; background: var(--green-soft); color: var(--green); font-size: 12px;
  font-weight: 800; padding: 2px 10px; border-radius: 999px; margin-bottom: 8px; }
.store-card h3 { font-size: 17px; }
.store-card .addr { color: var(--ink-soft); font-size: 13px; margin-top: 4px; }
.store-card .benefit { color: var(--green); font-size: 14px; font-weight: 700; margin-top: 8px; }

/* 연혁 타임라인 */
.timeline { margin-top: 40px; display: grid; gap: 40px; }
.tl-year h3 { font-size: 26px; color: var(--green); margin-bottom: 18px; }
.tl-year ul { list-style: none; border-left: 3px solid var(--green-soft); padding-left: 0; }
.tl-year li { position: relative; padding: 0 0 16px 56px; color: var(--ink); font-size: 15px; }
.tl-year li::before { content: ""; position: absolute; left: -7px; top: 5px; width: 11px; height: 11px;
  border-radius: 50%; background: var(--green); border: 2.5px solid #fff; box-shadow: 0 0 0 2px var(--green-soft); }
.tl-m { position: absolute; left: 14px; top: 0; font-weight: 800; color: var(--ink-soft); font-size: 13px; }

/* 문의 폼 */
.contact-form { margin-top: 36px; background: #fff; border-radius: var(--radius); padding: 32px;
  box-shadow: 0 4px 24px rgba(18,36,26,.07); }
.contact-form label { display: block; font-size: 14px; font-weight: 800; margin: 16px 0 6px; }
.contact-form input[type=text], .contact-form select, .contact-form textarea {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--green-soft); border-radius: 10px;
  font-size: 15px; font-family: inherit; box-sizing: border-box; background: var(--green-bg); }
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus {
  outline: none; border-color: var(--green); background: #fff; }
.contact-form button { margin-top: 22px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-msg { margin-top: 24px; padding: 14px 18px; border-radius: 10px; font-weight: 700; }
.form-msg.ok { background: var(--green-soft); color: #00733a; }
.form-msg.err { background: #fdecea; color: #c0392b; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }

/* 제휴 상점 — 운영약관 페이지 */
.terms-meta { background: var(--green-bg); border-radius: var(--radius); padding: 18px 22px; margin-top: 32px;
  font-size: 14px; color: var(--ink-soft); line-height: 1.9; }
.terms-meta strong { color: var(--ink); margin-right: 6px; }
.terms-intro { margin-top: 24px; padding: 20px 22px; border: 1.5px solid var(--green-soft); border-radius: var(--radius); }
.terms-intro h3 { font-size: 15px; color: var(--green); margin-bottom: 10px; }
.terms-intro p { font-size: 14.5px; color: var(--ink-soft); line-height: 1.8; margin-bottom: 8px; }
.terms-intro strong { color: var(--ink); }
.terms-body { margin-top: 40px; }
.terms-body h3 { font-size: 18px; color: var(--ink); margin: 40px 0 14px; padding-left: 12px;
  border-left: 4px solid var(--green); }
.terms-body p { font-size: 15px; color: var(--ink-soft); line-height: 1.85; margin-bottom: 12px; }
.terms-table-wrap { overflow-x: auto; margin: 14px 0 18px; }
.terms-table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 460px; }
.terms-table th { background: var(--green); color: #fff; font-weight: 800; padding: 10px 12px; text-align: left; }
.terms-table td { border-bottom: 1px solid var(--green-soft); padding: 10px 12px; color: var(--ink-soft); vertical-align: top; }

/* 제휴 상점 — 참여신청 폼 */
.pf-notice { margin-top: 28px; background: var(--green-bg); border-radius: var(--radius); padding: 22px 24px; }
.pf-notice p { font-size: 14.5px; color: var(--ink-soft); line-height: 1.8; }
.pf-notice strong { color: var(--ink); }
.pf-beta { margin-top: 16px; background: #fffaf0; border: 1.5px solid #f0d9a8; border-radius: var(--radius); padding: 18px 22px; }
.pf-beta strong { display: block; font-size: 15px; color: #8a6420; margin-bottom: 8px; }
.pf-beta ul { list-style: none; }
.pf-beta li { position: relative; padding-left: 16px; margin-bottom: 8px; font-size: 14px; color: #6b5426; line-height: 1.75; }
.pf-beta li::before { content: "·"; position: absolute; left: 4px; font-weight: 800; }
.pf-beta li strong { display: inline; color: #8a6420; }
.partner-form { margin-top: 32px; }
.pf-section { background: #fff; border: 1px solid var(--green-soft); border-radius: var(--radius);
  padding: 26px 26px 22px; margin-bottom: 20px; }
.pf-section > h3 { font-size: 17px; margin-bottom: 6px; padding-left: 11px; border-left: 4px solid var(--green); }
.pf-desc { font-size: 13.5px; color: var(--ink-soft); line-height: 1.7; margin: 8px 0 4px; }
.pf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 18px; margin-top: 14px; }
.pf-item { grid-column: 1 / -1; margin-bottom: 12px; }
.pf-item.pf-half { grid-column: span 1; }
/* 표준값이 미리 채워진 섹션임을 알려 "내가 다 정해야 하나" 하는 부담을 없앤다 */
.pf-tpl-badge {
  display: inline-block; margin-left: 8px; padding: 2px 9px;
  font-size: 11.5px; font-weight: 700; letter-spacing: -0.01em;
  color: #00733a; background: #e6f5eb; border: 1px solid #bfe3cd; border-radius: 999px;
  vertical-align: middle;
}
.pf-checkall {
  display: flex; align-items: center; gap: 8px; margin-bottom: 12px;
  padding: 10px 12px; background: #f4faf6; border: 1px solid #cfe7d8; border-radius: 8px;
  font-weight: 700; font-size: 14px; cursor: pointer;
}
.pf-checkall input { width: 18px; height: 18px; }

/* 검증에 걸린 칸 — 목록만 보여주면 어느 칸인지 못 찾는다 */
.pf-item.pf-bad, .pf-agree.pf-bad {
  border-left: 4px solid #c0392b; background: #fff5f4;
  padding: 10px 12px; border-radius: 8px; scroll-margin-top: 90px;
}
.pf-item.pf-bad > label { color: #c0392b; }
.pf-item label { display: block; font-size: 13.5px; font-weight: 800; margin-bottom: 6px; }
.pf-req { color: #c0392b; }
.pf-item input[type=text], .pf-item input[type=tel], .pf-item input[type=email],
.pf-item input[type=date], .pf-item textarea {
  width: 100%; padding: 11px 13px; border: 1.5px solid var(--green-soft); border-radius: 10px;
  font-size: 15px; font-family: inherit; box-sizing: border-box; background: var(--green-bg); }
.pf-item input:focus, .pf-item textarea:focus { outline: none; border-color: var(--green); background: #fff; }
.pf-opts { display: flex; flex-wrap: wrap; gap: 8px 16px; padding: 4px 0; }
.pf-opt { display: inline-flex !important; align-items: center; gap: 7px; font-weight: 400 !important;
  font-size: 14.5px !important; margin-bottom: 0 !important; cursor: pointer; }
.pf-opt input { width: 17px; height: 17px; accent-color: var(--green); }
.pf-help { font-size: 12.5px; color: var(--ink-soft); line-height: 1.6; margin-top: 6px; }
.pf-agree { display: flex; align-items: flex-start; gap: 10px; padding: 9px 0; font-size: 14px;
  color: var(--ink-soft); line-height: 1.6; cursor: pointer; border-bottom: 1px solid var(--green-bg); }
.pf-agree input { margin-top: 3px; width: 18px; height: 18px; flex-shrink: 0; accent-color: var(--green); }
.pf-company { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 20px; margin-top: 12px; font-size: 14px; }
.pf-company > div { display: flex; gap: 10px; }
.pf-company span { color: var(--ink-soft); min-width: 68px; }
.sign-wrap { position: relative; margin-top: 14px; border: 2px dashed var(--green-soft); border-radius: var(--radius);
  background: var(--green-bg); overflow: hidden; }
#sign-pad { display: block; width: 100%; height: 190px; touch-action: none; cursor: crosshair; }
.sign-hint { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  color: #9db3a5; font-size: 15px; pointer-events: none; }
.sign-actions { display: flex; align-items: center; gap: 14px; margin-top: 10px; }
.sign-actions .pf-help { margin-top: 0; font-weight: 700; }
@media (max-width: 640px) {
  .pf-grid, .pf-company { grid-template-columns: 1fr; }
  .pf-item.pf-half { grid-column: 1 / -1; }
  .pf-section { padding: 20px 18px 16px; }
}

/* 뉴스 목록 */
.news-item { border-bottom: 1px solid var(--green-soft); padding: 22px 0; }
.news-item .meta { color: var(--ink-soft); font-size: 13px; margin-bottom: 4px; }
.news-item h3 { font-size: 18px; }
.news-item .tag { display: inline-block; background: var(--green-soft); color: var(--green);
  font-size: 12px; font-weight: 800; padding: 2px 10px; border-radius: 999px; margin-right: 8px; }

/* 반응형 */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .nav { display: none; position: absolute; top: 60px; left: 0; right: 0; background: #fff;
    flex-direction: column; padding: 20px; border-bottom: 1px solid var(--green-soft); }
  .nav.open { display: flex; }
  .nav-toggle { display: block; }
  .section { padding: 64px 0; }
}

/* 전용 로고 이미지가 없는 사이트(xnpc.kr)의 텍스트 로고.
   이미지가 준비되면 config/sites.php 의 logo 에 경로만 넣으면 이 스타일은 안 쓰인다. */
.logo-text {
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: #12241A;
  white-space: nowrap;
}

/* 반대편 사이트로 건너가는 네비 링크. 다른 도메인으로 나간다는 걸 눈으로 알리려고
   구분선을 두고 색을 낮춘다. 같은 사이트 안의 메뉴처럼 보이면 방문자가 혼란스럽다. */
.nav-cross {
  opacity: .72;
  border-left: 1px solid rgba(0,0,0,.15);
  padding-left: 14px;
  margin-left: 4px;
}
.nav-cross:hover { opacity: 1; }
@media (max-width: 768px) {
  .nav-cross { border-left: 0; padding-left: 0; margin-left: 0; }
}

/* 소셜미션의 수치 강조. 숫자를 먼저 읽히게 한다. */
.stat { text-align: center; padding: 20px 12px; }
.stat strong { display: block; font-size: 34px; font-weight: 800; color: #00C853; line-height: 1.1; }
.stat span { display: block; margin-top: 10px; font-size: 14px; color: #5A6B60; word-break: keep-all; }

/* 부연 설명. 본문보다 한 단계 낮은 목소리. */
.muted { color: #5A6B60; font-size: 14px; }

/* 협력 기관 목록. 로고 없이 기관명만 싣는 동안 쓰는 형태다. */
.partner-list { list-style: none; padding: 0; margin: 0; }
.partner-list li {
  padding: 16px 18px;
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 10px;
  margin-bottom: 10px;
  font-weight: 700;
}
