/*
Theme Name: Jibsuri Doorframe
Description: 집수리팩토리 문틀 복원 전문 사이트 - Fresh Frame Studio
Author: Jibsuri Factory
Version: 1.0
Text Domain: jibsuri-doorframe
*/

/* ===== Design tokens ===== */
:root {
  --mint: #22C7B8;
  --aqua: #DDF9F5;
  --sky: #DFF5FF;
  --coral: #FF766B;
  --lime: #CFF45A;
  --lemon: #FFE766;
  --lavender: #EAE5FF;
  --gray-light: #F4F7F8;
  --white: #FFFFFF;
  --ink: #263338;
  --radius-md: 20px;
  --radius-lg: 32px;
  --shadow-soft: 0 10px 30px rgba(38, 51, 56, 0.08);
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Malgun Gothic', sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
ul { list-style: none; margin: 0; padding: 0; }

.jdf-container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.jdf-section { padding: 72px 0; }
.jdf-section--aqua { background: var(--aqua); }
.jdf-section--sky { background: var(--sky); }
.jdf-section--lavender { background: var(--lavender); }
.jdf-section--gray { background: var(--gray-light); }

.jdf-eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--mint);
  background: rgba(34, 199, 184, 0.12);
  border-radius: 999px;
  padding: 6px 16px;
  margin-bottom: 16px;
}

.jdf-title {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  line-height: 1.35;
  margin: 0 0 16px;
  letter-spacing: -0.01em;
}

.jdf-lede {
  font-size: 17px;
  color: #4b5a60;
  max-width: 640px;
  margin: 0 0 40px;
}

.jdf-reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.jdf-reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ===== Buttons ===== */
.jdf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 15px;
  border: none;
  transition: transform .15s ease, box-shadow .15s ease;
}
.jdf-btn:hover { transform: translateY(-2px); }
.jdf-btn--lime { background: var(--lime); color: var(--ink); }
.jdf-btn--mint { background: var(--mint); color: var(--white); }
.jdf-btn--coral { background: var(--coral); color: var(--white); }
.jdf-btn--outline { background: transparent; color: var(--ink); border: 2px solid var(--ink); }
.jdf-btn--white { background: var(--white); color: var(--ink); box-shadow: var(--shadow-soft); }

/* ===== Header ===== */
.jdf-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(38,51,56,0.06);
}
.jdf-header-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.jdf-logo { font-size: 20px; font-weight: 800; color: var(--ink); }
.jdf-logo span { color: var(--mint); }
.jdf-nav-desktop { display: flex; align-items: center; gap: 32px; }
.jdf-nav-desktop ul { display: flex; gap: 28px; font-weight: 600; font-size: 15px; }
.jdf-nav-desktop a:hover { color: var(--mint); }
.jdf-header-cta { margin-left: 8px; }
.jdf-menu-toggle {
  display: none;
  width: 44px; height: 44px;
  border: none; background: var(--gray-light);
  border-radius: 12px;
  position: relative;
}
.jdf-menu-toggle span, .jdf-menu-toggle::before, .jdf-menu-toggle::after {
  content: ''; position: absolute; left: 12px; right: 12px; height: 2px; background: var(--ink);
}
.jdf-menu-toggle::before { top: 15px; }
.jdf-menu-toggle span { top: 21px; }
.jdf-menu-toggle::after { top: 27px; }

.jdf-mobile-nav {
  display: none;
  position: fixed; inset: 0 0 0 auto; width: min(320px, 86vw);
  background: var(--white); z-index: 200;
  transform: translateX(100%); transition: transform .25s ease;
  box-shadow: -20px 0 40px rgba(0,0,0,0.08);
  padding: 24px;
}
.jdf-mobile-nav.is-open { display: block; transform: translateX(0); }
.jdf-mobile-nav ul { display: flex; flex-direction: column; gap: 20px; font-weight: 700; font-size: 17px; margin-top: 48px; }

.jdf-mobile-bar {
  display: none;
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 150;
  background: var(--white);
  border-top: 1px solid rgba(38,51,56,0.08);
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  gap: 10px;
}
.jdf-mobile-bar a {
  flex: 1;
  text-align: center;
  padding: 13px 10px;
  border-radius: 14px;
  font-weight: 700;
  font-size: 14px;
}
.jdf-mobile-bar .call { background: var(--gray-light); color: var(--ink); }
.jdf-mobile-bar .photo { background: var(--lime); color: var(--ink); }

