/*
  집수리팩토리 부엌인테리어 — DESIGN 02
  Primary #F03A47 / Accent #70D7FF / Background #FFF7F8 / Text #261418
*/
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.css');

:root {
  --font-body: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --color-primary: #f03a47;
  --color-primary-rgb: 240, 58, 71;
  --color-primary-text: #c22430; /* 본문/링크용 고대비 버전 */
  --color-accent: #70d7ff;
  --color-accent-rgb: 112, 215, 255;

  --color-text: #261418;
  --text-on-light: #261418;
  --text-on-light-muted: #6b5a5d;
  --text-on-dark: #fff7f8;
  --text-on-dark-muted: #cbb9bc;

  --color-bg: #fff7f8;
  --color-bg-alt: #fdeaec;
  --color-border: #f0d9dc;

  --radius: 0;
  --radius-lg: 0;
  --container-max: 1200px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text-on-light);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body, p, h1, h2, h3, h4, li, td, th, a, span { word-break: keep-all; overflow-wrap: break-word; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
:focus-visible { outline: 3px solid var(--color-primary); outline-offset: 2px; }

.container { max-width: var(--container-max); margin: 0 auto; padding: 0 24px; }
.section { padding: 72px 24px; }
.section-alt { background: var(--color-bg-alt); }
.section-dark { background: var(--color-text); color: var(--text-on-dark); }
.sec-eyebrow {
  display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 700; letter-spacing: 1.5px;
  text-transform: uppercase; color: var(--color-primary-text); margin: 0 0 10px;
}
.sec-eyebrow::before { content: ''; display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--color-primary); }
.section-dark .sec-eyebrow { color: var(--color-accent); }
.section-dark .sec-eyebrow::before { background: var(--color-accent); }
.sec-title { font-size: clamp(1.6rem, 2.8vw, 2.2rem); font-weight: 800; letter-spacing: -.3px; margin: 0 0 12px; }
.section-dark .sec-title { color: var(--text-on-dark); }
.sec-sub { font-size: .95rem; line-height: 1.7; color: var(--text-on-light-muted); margin: 0 0 40px; max-width: 640px; }
.section-dark .sec-sub { color: var(--text-on-dark-muted); }
p { font-size: .95rem; line-height: 1.8; }

