/* 지원사업 통합 조회(SUPPORT-01) 전용 스타일
   공통 토큰·프리미티브(.container/.btn/.brand/.badge)는 common.css 에서 로드됨 */

/* 본문 래퍼 */
.support-main { padding: 30px 0 56px; background: var(--surface-2); min-height: 60vh; }

/* 목록처럼 푸터가 있는 페이지는 내용이 짧아도 푸터를 화면 바닥에 고정한다.
   상세 페이지는 푸터 없이 하단 고정 CTA를 쓰므로 :has로 제외한다. */
body:has(.site-footer) { display: flex; flex-direction: column; min-height: 100vh; }
body:has(.site-footer) .support-main { flex: 1 0 auto; }
.site-footer { flex-shrink: 0; }
.support-inner { display: flex; flex-direction: column; gap: 16px; padding: 0 24px; }

/* 상단: 건수 + 모집상태 토글 */
.sp-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.sp-count { font-size: 23px; font-weight: 800; letter-spacing: -.02em; color: var(--ink); }
.sp-count-num { color: var(--brand); }
.sp-sub { margin-top: 4px; font-size: 13px; color: var(--muted); }
.sp-active-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.sp-active-chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 5px 8px 5px 11px;
  background: var(--brand-tint); color: var(--brand-dark);
  border-radius: 20px; font-size: 12px; font-weight: 700;
}
.sp-chip-x { border: 0; background: none; color: var(--brand-dark); font-size: 14px; line-height: 1; padding: 0 2px; }