@media (max-width: 880px) {
  .jdf-nav-desktop { display: none; }
  .jdf-menu-toggle { display: block; }
  .jdf-mobile-bar { display: flex; }
  body { padding-bottom: 78px; }
}

/* ===== Hero: editorial damage-type cards ===== */
.jdf-hero { padding: 56px 0 80px; }
.jdf-hero-head { max-width: 680px; margin: 0 auto 40px; text-align: center; }
.jdf-hero-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(2, minmax(160px, auto));
  gap: 18px;
}
.jdf-hero-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--gray-light);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  box-shadow: var(--shadow-soft);
  transition: transform .2s ease;
}
.jdf-hero-card:hover { transform: translateY(-4px); }
.jdf-hero-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; transition: transform .3s ease; }
.jdf-hero-card:hover img { transform: scale(1.05); }
.jdf-hero-card-label {
  position: relative; z-index: 1;
  padding: 18px;
  color: var(--white);
  font-weight: 700;
  background: linear-gradient(0deg, rgba(0,0,0,0.55), transparent);
}
.jdf-hero-card--main { grid-column: span 2; grid-row: span 2; min-height: 420px; }
.jdf-hero-card--mid { grid-column: span 2; grid-row: span 1; min-height: 200px; }
.jdf-hero-card--small { grid-column: span 1; grid-row: span 1; min-height: 200px; }
.jdf-hero-card--arch { border-radius: 200px 200px var(--radius-md) var(--radius-md); }

.jdf-hero-cta { display: flex; gap: 14px; justify-content: center; margin-top: 40px; flex-wrap: wrap; }

@media (max-width: 880px) {
  .jdf-hero-grid { grid-template-columns: 1fr 1fr; grid-template-rows: none; }
  .jdf-hero-card--main { grid-column: span 2; min-height: 260px; }
  .jdf-hero-card--mid { grid-column: span 1; min-height: 180px; }
  .jdf-hero-card--small { grid-column: span 1; min-height: 160px; }
}

/* ===== Diagnosis selector ===== */
.jdf-diagnosis-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}
.jdf-diagnosis-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 0;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease;
  display: block;
}
.jdf-diagnosis-card:hover, .jdf-diagnosis-card.is-selected { transform: translateY(-6px); box-shadow: 0 16px 34px rgba(34,199,184,0.22); }
.jdf-diagnosis-card img { width: 100%; height: 140px; object-fit: cover; }
.jdf-diagnosis-card-body { padding: 16px; }
.jdf-diagnosis-card-q { font-weight: 700; font-size: 14.5px; margin-bottom: 8px; }
.jdf-diagnosis-card-a { font-size: 13.5px; color: var(--mint); font-weight: 700; }