.dp-g2 { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.dp-g3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.dp-g4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 900px) { .dp-g4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 768px) { .dp-g2, .dp-g3 { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .dp-g4 { grid-template-columns: 1fr; } }

/* 버튼 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 15px 30px; border-radius: var(--radius); font-weight: 700; font-size: 1rem;
  border: 1px solid transparent; transition: background .2s ease, color .2s ease, border-color .2s ease, transform .2s ease;
}
.btn-primary { background: var(--color-primary); color: #fff; }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .4); }
.btn-outline-dark { background: transparent; color: var(--color-primary-text); border-color: var(--color-border); }
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover { background: #d62731; transform: translateY(-1px); }
  .btn-outline-light:hover { border-color: var(--color-accent); color: var(--color-accent); }
  .btn-outline-dark:hover { border-color: var(--color-primary); color: var(--color-primary); }
  .card:hover { border-color: rgba(var(--color-primary-rgb), .45); transform: translateY(-4px); }
  .link-card:hover img { transform: scale(1.06); }
}
.btn:active { opacity: .85; }

/* 헤더 */
.hdr { position: sticky; top: 0; z-index: 50; height: 68px; background: var(--color-text); border-bottom: 1px solid rgba(var(--color-accent-rgb), .2); }
.hdr .container { height: 68px; display: flex; align-items: center; justify-content: space-between; }
.hdr-logo { font-size: 1.1rem; font-weight: 800; letter-spacing: -.3px; color: #fff; }
.hdr-logo span { color: var(--color-accent); }
.hdr-nav { display: flex; gap: 16px; }
.hdr-nav a { color: var(--text-on-dark-muted); font-weight: 600; font-size: .82rem; white-space: nowrap; }
@media (hover: hover) and (pointer: fine) { .hdr-nav a:hover { color: #fff; } }
.hdr-cta { background: var(--color-primary); color: #fff; font-weight: 700; font-size: .85rem; padding: 10px 20px; border-radius: var(--radius); white-space: nowrap; }
@media (hover: hover) and (pointer: fine) { .hdr-cta:hover { background: #d62731; } }
.hdr-burger { display: none; flex-direction: column; gap: 5px; width: 26px; background: none; border: none; cursor: pointer; padding: 0; }
.hdr-burger span { display: block; width: 100%; height: 2px; background: #fff; }
#mob-nav { position: fixed; top: 68px; left: 0; right: 0; background: var(--color-text); max-height: 0; overflow: hidden; transition: max-height .3s ease; z-index: 49; }
#mob-nav.open { max-height: 520px; overflow-y: auto; }
#mob-nav a { display: block; padding: 14px 24px; color: var(--text-on-dark-muted); font-weight: 600; font-size: .9rem; border-top: 1px solid rgba(255, 255, 255, .08); }
@media (max-width: 1180px) {
  .hdr-nav, .hdr-cta { display: none; }
  .hdr-burger { display: flex; }
  body { padding-bottom: 64px; }
}
@media (min-width: 1181px) { #mob-nav { display: none; } }

/* 히어로 */
.hero-h1 {
  font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 800; line-height: 1.25; letter-spacing: -1px;
  color: #fff; margin: 0 0 18px; max-width: 760px;
}
.mega-hero { background: var(--color-text); }
.hero-photo { width: 100%; height: clamp(380px, 60vw, 700px); overflow: hidden; background: var(--color-text); }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 42%; }
.hero-info { padding: 44px 24px 56px; }
.mega-hero-kicker {
  display: inline-flex; align-items: center; gap: 8px; font-size: .82rem; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--color-accent); margin: 0 0 18px;
}
.mega-hero-kicker::before { content: ''; width: 10px; height: 10px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.mega-hero-sub { color: var(--text-on-dark-muted); font-size: clamp(1rem, 1.6vw, 1.15rem); line-height: 1.8; max-width: 640px; margin: 0 0 30px; }
.mega-hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* 카드 */
.card { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 28px; transition: transform .25s ease, border-color .25s ease; }
.card-icon {
  width: 46px; height: 46px; border-radius: var(--radius); background: rgba(var(--color-primary-rgb), .12);
  color: var(--color-primary-text); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; margin-bottom: 18px; font-weight: 800;
}
.card h3 { font-size: 1.05rem; margin: 0 0 8px; }
.card p { font-size: .88rem; color: var(--text-on-light-muted); margin: 0; }
.section-dark .card { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .14); }
.section-dark .card-icon { background: rgba(var(--color-accent-rgb), .18); color: var(--color-accent); }
.section-dark .card h3 { color: #fff; }
.section-dark .card p { color: var(--text-on-dark-muted); }
.diag-card { display: flex; gap: 16px; align-items: flex-start; }
a.diag-card { text-decoration: none; }
.diag-card .diag-icon {
  flex-shrink: 0; width: 44px; height: 44px; border-radius: 50%; background: rgba(var(--color-primary-rgb), .12);
  color: var(--color-primary-text); display: flex; align-items: center; justify-content: center;
}
.diag-card .diag-icon svg { width: 22px; height: 22px; }

/* 링크카드(서비스/지역/썸네일) */
.link-card { border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--color-border); border-top: 4px solid var(--color-primary); background: #fff; }
.link-card figure { margin: 0; aspect-ratio: 3/4; overflow: hidden; background: var(--color-bg-alt); }
.link-card img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; transition: transform .4s ease; }
.link-card figcaption { padding: 16px 18px; }
.lc-cat { display: inline-block; font-size: .72rem; color: var(--color-primary-text); font-weight: 700; margin-bottom: 4px; }
.link-card figcaption h3 { font-size: .98rem; margin: 6px 0 4px; }
.link-card figcaption p { font-size: .82rem; color: var(--text-on-light-muted); margin: 0; }

/* 프로세스 */
.proc-list { display: flex; list-style: none; margin: 0; padding: 0; }
.proc-step { flex: 1; position: relative; padding: 0 12px; text-align: center; }
.proc-step:not(:last-child)::after { content: ''; position: absolute; top: 24px; left: 50%; width: 100%; height: 2px; background: var(--color-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(--color-primary); color: #fff; font-weight: 800;
}
.proc-step h4 { font-size: .94rem; margin: 0 0 6px; }
.proc-step p { font-size: .8rem; color: var(--text-on-light-muted); margin: 0; }
.section-dark .proc-step::after { background: rgba(255, 255, 255, .2); }
.section-dark .proc-step p { color: var(--text-on-dark-muted); }
@media (max-width: 768px) { .proc-list { flex-direction: column; gap: 10px; } .proc-step { padding: 20px 0; } .proc-step::after { display: none; } }

/* 시공 전후 */
.ba-wrap { display: grid; grid-template-columns: repeat(var(--ba-cols, 2), 1fr); gap: 20px; }
.ba-pair { border: 1px solid var(--color-border); border-radius: var(--radius-lg); overflow: hidden; background: #fff; }
.ba-pair-imgs { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; background: var(--color-border); }
.ba-item { position: relative; aspect-ratio: 3/4; overflow: hidden; }
.ba-item img { width: 100%; height: 100%; object-fit: cover; }
.ba-tag { position: absolute; top: 12px; left: 12px; padding: 5px 14px; border-radius: 999px; font-size: .78rem; font-weight: 700; color: #fff; background: rgba(38, 20, 24, .72); }
.ba-tag.after { background: rgba(240, 58, 71, .88); }
.ba-pair-caption { padding: 14px 16px; font-size: .88rem; font-weight: 700; }
@media (max-width: 900px) { .ba-wrap { grid-template-columns: 1fr; } }

/* 표 */
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--color-border); }
table { width: 100%; border-collapse: collapse; background: #fff; }
th, td { padding: 14px 16px; text-align: left; border-bottom: 1px solid var(--color-border); font-size: .88rem; }
th { background: var(--color-bg-alt); font-weight: 700; color: var(--color-primary-text); }
tbody tr:last-child td { border-bottom: none; }

/* 체크리스트 */
.check-list li { padding: 12px 0; border-bottom: 1px dashed var(--color-border); font-size: .92rem; padding-left: 28px; position: relative; }
.check-list li::before { content: '✓'; position: absolute; left: 0; color: var(--color-primary); font-weight: 700; }

/* FAQ (네이티브 details) */
.faq-list { max-width: 780px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--color-border); }
.faq-item summary {
  cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 20px 4px; font-weight: 700; font-size: .96rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; font-size: 1.3rem; color: var(--color-primary); transition: transform .25s ease; flex-shrink: 0; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-a { padding: 0 4px 20px; margin: 0; font-size: .89rem; color: var(--text-on-light-muted); }

/* 브레드크럼 */
.crumb { font-size: .8rem; color: var(--text-on-light-muted); margin-bottom: 18px; }
.crumb a { color: var(--color-primary-text); font-weight: 600; }
.section-dark .crumb { color: var(--text-on-dark-muted); }
.section-dark .crumb a { color: var(--color-accent); }

/* 세부/지역페이지 상단 다크 히어로 */
.case-hero { position: relative; background-size: cover; background-position: center; overflow: hidden; padding-top: 128px !important; }
.case-hero::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(38, 20, 24, .55) 0%, rgba(38, 20, 24, .88) 100%); }
.case-hero .container { position: relative; z-index: 1; }

/* CTA */
.mega-cta { display: grid; grid-template-columns: 1.4fr 1fr; min-height: 40vh; border-top: 4px solid var(--color-accent); }
.mega-cta-info { background: var(--color-text); color: #fff; padding: clamp(2.6rem, 6vw, 4.5rem) clamp(1.5rem, 4vw, 4rem); display: flex; flex-direction: column; justify-content: center; }
.mega-cta-info h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 800; line-height: 1.15; letter-spacing: -.02em; margin: 0 0 14px; }
.mega-cta-info p { color: var(--text-on-dark-muted); font-size: 1rem; margin: 0; max-width: 44ch; }
.mega-cta-phone { background: var(--color-primary); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 8px; padding: 2.6rem 1.5rem; transition: background .2s ease; }
.mega-cta-phone .label { font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; opacity: .9; }
.mega-cta-phone .number { font-size: clamp(1.5rem, 3.6vw, 2rem); font-weight: 800; letter-spacing: -.02em; }
@media (hover: hover) and (pointer: fine) { .mega-cta-phone:hover { background: #d62731; } }
@media (max-width: 768px) { .mega-cta { grid-template-columns: 1fr; min-height: auto; } }

/* 모바일 스티키 바 / 플로팅 CTA */
#mob-bar { display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: #fff; box-shadow: 0 -4px 16px rgba(0, 0, 0, .1); padding: 10px 14px; gap: 10px; }
#mob-bar a { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; text-align: center; padding: 12px; border-radius: var(--radius); font-weight: 700; font-size: .86rem; }
#mob-bar a.mb-call { background: var(--color-primary); color: #fff; }
@media (max-width: 1024px) { #mob-bar { display: flex; } }
#float-cta { position: fixed; right: 24px; bottom: 28px; z-index: 55; background: var(--color-primary); color: #fff; padding: 14px 24px; border-radius: var(--radius); font-weight: 700; font-size: .88rem; box-shadow: 0 8px 20px rgba(var(--color-primary-rgb), .4); }
@media (max-width: 1024px) { #float-cta { display: none; } }

/* 푸터 */
.ftr { background: var(--color-text); color: var(--text-on-dark-muted); padding: 60px 24px 28px; overflow-x: hidden; border-top: 1px solid rgba(var(--color-accent-rgb), .3); }
.ftr-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; }
.ftr h4 { color: var(--color-accent); font-size: .78rem; letter-spacing: 1.5px; text-transform: uppercase; margin: 0 0 16px; }
.ftr p { font-size: .84rem; line-height: 1.9; margin: 0 0 4px; }
.ftr a { font-size: .84rem; }
.ftr ul li { margin-bottom: 10px; }
@media (hover: hover) and (pointer: fine) { .ftr a:hover { color: var(--color-accent); } }
.ftr-bottom { max-width: var(--container-max); margin: 40px auto 0; padding-top: 24px; border-top: 1px solid rgba(255, 255, 255, .1); font-size: .74rem; text-align: center; color: #9a8b8d; }

/* 관련 링크(다른 서비스 더보기) */
.related-links { background: var(--color-bg-alt); border-top: 1px solid var(--color-border); padding: 56px 24px; }
.related-links-label { font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--color-primary-text); margin: 0 0 20px; text-align: center; }
.related-links figcaption { padding: 14px 16px; }
.related-links figcaption h3 { font-size: .92rem; margin: 0; }
@media (max-width: 768px) { .ftr-grid { grid-template-columns: 1fr; } }

/* 최종수정일 표기 */
.updated-note { text-align: center; font-size: .8rem; color: var(--text-on-light-muted); margin-top: -12px; }
.section-dark .updated-note { color: var(--text-on-dark-muted); }

/* 스크롤 리빌 */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s cubic-bezier(.16, 1, .3, 1), transform .6s cubic-bezier(.16, 1, .3, 1); }
.reveal.show { opacity: 1; transform: translateY(0); }
.stagger > * { opacity: 0; transform: translateY(22px) scale(.96); transition: opacity .5s cubic-bezier(.34, 1.15, .64, 1), transform .5s cubic-bezier(.34, 1.15, .64, 1); transition-delay: calc(var(--i, 0) * .09s); }
.stagger.show > * { opacity: 1; transform: translateY(0) scale(1); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
