/* ymw.jibsurimission.com — 야자매트시공(임팩트) 디자인 시스템
   참고(레퍼런스, 색상/폰트/여백 메커니즘만 참고 — 레이아웃/섹션순서는 미복제):
   msr.standardhomerepair.com 실측값 — Pretendard 가변폰트, 무각(radius 0) 카드, 2/3/4열 그리드, gap 8/10/20px
   팔레트는 실제 촬영된 야자매트(코이어 로프) 색상에서 파생한 자체 톤(황토빛 브라운 + 짙은 흙색) */
@font-face {
  font-family: 'Pretendard';
  src: url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable.css');
}
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable.css');

:root {
  --soil: #1c1712;       /* 짙은 흙색 — 프라이머리 다크 */
  --coir: #b9793a;       /* 야자매트 코이어 로프 황토색 — 포인트 */
  --coir-deep: #8f5c26;  /* 코이어 다크 톤 (hover 등) */
  --cream: #f6f1e7;      /* 밝은 배경 (모래빛 크림) */
  --paper: #fffdf9;      /* 카드 배경 */
  --border: #ddd2bd;     /* 보더 */
  --text-on-light: #211a12;
  --text-sub-on-light: #5c5245;
  --text-on-dark: #f6f1e7;
  --text-sub-on-dark: #cbbfa9;
  --radius: 3px;
  --max: 1180px;
  --ff: 'Pretendard', 'Noto Sans KR', sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body, p, h1, h2, h3, h4, h5, h6, li, td, th, a, span, div, button {
  word-break: keep-all;
  overflow-wrap: break-word;
}
body {
  margin: 0;
  font-family: var(--ff);
  color: var(--text-on-light);
  background: var(--cream);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }
section { padding: 88px 0; overflow-x: hidden; }
h1, h2, h3 { line-height: 1.3; margin: 0 0 16px; }
h1 { font-size: clamp(32px, 5vw, 52px); font-weight: 900; letter-spacing: -.01em; position: relative; display: inline-block; padding-bottom: 14px; }
h1::after { content: ''; position: absolute; left: 0; bottom: 0; width: 56px; height: 4px; background: var(--coir); border-radius: 2px; }
h2 { font-size: clamp(26px, 3.6vw, 36px); font-weight: 800; }
h3 { font-size: 20px; font-weight: 700; }
p { margin: 0 0 14px; }

/* ---------- 헤더 / 네비 ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--soil);
  box-shadow: 0 2px 14px rgba(0,0,0,.18);
}
.site-header.is-scrolled {
  box-shadow: 0 2px 14px rgba(0,0,0,.3);
}
.hdr-inner { display: flex; align-items: center; justify-content: space-between; padding: 18px 24px; max-width: var(--max); margin: 0 auto; }
.hdr-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text-on-dark); }
.hdr-logo { flex-shrink: 0; border-radius: var(--radius); }
.hdr-brand-text { display: flex; flex-direction: column; gap: 2px; }
.hdr-brand strong { font-size: 20px; font-weight: 800; letter-spacing: .02em; }
.hdr-brand small { font-variant: small-caps; letter-spacing: .12em; font-size: 11px; color: var(--coir); text-transform: uppercase; }
.hdr-nav { display: flex; align-items: center; gap: 28px; }
.hdr-nav a { color: var(--text-on-dark); text-decoration: none; font-size: 15px; font-weight: 500; }
.hdr-cta {
  background: var(--coir); color: var(--soil); font-weight: 700; padding: 11px 22px;
  border-radius: var(--radius); text-decoration: none; font-size: 15px;
}
.hdr-burger { display: none; }
#mob-nav { display: none; }

@media (hover: hover) and (pointer: fine) {
  .hdr-cta:hover { background: var(--coir-deep); }
  .btn:hover { filter: brightness(1.08); }
  .card:hover { border-color: var(--coir); }
  .link-card:hover img { transform: scale(1.04); }
  .footer-cats a:hover, .footer-links a:hover { color: var(--coir); }
}

@media (max-width: 768px) {
  .hdr-nav > a { display: none; }
  .hdr-burger {
    display: block; background: none; border: none; color: var(--text-on-dark);
    font-size: 26px; cursor: pointer; line-height: 1;
  }
  #mob-nav {
    display: block; position: fixed; inset: 0 0 0 30%; background: var(--soil);
    transform: translateX(100%); transition: transform .3s ease; z-index: 60;
    padding: 90px 28px; display: flex; flex-direction: column; gap: 22px;
  }
  #mob-nav.is-open { transform: translateX(0); }
  #mob-nav a { color: var(--text-on-dark); text-decoration: none; font-size: 18px; font-weight: 600; }
  body { padding-bottom: 64px; }
}

/* ---------- 버튼 ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 15px 28px; border-radius: var(--radius); font-weight: 700; font-size: 16px; text-decoration: none; border: none; cursor: pointer; }
.btn-primary { background: var(--coir); color: var(--soil); }
.btn-outline { background: transparent; color: var(--text-on-dark); border: 1.5px solid var(--coir); }
.btn-dark { background: var(--soil); color: var(--text-on-dark); }

/* ---------- 히어로 ---------- */
.hero { position: relative; min-height: 92vh; display: flex; align-items: flex-end; overflow: hidden; }
.hero--short { min-height: 70vh; }
.hero-slides { position: absolute; inset: 0; z-index: 0; }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.4s ease; }
.hero-slide.is-active { opacity: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; }
@keyframes hero-drift { from { transform: scale(1.02) translateY(0); } to { transform: scale(1.08) translateY(-10px); } }
.hero-slide.is-active img { animation: hero-drift 9s ease-in-out infinite alternate; }
.hero-body { position: relative; z-index: 2; width: 100%; padding: 0 24px 72px; max-width: var(--max); margin: 0 auto; }
.hero-shade { position: absolute; left: 0; right: 0; bottom: 0; height: 260px; z-index: 1; background: linear-gradient(180deg, transparent, rgba(15,11,7,.82)); }
.hero-badge { display: block; width: fit-content; background: var(--paper); color: var(--coir-deep); font-weight: 700; font-size: 13px; padding: 7px 14px; border-radius: var(--radius); margin-bottom: 4px; }
.hero h1 { color: #fff; }
.hero-sub { color: #efe6d6; font-size: 18px; max-width: 640px; }
.hero-cta-row { display: flex; gap: 14px; margin-top: 26px; flex-wrap: wrap; }
.hero-dots { position: absolute; right: 24px; bottom: 28px; z-index: 2; display: flex; gap: 8px; }
.hero-dots span { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,.4); }
.hero-dots span.is-active { background: var(--coir); }

/* 모바일: 이미지-텍스트 겹침 방지 — 이미지 블록 위, 텍스트 블록 아래로 완전 분리 */
@media (max-width: 768px) {
  .hero { display: block; min-height: 0; padding: 0; }
  .hero-slides { position: relative; height: 50vw; min-height: 240px; max-height: 340px; }
  .hero-shade { display: none; }
  .hero-dots { display: none; }
  .hero-body { position: relative; background: var(--soil); padding: 28px 20px 34px; max-width: none; }
}

/* ---------- 그리드 ---------- */
.dp-g2 { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.dp-g3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.dp-stat3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; text-align: center; }
@media (max-width: 768px) { .dp-g2, .dp-g3 { grid-template-columns: 1fr; } }
@media (max-width: 600px) { .dp-stat3 { grid-template-columns: 1fr; gap: 16px; } }

/* ---------- 카드 ---------- */
.card { background: var(--paper); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; transition: border-color .2s ease; }
.card-badges { display: flex; flex-wrap: wrap; gap: 8px; }
@media (max-width: 768px) { .card-badges { flex-direction: column; align-items: flex-start; gap: 6px; } }
.badge { display: inline-block; background: var(--cream); border: 1px solid var(--border); color: var(--text-sub-on-light); font-size: 13px; padding: 5px 12px; border-radius: var(--radius); }

/* ---------- 내부링크 카드(썸네일) ---------- */
.link-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 900px) { .link-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .link-grid { grid-template-columns: 1fr; } }
.link-card { display: block; text-decoration: none; color: var(--text-on-light); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--paper); }
.link-card figure { margin: 0; overflow: hidden; aspect-ratio: 4 / 3; }
.link-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.link-card figcaption { padding: 16px 18px; }
.link-card figcaption strong { display: block; font-size: 16px; margin-bottom: 4px; color: var(--text-on-light); }
.link-card figcaption span { font-size: 13px; color: var(--text-sub-on-light); }
.link-card.is-contact { background: var(--soil); color: var(--text-on-dark); display: flex; align-items: center; justify-content: center; text-align: center; padding: 36px 20px; }
.link-card.is-contact strong { color: var(--coir); font-size: 19px; }

