/* 채움 — 공실 제안 플랫폼 v0.1 */

:root {
  --paper: #EDEDE9;
  --card: #FFFFFF;
  --ink: #1A1E23;
  --muted: #6E736E;
  --line: #C9CCC4;
  --green: #14634B;
  --green-deep: #0E4A38;
  --green-soft: #E4EEE8;
  --font-display: 'Song Myung', 'Nanum Myeongjo', serif;
  --font-body: 'Pretendard Variable', Pretendard, -apple-system, 'Malgun Gothic', sans-serif;
  --font-mono: 'IBM Plex Mono', 'Courier New', monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: 960px; margin: 0 auto; padding: 0 20px; }

a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--green); outline-offset: 3px; }
img { max-width: 100%; display: block; }

/* ---------- 헤더 ---------- */
.site-header { padding: 28px 0; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; }

.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-display); font-size: 1.35rem; letter-spacing: 0.06em; }
.brand-block { width: 16px; height: 16px; border: 1.5px dashed var(--green); animation: fill-in 0.9s ease 0.4s forwards; }
@keyframes fill-in { to { background: var(--green); border-style: solid; } }

.site-nav { display: flex; gap: 22px; font-size: 0.92rem; }
.site-nav a { text-decoration: none; color: var(--muted); }
.site-nav a:hover, .site-nav a[aria-current] { color: var(--ink); }

/* ---------- 히어로 ---------- */
.hero { padding: 72px 0 56px; }
.eyebrow { font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.14em; color: var(--green); text-transform: uppercase; }
.hero h1 { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.7rem, 4.6vw, 2.7rem); line-height: 1.45; margin-top: 18px; }
.hero h1 em { font-style: normal; color: var(--green); }
.hero .lead { margin-top: 20px; max-width: 34em; color: var(--muted); }

/* ---------- 섹션 공통 ---------- */
.section { padding: 48px 0; border-top: 1px solid var(--line); }
.section-label { font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.14em; color: var(--muted); margin-bottom: 26px; }
.section-label b { color: var(--green); font-weight: 600; }

/* ---------- 공실 카드 (시그니처: 점선 → 채움) ---------- */
.listing-card {
  display: block; text-decoration: none;
  background: var(--card);
  border: 1.5px dashed var(--line);
  transition: border-color 0.35s ease, box-shadow 0.35s ease;
  position: relative;
}
.listing-card::after {
  content: ''; position: absolute; left: 0; bottom: 0; height: 4px; width: 0;
  background: var(--green); transition: width 0.5s ease;
}
.listing-card:hover { border: 1.5px solid var(--green); box-shadow: 0 14px 40px rgba(20, 99, 75, 0.12); }
.listing-card:hover::after { width: 100%; }

.listing-photo { aspect-ratio: 16 / 9; overflow: hidden; background: var(--green-soft); }
.listing-photo img { width: 100%; height: 100%; object-fit: cover; }

.listing-body { padding: 26px 28px 30px; }
.listing-place { font-family: var(--font-display); font-size: 1.3rem; }
.listing-addr { color: var(--muted); font-size: 0.9rem; margin-top: 4px; }

.spec-row { display: flex; flex-wrap: wrap; gap: 8px 26px; margin-top: 18px; font-family: var(--font-mono); font-size: 0.86rem; }
.spec-row span b { color: var(--green); font-weight: 600; }

.tag-row { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 8px; }
.tag { font-size: 0.8rem; padding: 4px 12px; background: var(--green-soft); color: var(--green-deep); border-radius: 999px; }

.listing-cta { margin-top: 20px; font-size: 0.92rem; color: var(--green); font-weight: 600; }

/* ---------- 프로세스 ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step { background: var(--card); padding: 22px 22px 26px; border-top: 3px solid var(--green); }
.step .no { font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted); }
.step h3 { font-size: 1rem; margin-top: 8px; }
.step p { font-size: 0.88rem; color: var(--muted); margin-top: 8px; }

/* ---------- CTA 스트립 ---------- */
.cta-strip { background: var(--ink); color: #F4F5F2; padding: 44px 0; }
.cta-strip h2 { font-family: var(--font-display); font-weight: 400; font-size: 1.4rem; }
.cta-strip p { color: #B9BDB6; margin-top: 8px; font-size: 0.94rem; }
.cta-strip .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }

.btn {
  display: inline-block; text-decoration: none; font-weight: 600; font-size: 0.95rem;
  padding: 13px 26px; border: 1.5px solid transparent; cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease;
}
.btn:active { transform: translateY(1px); }
.btn-green { background: var(--green); color: #fff; }
.btn-green:hover { background: var(--green-deep); }
.btn-ghost { border-color: var(--line); color: inherit; }
.btn-ghost:hover { border-color: var(--green); color: var(--green); }
.cta-strip .btn-ghost { border-color: #4A4F48; color: #F4F5F2; }
.cta-strip .btn-ghost:hover { border-color: var(--green); }

/* ---------- 상세 페이지 ---------- */
.back-link { display: inline-block; margin-top: 8px; font-size: 0.88rem; color: var(--muted); text-decoration: none; }
.back-link:hover { color: var(--green); }

.detail-head { padding: 36px 0 8px; }
.detail-head h1 { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.5rem, 4vw, 2.1rem); }
.detail-head .addr { color: var(--muted); margin-top: 6px; }

.spec-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line); background: var(--card); margin-top: 28px;
}
.spec-cell { padding: 18px 20px; border-right: 1px solid var(--line); }
.spec-cell:last-child { border-right: 0; }
.spec-cell .k { font-size: 0.78rem; color: var(--muted); }
.spec-cell .v { font-family: var(--font-mono); font-size: 1.02rem; margin-top: 4px; }
.spec-cell .v small { font-size: 0.75rem; color: var(--muted); }