@media (max-width: 880px) {
  .jdf-diagnosis-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ===== Damage encyclopedia (editorial) ===== */
.jdf-encyclopedia { display: flex; flex-direction: column; gap: 56px; }
.jdf-enc-item { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.jdf-enc-item:nth-child(even) { direction: rtl; }
.jdf-enc-item:nth-child(even) > * { direction: ltr; }
.jdf-enc-item:nth-child(3n) .jdf-enc-photo img { border-radius: 200px 200px var(--radius-md) var(--radius-md); }
.jdf-enc-photo img { border-radius: var(--radius-md); width: 100%; height: 320px; object-fit: cover; box-shadow: var(--shadow-soft); }
.jdf-enc-name { font-size: 22px; font-weight: 800; margin-bottom: 14px; }
.jdf-enc-row { display: flex; gap: 10px; margin-bottom: 10px; font-size: 15px; }
.jdf-enc-row b { flex: 0 0 auto; color: var(--mint); font-weight: 700; }

@media (max-width: 880px) {
  .jdf-enc-item { grid-template-columns: 1fr; }
  .jdf-enc-item:nth-child(even) { direction: ltr; }
  .jdf-enc-photo img { height: 220px; }
}

/* ===== Featured case studies ===== */
.jdf-case { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; margin-bottom: 64px; }
.jdf-case--reverse { grid-template-columns: 0.9fr 1.1fr; }
.jdf-case--reverse .jdf-case-media { order: 2; }
.jdf-case-media img { width: 100%; border-radius: var(--radius-lg); box-shadow: var(--shadow-soft); }
.jdf-case-mix { display: grid; grid-template-columns: 1.3fr 1fr; gap: 14px; }
.jdf-case-mix img:first-child { border-radius: 220px 220px var(--radius-lg) var(--radius-lg); height: 100%; object-fit: cover; }
.jdf-case-mix img:last-child { border-radius: var(--radius-md); }
.jdf-case-badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: 999px; margin-right: 8px; }
.jdf-case-badge--before { background: var(--coral); color: var(--white); }
.jdf-case-badge--after { background: var(--mint); color: var(--white); }
.jdf-case-title { font-size: 24px; font-weight: 800; margin: 12px 0 14px; }
.jdf-case-note { font-size: 13.5px; color: #5b6b70; margin-top: 16px; padding: 14px 16px; background: var(--gray-light); border-radius: 14px; }

@media (max-width: 880px) {
  .jdf-case, .jdf-case--reverse { grid-template-columns: 1fr; }
  .jdf-case--reverse .jdf-case-media { order: 0; }
  .jdf-case-mix { grid-template-columns: 1fr 1fr; }
}

/* ===== Naver search service cards (kept simple & crawlable) ===== */
.jdf-service-cards { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.jdf-service-card {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: transform .2s ease;
}
.jdf-service-card:hover { transform: translateY(-4px); }
.jdf-service-card img { width: 100%; height: 150px; object-fit: cover; }
.jdf-service-card span { display: block; padding: 14px; font-weight: 700; text-align: center; }

@media (max-width: 880px) {
  .jdf-service-cards { grid-template-columns: repeat(2, 1fr); }
}

/* ===== Additional case gallery (editorial masonry) ===== */
.jdf-gallery { display: grid; grid-template-columns: repeat(6, 1fr); grid-auto-rows: 90px; gap: 16px; }
.jdf-gallery-item { position: relative; border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-soft); }
.jdf-gallery-item img { width: 100%; height: 100%; object-fit: cover; }
.jdf-gallery-item-label {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 12px 14px;
  color: var(--white); font-weight: 700; font-size: 14px;
  background: linear-gradient(0deg, rgba(0,0,0,0.55), transparent);
}
.jdf-gallery-item--tall { grid-column: span 2; grid-row: span 4; }
.jdf-gallery-item--wide { grid-column: span 4; grid-row: span 3; }
.jdf-gallery-item--square { grid-column: span 2; grid-row: span 3; }
.jdf-gallery-item--arch { grid-column: span 2; grid-row: span 3; border-radius: 120px 120px var(--radius-md) var(--radius-md); }
.jdf-gallery-item--long { grid-column: span 2; grid-row: span 4; }

@media (max-width: 880px) {
  .jdf-gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 140px; }
  .jdf-gallery-item, .jdf-gallery-item--tall, .jdf-gallery-item--wide, .jdf-gallery-item--square, .jdf-gallery-item--arch, .jdf-gallery-item--long {
    grid-column: span 1; grid-row: span 2;
  }
}

/* ===== Process timeline ===== */
.jdf-timeline { max-width: 760px; margin: 0 auto; position: relative; }
.jdf-timeline::before {
  content: ''; position: absolute; left: 34px; top: 0; bottom: 0; width: 2px; background: rgba(34,199,184,0.25);
}
.jdf-timeline-step { position: relative; padding-left: 88px; margin-bottom: 48px; display: flex; gap: 24px; align-items: flex-start; }
.jdf-timeline-num {
  position: absolute; left: 0; top: 0; width: 68px; height: 68px; border-radius: 50%;
  background: var(--mint); color: var(--white); font-weight: 800; font-size: 20px;
  display: flex; align-items: center; justify-content: center;
}
.jdf-timeline-step:nth-child(2) .jdf-timeline-num { width: 56px; height: 56px; font-size: 17px; background: var(--coral); }
.jdf-timeline-step:nth-child(3) .jdf-timeline-num { background: var(--lemon); color: var(--ink); }
.jdf-timeline-step:nth-child(4) .jdf-timeline-num { width: 60px; height: 60px; font-size: 18px; }
.jdf-timeline-body h3 { font-size: 19px; font-weight: 800; margin: 0 0 8px; }
.jdf-timeline-body p { margin: 0 0 14px; color: #4b5a60; font-size: 15px; }
.jdf-timeline-body img { border-radius: var(--radius-md); width: 100%; max-width: 260px; }
.jdf-timeline-step:nth-child(3) .jdf-timeline-body img { max-width: 340px; }

@media (max-width: 640px) {
  .jdf-timeline::before { left: 26px; }
  .jdf-timeline-step { padding-left: 66px; }
  .jdf-timeline-num { width: 52px !important; height: 52px !important; font-size: 16px !important; }
}

/* ===== Photo consult guide ===== */
.jdf-phototips-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.jdf-phone-card {
  background: var(--white);
  border-radius: 34px;
  padding: 14px;
  box-shadow: var(--shadow-soft);
  border: 6px solid var(--ink);
}
.jdf-phone-card img { border-radius: 22px; height: 260px; width: 100%; object-fit: cover; }
.jdf-phone-card-cap { padding: 14px 6px 4px; font-weight: 700; font-size: 15px; }
.jdf-phototips-note {
  margin-top: 32px; background: var(--sky); border-radius: var(--radius-md); padding: 24px 28px; font-size: 14.5px;
}
.jdf-phototips-note ul { list-style: disc; padding-left: 20px; margin-top: 10px; }
.jdf-phototips-note li { margin-bottom: 6px; }

@media (max-width: 880px) {
  .jdf-phototips-grid { grid-template-columns: 1fr; }
}

/* ===== About ===== */
.jdf-about { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.jdf-about img { border-radius: var(--radius-lg); width: 100%; box-shadow: var(--shadow-soft); }
.jdf-about p { margin: 0 0 18px; font-size: 16px; color: #384850; }

@media (max-width: 880px) {
  .jdf-about { grid-template-columns: 1fr; }
}

/* ===== FAQ ===== */
.jdf-faq-layout { display: grid; grid-template-columns: 2fr 1fr; gap: 40px; align-items: start; }
.jdf-faq-list details {
  background: var(--white); border-radius: 16px; padding: 18px 20px; margin-bottom: 12px; box-shadow: var(--shadow-soft);
}
.jdf-faq-list summary { font-weight: 700; font-size: 15.5px; cursor: pointer; list-style: none; }
.jdf-faq-list summary::-webkit-details-marker { display: none; }
.jdf-faq-list summary::after { content: '+'; float: right; font-weight: 400; color: var(--mint); }
.jdf-faq-list details[open] summary::after { content: '−'; }
.jdf-faq-list p { margin: 14px 0 0; color: #4b5a60; font-size: 14.5px; }
.jdf-faq-side {
  background: var(--lavender); border-radius: var(--radius-md); padding: 24px; text-align: center; position: sticky; top: 96px;
}
.jdf-faq-side h3 { font-size: 17px; margin: 0 0 10px; }
.jdf-faq-side p { font-size: 13.5px; margin: 0 0 16px; color: #4b5a60; }

@media (max-width: 880px) {
  .jdf-faq-layout { grid-template-columns: 1fr; }
  .jdf-faq-side { position: static; }
}

/* ===== Arch-frame CTA ===== */
.jdf-cta-outer { padding: 40px 16px 0; }
.jdf-cta-frame {
  max-width: 920px; margin: 0 auto;
  background: linear-gradient(180deg, #17b3a4, var(--mint));
  border-radius: 260px 260px 28px 28px;
  padding: 22px 22px 0;
  box-shadow: 0 30px 60px rgba(34,199,184,0.25);
}
.jdf-cta-inner {
  background: var(--sky);
  border-radius: 240px 240px 16px 16px;
  padding: 72px 40px 48px;
  text-align: center;
  position: relative;
  box-shadow: inset 0 2px 12px rgba(0,0,0,0.05);
}
.jdf-cta-sill { height: 16px; background: rgba(0,0,0,0.12); border-radius: 0 0 8px 8px; max-width: 920px; margin: 0 auto; }
.jdf-cta-inner h2 { font-size: clamp(24px, 3.6vw, 34px); font-weight: 800; margin: 0 0 14px; }
.jdf-cta-inner p { font-size: 15.5px; color: #384850; margin: 0 0 32px; }
.jdf-cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

@media (max-width: 640px) {
  .jdf-cta-frame { border-radius: 140px 140px 20px 20px; padding: 16px 16px 0; }
  .jdf-cta-inner { border-radius: 124px 124px 12px 12px; padding: 52px 20px 36px; }
}

/* ===== Footer ===== */
.jdf-footer-molding { height: 10px; background: repeating-linear-gradient(90deg, var(--mint) 0 24px, var(--lime) 24px 48px); }
.jdf-footer-molding + .jdf-footer-molding { height: 4px; opacity: 0.5; }
.jdf-footer { background: var(--aqua); padding: 48px 0 28px; }
.jdf-footer-grid { display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.jdf-footer-brand { font-size: 19px; font-weight: 800; margin-bottom: 10px; }
.jdf-footer-info { display: grid; grid-template-columns: repeat(2, auto); gap: 6px 32px; font-size: 14px; color: #38484e; }
.jdf-footer-info b { color: var(--ink); font-weight: 700; margin-right: 6px; }
.jdf-footer-bottom { margin-top: 32px; padding-top: 20px; border-top: 1px solid rgba(38,51,56,0.1); font-size: 12.5px; color: #5b6b70; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }

@media (max-width: 640px) {
  .jdf-footer-info { grid-template-columns: 1fr; }
  .jdf-footer-bottom { flex-direction: column; }
}

/* ===== Before/After compare ===== */
.jdf-compare { position: relative; border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-soft); }
.jdf-compare img { width: 100%; display: block; }
.jdf-compare-after { position: absolute; inset: 0; }
.jdf-compare-tag { position: absolute; top: 12px; font-weight: 700; font-size: 12px; padding: 4px 12px; border-radius: 999px; color: var(--white); z-index: 2; }
.jdf-compare-tag--before { left: 12px; background: var(--coral); }
.jdf-compare-tag--after { right: 12px; background: var(--mint); }
.jdf-compare input[type="range"] { position: absolute; bottom: 12px; left: 12px; right: 12px; width: calc(100% - 24px); z-index: 3; }

/* ===== Page hero (service pages) ===== */
.jdf-page-hero { padding: 48px 0 40px; }
.jdf-breadcrumb { font-size: 13px; color: #5b6b70; margin-bottom: 14px; }
.jdf-breadcrumb a:hover { color: var(--mint); }
.jdf-related-links { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 24px; }
.jdf-related-links a { padding: 10px 18px; border-radius: 999px; background: var(--gray-light); font-weight: 700; font-size: 14px; }
.jdf-related-links a:hover { background: var(--lavender); }

.jdf-checklist { background: var(--white); border-radius: var(--radius-md); padding: 24px 28px; box-shadow: var(--shadow-soft); }
.jdf-checklist li { display: flex; gap: 10px; margin-bottom: 10px; font-size: 15px; }
.jdf-checklist li::before { content: '✓'; color: var(--mint); font-weight: 800; }

.jdf-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
@media (max-width: 880px) { .jdf-two-col { grid-template-columns: 1fr; } }

.jdf-note-box { background: var(--lemon); border-radius: 16px; padding: 18px 22px; font-size: 14px; margin: 24px 0; }

/* ===== Sitemap page ===== */
.jdf-sitemap-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.jdf-sitemap-card { background: var(--white); border-radius: var(--radius-md); padding: 24px; box-shadow: var(--shadow-soft); }
.jdf-sitemap-card h3 { margin: 0 0 12px; font-size: 16px; color: var(--mint); }
.jdf-sitemap-card li { margin-bottom: 8px; }
.jdf-sitemap-card a:hover { color: var(--mint); }
@media (max-width: 880px) { .jdf-sitemap-grid { grid-template-columns: 1fr; } }