.sp-recruit { flex: 0 0 auto; display: inline-flex; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 3px; }
.sp-recruit-btn {
  border: 0; background: none; padding: 7px 14px; border-radius: 8px;
  font-size: 13px; font-weight: 700; color: var(--muted);
}
.sp-recruit-btn.is-active { background: var(--brand); color: #fff; }

/* 유형 탭 */
.sp-type-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.sp-tab {
  border: 1px solid #eae1db; background: #fff;
  padding: 8px 13px; border-radius: 20px;
  font-size: 13px; font-weight: 600; color: var(--text-soft);
}
.sp-tab:hover { border-color: var(--brand); color: var(--brand); }
.sp-tab.is-active { background: var(--brand); border-color: var(--brand); color: #fff; }
.sp-tab-n { font-size: 11.5px; opacity: .7; margin-left: 3px; }

/* 필터 행 */
.sp-filters {
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px;
  padding: 14px 16px; background: #fff;
  border: 1px solid var(--card-line); border-radius: 12px;
}
.sp-filter { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.sp-filter-label { font-size: 12px; font-weight: 700; color: var(--faint); margin-right: 4px; }
.sp-chip {
  border: 1px solid var(--line); background: #fff;
  padding: 5px 11px; border-radius: 18px;
  font-size: 12.5px; font-weight: 600; color: var(--text-soft);
}
.sp-chip:hover { border-color: var(--brand); color: var(--brand); }
.sp-chip.is-active { background: var(--brand-tint); border-color: var(--brand); color: var(--brand-dark); }
.sp-search { margin-left: auto; flex: 1 1 200px; min-width: 170px; }
.sp-search input {
  width: 100%; height: 38px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: 9px;
  font-size: 13px; color: var(--text); background: #fff;
}
.sp-search input:focus { outline: none; border-color: var(--brand); }

/* 상세 필터 */
.sp-detail { border: 1px solid var(--card-line); border-radius: 12px; background: #fff; }
.sp-detail-summary {
  list-style: none; cursor: pointer;
  padding: 13px 16px; font-size: 13px; font-weight: 700; color: var(--text);
  display: flex; align-items: center; gap: 10px;
}
.sp-detail-summary::-webkit-details-marker { display: none; }
.sp-detail-summary::before { content: "\203A"; color: var(--faint); font-weight: 800; display: inline-block; transition: transform .15s; }
.sp-detail[open] .sp-detail-summary::before { transform: rotate(90deg); }
.sp-detail-note { font-size: 11px; font-weight: 700; color: var(--info); background: var(--info-bg); padding: 3px 8px; border-radius: 12px; }
.sp-detail-body { padding: 4px 16px 16px; display: flex; flex-direction: column; gap: 10px; }
.sp-detail-row { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }

/* 배너 */
.sp-banner {
  display: flex; align-items: center; flex-wrap: wrap; gap: 12px;
  padding: 12px 16px; border-radius: 10px;
  background: var(--warn-bg); border: 1px solid #efd9ad;
  font-size: 13px; color: #7a5a1a;
}
.sp-banner-text { flex: 1 1 auto; font-weight: 600; }
.sp-banner-check { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; cursor: pointer; }
.sp-banner-clear { border: 1px solid #e0c896; background: #fff; color: #7a5a1a; padding: 6px 12px; border-radius: 8px; font-size: 12.5px; font-weight: 700; }

/* 목록 */
.sp-list { display: flex; flex-direction: column; gap: 10px; }
.sp-card {
  display: flex; align-items: center; gap: 16px;
  padding: 16px 18px; background: #fff;
  border: 1px solid var(--card-line); border-radius: 12px;
  transition: border-color .12s, box-shadow .12s;
}
.sp-card:hover { border-color: var(--brand); box-shadow: 0 6px 18px rgba(168, 65, 44, .08); }
.sp-card-info { flex: 1 1 0; min-width: 0; }
.sp-card-head { display: flex; align-items: center; gap: 10px; }
.sp-type { flex: 0 0 auto; font-size: 11px; font-weight: 700; color: var(--brand-dark); background: var(--brand-tint); padding: 3px 9px; border-radius: 6px; }
.sp-title { font-size: 15px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-meta { margin-top: 6px; font-size: 12.5px; color: var(--muted); }
.sp-card-side { flex: 0 0 auto; display: flex; align-items: center; gap: 12px; }
.sp-status { font-size: 12px; font-weight: 700; white-space: nowrap; }
.sp-status-ok { color: var(--ok); }
.sp-status-danger { color: var(--danger); }
.sp-status-info { color: var(--info); }
.sp-status-muted { color: var(--faint); }
.sp-status-always { color: var(--muted-2); }
.sp-src { font-size: 10.5px; font-weight: 700; padding: 3px 9px; border-radius: 20px; white-space: nowrap; }
.sp-src-KSTARTUP { color: #3a5aa5; background: #e6ebf6; }
.sp-src-BIZINFO { color: #7a5a1a; background: var(--warn-bg); }
.sp-origin { font-size: 12px; font-weight: 700; color: var(--brand); border: 1px solid var(--line); border-radius: 8px; padding: 7px 12px; white-space: nowrap; }
.sp-origin:hover { border-color: var(--brand); background: var(--brand-tint); }

/* 빈 상태 */
.sp-empty { text-align: center; padding: 56px 20px; }
.sp-empty-title { font-size: 15px; font-weight: 700; color: var(--text); }
.sp-empty-sub { margin-top: 6px; font-size: 13px; color: var(--muted); }
.sp-empty .btn { margin-top: 16px; }

/* 더 보기 */
.sp-more-wrap { display: flex; justify-content: center; padding-top: 6px; }
.sp-more { border: 1px solid var(--line); background: #fff; color: var(--text); padding: 11px 28px; border-radius: 10px; font-size: 13px; font-weight: 700; }
.sp-more:hover { border-color: var(--brand); color: var(--brand); }

/* 푸터 (랜딩과 동일 패턴) */
.site-footer { border-top: 1px solid var(--line); background: #fff; }
.footer-inner {
  display: flex; align-items: center; flex-wrap: wrap; gap: 16px 28px;
  padding: 34px 24px;
}
.footer-brand { display: inline-flex; align-items: center; gap: 10px; }
.footer-nav { display: flex; gap: 22px; font-size: 13px; font-weight: 600; color: var(--text-soft); }
.footer-nav a:hover { color: var(--brand); }
.footer-copy { margin-left: auto; font-size: 12.5px; color: var(--faint); }

/* 반응형 · 태블릿 */
@media (max-width: 720px) {
  .sp-head { flex-direction: column; }
  .sp-search { margin-left: 0; }
  .sp-card { flex-direction: column; align-items: stretch; gap: 12px; }
  .sp-card-side { justify-content: space-between; }
  .sp-title { white-space: normal; }
}

/* 반응형 · 모바일 (1열 · 햄버거) */
@media (max-width: 640px) {
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-copy { margin-left: 0; }
}

/* 상세 (SUPPORT-02) */
.spd-main { padding: 30px 0 96px; }
.spd-wrap { max-width: 860px; }
.spd-back { display: inline-block; margin-bottom: 14px; font-size: 13px; font-weight: 600; color: var(--muted); }
.spd-back::before { content: "\2190"; margin-right: 6px; }
.spd-back:hover { color: var(--brand); }
.spd-card { background: #fff; border: 1px solid var(--card-line); border-radius: 14px; padding: 28px 30px; }
.spd-loading, .spd-missing { text-align: center; padding: 48px 0; color: var(--muted); }
.spd-missing-title { font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 16px; }

.spd-top { display: flex; align-items: center; gap: 10px; }
.spd-status { font-size: 12px; font-weight: 700; margin-left: auto; }
.spd-title { margin-top: 14px; font-size: 24px; font-weight: 800; color: var(--ink); line-height: 1.35; overflow-wrap: anywhere; }

.spd-info { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 22px; }
.spd-info-cell { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 10px; padding: 13px 15px; }
.spd-info-label { display: block; font-size: 11.5px; color: var(--faint); }
.spd-info-value { display: block; margin-top: 5px; font-size: 13.5px; font-weight: 600; color: var(--text); overflow-wrap: anywhere; }
.spd-info-value.is-strong { color: var(--brand); font-weight: 800; }

.spd-section { margin-top: 28px; }
.spd-section-title { font-size: 14px; font-weight: 800; color: var(--ink); margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.spd-note-inline { font-size: 11px; font-weight: 600; color: var(--faint); }
.spd-ks-badge { font-size: 11px; font-weight: 700; color: var(--info); background: var(--info-bg); padding: 3px 8px; border-radius: 12px; }
.spd-text { font-size: 13.5px; line-height: 1.7; color: var(--text); white-space: pre-wrap; overflow-wrap: anywhere; background: var(--surface); border: 1px solid var(--line-soft); border-radius: 10px; padding: 14px 16px; }

.spd-ks-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.spd-ks-cell { background: var(--surface); border: 1px solid var(--line-soft); border-radius: 10px; padding: 13px 15px; }
.spd-ks-label { display: block; font-size: 11.5px; color: var(--faint); }
.spd-ks-value { display: block; margin-top: 5px; font-size: 13.5px; color: var(--text); line-height: 1.55; overflow-wrap: anywhere; }

/* 하단 고정 CTA */
.spd-cta { position: sticky; bottom: 0; background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(90, 45, 28, .06); margin-top: 20px; }
.spd-cta-inner { max-width: 860px; display: flex; align-items: center; gap: 16px; padding: 14px 24px; }
.spd-cta-note { flex: 1 1 auto; font-size: 12.5px; color: var(--muted); }
.spd-cta-btn { flex: 0 0 auto; background: var(--brand); color: #fff; font-size: 13.5px; font-weight: 700; padding: 12px 22px; border-radius: 10px; }
.spd-cta-btn:hover { filter: brightness(1.05); }

@media (max-width: 720px) {
  .spd-info { grid-template-columns: repeat(2, 1fr); }
  .spd-ks-grid { grid-template-columns: 1fr; }
  .spd-card { padding: 22px 18px; }
  .spd-title { font-size: 20px; }
}