.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--green-soft); }
.gallery img:first-child { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; height: 100%; }

.feature-list { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 32px; }
.feature-list li { padding-left: 22px; position: relative; font-size: 0.95rem; }
.feature-list li::before { content: ''; position: absolute; left: 0; top: 0.55em; width: 10px; height: 10px; background: var(--green); }

.map-frame { border: 1px solid var(--line); width: 100%; height: 340px; }

/* ---------- AI 리포트 ---------- */
.report { background: var(--card); border: 1px solid var(--line); border-top: 4px solid var(--green); padding: 36px 34px 40px; }
.report-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; border-bottom: 1px solid var(--line); padding-bottom: 18px; }
.report-head h2 { font-family: var(--font-display); font-weight: 400; font-size: 1.4rem; }
.report-head .meta { font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted); }

.report h3 { font-size: 1.02rem; margin: 30px 0 12px; color: var(--green-deep); }
.report p { font-size: 0.95rem; max-width: 44em; }
.report p + p { margin-top: 10px; }

.pick { border: 1px solid var(--line); padding: 20px 22px; margin-top: 14px; }
.pick-head { display: flex; align-items: baseline; gap: 12px; }
.pick-rank { font-family: var(--font-mono); font-size: 0.8rem; color: var(--green); font-weight: 600; }
.pick-head h4 { font-size: 1.05rem; }
.pick p { font-size: 0.9rem; color: var(--muted); margin-top: 8px; }
.pick .fit { margin-top: 10px; font-size: 0.82rem; color: var(--green-deep); }

.report .disclaimer { margin-top: 30px; font-size: 0.78rem; color: var(--muted); border-top: 1px dashed var(--line); padding-top: 14px; }

/* ---------- 문의 ---------- */
.inquiry { text-align: center; padding: 60px 0; }
.inquiry h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.3rem, 3.5vw, 1.7rem); }
.inquiry p { color: var(--muted); margin-top: 10px; }
.inquiry .btn-row { margin-top: 26px; display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }

/* ---------- 임대인 페이지 ---------- */
.owner-hero { padding: 64px 0 40px; }
.owner-hero h1 { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.6rem, 4.4vw, 2.4rem); line-height: 1.45; }
.owner-hero p { margin-top: 18px; color: var(--muted); max-width: 36em; }
.price-note { display: inline-block; margin-top: 22px; font-family: var(--font-mono); font-size: 0.82rem; color: var(--green); border: 1.5px dashed var(--green); padding: 8px 16px; }