/* ---------- Before / After ---------- */
.ba-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; border-radius: var(--radius); overflow: hidden; }
@media (max-width: 640px) { .ba-wrap { grid-template-columns: 1fr; } }
.ba-item { position: relative; }
.ba-item img { aspect-ratio: 4/3; object-fit: cover; }
.ba-tag { position: absolute; top: 14px; left: 14px; background: var(--soil); color: var(--coir); font-size: 13px; font-weight: 800; padding: 6px 14px; border-radius: var(--radius); letter-spacing: .04em; }

/* ---------- 프로세스 ---------- */
.proc-list { display: flex; list-style: none; margin: 0; padding: 0; }
.proc-step { flex: 1; position: relative; padding: 0 12px; text-align: center; opacity: 0; transform: translateY(16px); transition: opacity .5s ease, transform .5s ease; }
.proc-step.is-visible { opacity: 1; transform: translateY(0); }
.proc-step:not(:last-child)::after { content: ''; position: absolute; top: 24px; left: 50%; width: 100%; height: 2px; background: var(--border); z-index: 0; }
.proc-num { position: relative; z-index: 1; margin: 0 auto 14px; width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--soil); color: var(--coir); font-weight: 800; }
.proc-step p { font-size: 14px; color: var(--text-sub-on-light); }
.proc-step h3 { font-size: 16px; }
@media (max-width: 768px) {
  .proc-list { flex-direction: column; gap: 10px; }
  .proc-step { padding: 24px 0; }
  .proc-step::after { display: none; }
}