/* ---------- 푸터 ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 30px 0 44px; margin-top: 40px; font-size: 0.8rem; color: var(--muted); }
.site-footer .legal { margin-top: 6px; }

/* ---------- 폼 (공실 등록) ---------- */
.form-page { max-width: 640px; }
.field { margin-bottom: 24px; }
.field > .lbl { display: block; font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.1em; color: var(--muted); margin-bottom: 8px; }
.field input[type="text"], .field input[type="number"], .field textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); background: var(--card);
  font: inherit; color: var(--ink);
}
.field input:focus, .field textarea:focus { outline: 2px solid var(--green); outline-offset: 0; border-color: var(--green); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.chip-group { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-group label { cursor: pointer; }
.chip-group input { position: absolute; opacity: 0; }
.chip-group span { display: inline-block; padding: 7px 15px; border: 1px solid var(--line); background: var(--card); font-size: 0.88rem; border-radius: 999px; transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease; }
.chip-group input:checked + span { background: var(--green); border-color: var(--green); color: #fff; }
.chip-group input:focus-visible + span { outline: 3px solid var(--green); outline-offset: 2px; }
.form-note { font-size: 0.82rem; color: var(--muted); margin-top: 8px; }
.submit-result { display: none; margin-top: 28px; border: 1.5px dashed var(--green); background: var(--green-soft); padding: 22px; }
.submit-result.show { display: block; }
.submit-result h3 { font-size: 1rem; color: var(--green-deep); }
.submit-result p { font-size: 0.88rem; margin-top: 8px; }
.submit-result textarea { width: 100%; height: 190px; font-family: var(--font-mono); font-size: 0.78rem; border: 1px solid var(--line); padding: 10px; background: #fff; margin-top: 12px; }
.submit-result .btn-row { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }

/* ---------- 목록 & 필터 ---------- */
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.filter-chip { font: inherit; font-size: 0.88rem; padding: 7px 15px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); cursor: pointer; transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease; }
.filter-chip[aria-pressed="true"] { background: var(--green); color: #fff; border-color: var(--green); }
.card-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.card-grid .listing-card .listing-photo { aspect-ratio: 16 / 10; }
.badge-row { display: flex; gap: 6px; margin-bottom: 10px; }
.badge { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.06em; padding: 3px 10px; background: var(--ink); color: #fff; }
.empty-slot { border: 1.5px dashed var(--line); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 40px 24px; color: var(--muted); text-decoration: none; min-height: 280px; transition: border-color 0.3s ease, color 0.3s ease; }
.empty-slot:hover { border-color: var(--green); color: var(--green); }
.empty-slot .plus { font-family: var(--font-mono); font-size: 2rem; line-height: 1; margin-bottom: 12px; }
.empty-slot strong { font-family: var(--font-display); font-weight: 400; font-size: 1.1rem; }
.empty-slot small { margin-top: 6px; font-size: 0.82rem; }

/* ---------- 담당자 스트립 ---------- */
.pro-strip { border: 1px solid var(--line); background: var(--card); padding: 26px 28px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.pro-strip h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.15rem; }
.pro-strip p { font-size: 0.88rem; color: var(--muted); margin-top: 4px; }

/* ---------- 모션 ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.65s ease, transform 0.65s cubic-bezier(0.22, 0.7, 0.25, 1); }
.reveal.in { opacity: 1; transform: none; }

@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.hero .eyebrow, .owner-hero .eyebrow, .detail-head .eyebrow { animation: rise 0.6s ease 0.1s backwards; }
.hero h1, .owner-hero h1, .detail-head h1 { animation: rise 0.7s ease 0.25s backwards; }
.hero .lead, .owner-hero p, .detail-head .addr { animation: rise 0.7s ease 0.45s backwards; }

@keyframes sweep { to { background-size: 100% 100%; } }
.hero h1 em, .owner-hero h1 em {
  background-image: linear-gradient(transparent 60%, var(--green-soft) 60%);
  background-repeat: no-repeat; background-size: 0% 100%;
  animation: sweep 0.7s ease 1.05s forwards;
}

.listing-photo img { transition: transform 0.6s cubic-bezier(0.22, 0.7, 0.25, 1); }
.listing-card:hover .listing-photo img { transform: scale(1.04); }

.step { border-top: 0; position: relative; }
.step::before { content: ''; position: absolute; top: 0; left: 0; height: 3px; width: 100%; background: var(--green); transform: scaleX(0); transform-origin: left; transition: transform 0.8s ease 0.25s; }
.step.in::before { transform: scaleX(1); }

.site-nav a { position: relative; transition: color 0.25s ease; }
.site-nav a::after { content: ''; position: absolute; left: 0; bottom: -5px; height: 1.5px; width: 100%; background: var(--green); transform: scaleX(0); transform-origin: left; transition: transform 0.3s ease; }
.site-nav a:hover::after, .site-nav a[aria-current]::after { transform: scaleX(1); }

.gallery img { transition: opacity 0.65s ease, transform 0.65s cubic-bezier(0.22, 0.7, 0.25, 1), filter 0.4s ease; }
.gallery img:hover { filter: brightness(1.06); }

.btn { transition: transform 0.2s ease, background 0.25s ease, border-color 0.25s ease, color 0.25s ease, box-shadow 0.25s ease; }
.btn-green:hover { box-shadow: 0 10px 26px rgba(20, 99, 75, 0.28); transform: translateY(-2px); }
.btn-green:active { transform: translateY(0); }

/* ---------- 반응형 ---------- */
@media (max-width: 720px) {
  .steps { grid-template-columns: 1fr; }
  .spec-grid { grid-template-columns: 1fr 1fr; }
  .spec-cell:nth-child(2) { border-right: 0; }
  .gallery { grid-template-columns: 1fr 1fr; }
  .gallery img:first-child { grid-column: span 2; grid-row: auto; aspect-ratio: 16 / 10; }
  .feature-list { grid-template-columns: 1fr; }
  .report { padding: 26px 20px 32px; }
  .card-grid { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .brand-block { animation: none; background: var(--green); border-style: solid; }
  .listing-card, .listing-card::after, .btn, .listing-photo img, .gallery img, .step::before { transition: none; }
  .hero .eyebrow, .hero h1, .hero .lead,
  .owner-hero .eyebrow, .owner-hero h1, .owner-hero p,
  .detail-head .eyebrow, .detail-head h1, .detail-head .addr,
  .hero h1 em, .owner-hero h1 em { animation: none; }
  .hero h1 em, .owner-hero h1 em { background-size: 100% 100%; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .step::before { transform: scaleX(1); }
}