/* ---------- FAQ ---------- */
.faq-list { margin-top: 8px; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-q { width: 100%; text-align: left; background: none; border: none; padding: 22px 0; font-size: 17px; font-weight: 700; cursor: pointer; display: flex; justify-content: space-between; gap: 16px; color: var(--text-on-light); }
.faq-q::after { content: '+'; color: var(--coir); font-size: 22px; flex-shrink: 0; }
.faq-item.is-open .faq-q::after { content: '−'; }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .3s ease; font-size: 15px; color: var(--text-sub-on-light); }
.faq-item.is-open .faq-a { max-height: 400px; }
.faq-a p { padding-bottom: 20px; }

/* ---------- 섹션 톤 ---------- */
.tone-dark { background: var(--soil); color: var(--text-on-dark); }
.tone-dark h2, .tone-dark h3 { color: #fff; }
.tone-dark p { color: var(--text-sub-on-dark); }
.tone-dark .card { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.15); }
.eyebrow { color: var(--coir-deep); font-weight: 700; font-size: 13px; letter-spacing: .08em; margin-bottom: 10px; display: block; }
.tone-dark .eyebrow { color: var(--coir); }

/* ---------- CTA 밴드 ---------- */
.cta-band { background: linear-gradient(120deg, var(--soil), #2a2016); color: #fff; border-radius: var(--radius); padding: 56px 44px; text-align: center; }
.cta-band h2 { color: #fff; }
.cta-band p { color: var(--text-sub-on-dark); }

/* ---------- 표(table) ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; min-width: 480px; }
th, td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--border); font-size: 15px; }
th { background: var(--cream); font-weight: 700; }
@media (max-width: 640px) {
  table { min-width: 0; }
  th, td { padding: 10px 8px; font-size: 13px; }
}

/* ---------- 푸터 ---------- */
.site-footer { background: var(--soil); color: var(--text-sub-on-dark); padding: 60px 0 28px; }
.footer-block { padding: 22px 0; border-bottom: 1px solid rgba(255,255,255,.12); }
.footer-label { display: block; font-size: 12px; font-weight: 700; letter-spacing: .06em; color: var(--coir); text-transform: uppercase; margin-bottom: 14px; }
.footer-cats { display: flex; flex-wrap: wrap; gap: 10px 28px; }
.footer-cats a { color: var(--text-on-dark); text-decoration: none; font-size: 14px; }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: var(--text-on-dark); text-decoration: none; font-size: 14px; }
.footer-biz { font-size: 13px; line-height: 1.9; border-top: 1px solid rgba(255,255,255,.12); padding-top: 22px; }
.footer-biz strong { color: var(--text-on-dark); }

/* ---------- 모바일 스티키 CTA ---------- */
#mob-bar { display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 55; background: var(--soil); padding: 10px 16px; box-shadow: 0 -4px 16px rgba(0,0,0,.3); }
#mob-bar a { display: block; text-align: center; background: var(--coir); color: var(--soil); font-weight: 800; padding: 13px; border-radius: var(--radius); text-decoration: none; }
@media (max-width: 768px) { #mob-bar { display: block; } }
#float-cta { position: fixed; right: 28px; bottom: 28px; z-index: 55; }
#float-cta a { display: inline-flex; align-items: center; gap: 8px; background: var(--coir); color: var(--soil); padding: 15px 22px; border-radius: var(--radius); text-decoration: none; font-weight: 800; box-shadow: 0 8px 22px rgba(0,0,0,.25); }
@media (max-width: 768px) { #float-cta { display: none; } }

/* ---------- 스크롤 리빌 (섹션마다 다른 방식 사용 — 동일 fade 반복 금지) ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

.reveal-wipe { position: relative; clip-path: inset(0 0 0 0); }
.reveal-wipe::after { content: ''; position: absolute; inset: 0; background: var(--cream); transform-origin: right; transform: scaleX(1); transition: transform .8s cubic-bezier(.65,0,.35,1); z-index: 3; }
.reveal-wipe.is-visible::after { transform: scaleX(0); }

.reveal-scale { opacity: 0; transform: scale(.94); transition: opacity .6s ease, transform .6s cubic-bezier(.34,1.56,.64,1); }
.reveal-scale.is-visible { opacity: 1; transform: scale(1); }

.stagger > * { opacity: 0; transform: translateY(20px); transition: opacity .5s ease, transform .5s ease; transition-delay: calc(var(--i, 0) * 100ms); }
.stagger.is-visible > * { opacity: 1; transform: translateY(0); }

/* ---------- 카운터 ---------- */
.counter { font-size: 40px; font-weight: 800; color: var(--coir-deep); }
.tone-dark .counter { color: var(--coir); }

@media (max-width: 768px) {
  section { padding: 56px 0; }
  .cta-band { padding: 40px 24px; }
}
