/* =======================================================================
   Figma 스타일 디자인 시스템 (Pretendard)
   흑백 에디토리얼 chrome + 파스텔 컬러블록 + pill 버튼
   style.css 뒤에 로드되어 홈/공통 chrome 을 덮어쓴다.
   ======================================================================= */
:root {
  --fig-ink: #0a0a0a;
  --fig-canvas: #ffffff;
  --fig-hairline: #e6e6e6;
  --fig-surface: #f7f7f5;
  --fig-lime: #dceeb1;
  --fig-lilac: #c5b0f4;
  --fig-cream: #f4ecd6;
  --fig-mint: #c8e6cd;
  --fig-pink: #efd4d4;
  --fig-coral: #f3c9b6;
  --fig-navy: #1f1d3d;
}

body {
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
    system-ui, "Segoe UI", "Malgun Gothic", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ── 상단 네비 (white editorial) ───────────────────────────── */
.site-header { background: #fff; border-bottom: 1px solid var(--fig-hairline); box-shadow: 0 1px 8px rgba(0,0,0,0.08); }
.header-inner { height: 64px; }
.logo, .logo span {
  color: #0a0a0a !important; -webkit-text-stroke: 0 !important;
  font-weight: 800; font-size: 23px; letter-spacing: -0.035em;
}
.header-nav { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.header-nav a {
  color: #0a0a0a; font-size: 15px; font-weight: 460;
  padding: 8px 12px; border-radius: 9999px;
}
.header-nav a:hover { background: var(--fig-surface); color: #0a0a0a; }
.header-nav .nav-signup { background: #0a0a0a; color: #fff; padding: 9px 18px; margin-left: 4px; }
.header-nav .nav-signup:hover { background: #2a2a2a; color: #fff; }
.logout-form button { color: #0a0a0a; font-weight: 460; }
.logout-form button:hover { color: #0a0a0a; text-decoration: underline; }

/* ── 버튼 → pill ───────────────────────────────────────────── */
.btn-primary {
  display: inline-block; background: #0a0a0a; color: #fff;
  border-radius: 9999px; padding: 12px 24px; font-weight: 500; font-size: 16px;
}
.btn-primary:hover { background: #2a2a2a; }
.btn-secondary {
  display: inline-block; background: #fff; color: #0a0a0a; border: 1px solid #0a0a0a;
  border-radius: 9999px; padding: 11px 22px; font-weight: 500; font-size: 16px;
}
.btn-secondary:hover { background: var(--fig-surface); }

/* ===== 홈(Figma 에디토리얼) ============================================ */
.fig-eyebrow {
  font-family: "JetBrains Mono", ui-monospace, "Pretendard Variable", monospace;
  text-transform: uppercase; letter-spacing: 0.14em;
  font-size: 13px; font-weight: 600; color: #0a0a0a;
}

/* 히어로 */
.fig-hero {
  text-align: center; padding: 60px 8px 36px;
  background: linear-gradient(170deg, #f4ead6 0%, #f7f5ef 35%, #fafaf8 65%, #fff 100%);
  width: 100vw; margin-left: calc(50% - 50vw); padding-left: 8px; padding-right: 8px;
}
.fig-hero .fig-eyebrow { margin-bottom: 22px; }
.fig-display {
  font-size: clamp(38px, 7vw, 76px); font-weight: 900; line-height: 1.05;
  letter-spacing: -0.035em; color: #0a0a0a;
}
.fig-lead {
  font-size: 20px; font-weight: 340; color: #0a0a0a; line-height: 1.45;
  max-width: 600px; margin: 22px auto 26px;
}
.fig-search {
  display: flex; max-width: 560px; margin: 0 auto;
  border: 1.5px solid #0a0a0a; border-radius: 9999px; overflow: hidden; background: #fff;
}
.fig-search input { flex: 1; border: none; padding: 15px 24px; font-size: 16px; outline: none; }
.fig-search button { border: none; background: #0a0a0a; color: #fff; padding: 0 30px; font-weight: 500; font-size: 16px; cursor: pointer; }
.fig-search button:hover { background: #2a2a2a; }
.fig-cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 22px; }

/* 마퀴 (풀블리드 검정 띠) */
.fig-marquee {
  width: 100vw; margin-left: calc(50% - 50vw); margin-top: 28px;
  background: #0a0a0a; color: #fff; padding: 13px 0; overflow: hidden; white-space: nowrap;
}
.fig-marquee .track { display: inline-block; animation: fig-scroll 40s linear infinite; }
.fig-marquee:hover .track { animation-play-state: paused; }
.fig-marquee span { font-size: 14px; letter-spacing: 0.01em; padding: 0 8px; }
.fig-marquee b { color: var(--fig-lime); font-weight: 700; }
.fig-marquee .tk { font-size: 14px; color: #fff; text-decoration: none; padding: 0 8px; }
.fig-marquee .tk:hover { color: var(--fig-lime); text-decoration: underline; }
.fig-marquee .tk .tk-d { color: #9ca3af; padding: 0; }
.fig-marquee .tk-head { color: var(--fig-lime); font-weight: 700; }
.fig-marquee .tk-sep { color: #555; padding: 0 2px; }
@keyframes fig-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* 마퀴 하단 라임 스트립 */
.fig-post-marquee {
  width: 100vw; margin-left: calc(50% - 50vw);
  background: var(--fig-lime); color: #2d3b00;
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 6px 20px;
  padding: 11px 20px; font-size: 13px; font-weight: 500;
}
.fig-post-marquee b { font-weight: 700; }
.fig-post-marquee a { color: #2d3b00; font-weight: 700; text-decoration: underline; }
.fig-post-marquee a:hover { opacity: .75; }
.fig-pm-sep { width: 1px; height: 14px; background: rgba(0,0,0,.2); flex-shrink: 0; }

/* 컬러 블록 */
.fig-block { border-radius: 24px; padding: 48px 44px; margin: 22px 0; }
.fig-block.lime { background: var(--fig-lime); color: #0a0a0a; }
.fig-block.lilac { background: var(--fig-lilac); color: #0a0a0a; }
.fig-block.cream { background: var(--fig-cream); color: #0a0a0a; }
.fig-block.mint { background: var(--fig-mint); color: #0a0a0a; }
.fig-block.navy { background: var(--fig-navy); color: #fff; }
.fig-block .fig-eyebrow { color: inherit; opacity: .65; margin-bottom: 16px; }
.fig-block h2 { font-size: clamp(26px, 4.2vw, 40px); font-weight: 350; letter-spacing: -0.025em; line-height: 1.12; margin-bottom: 14px; }
.fig-block p { font-size: 18px; font-weight: 330; line-height: 1.5; max-width: 620px; }
.fig-feats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 28px; }
.fig-feat { background: rgba(255,255,255,.6); border-radius: 14px; padding: 18px 18px 16px; }
.fig-block.navy .fig-feat { background: rgba(255,255,255,.09); }
.fig-feat strong { display: block; font-size: 16px; font-weight: 600; margin-bottom: 5px; }
.fig-feat span { font-size: 13.5px; opacity: .82; line-height: 1.4; }

/* 섹션 헤더 */
.fig-sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 32px 0 18px; flex-wrap: wrap; }
.fig-sec-head h2 { font-size: clamp(26px, 3.5vw, 34px); font-weight: 350; letter-spacing: -0.025em; }
.fig-sec-head a { font-size: 16px; font-weight: 480; border-bottom: 1.5px solid #0a0a0a; padding-bottom: 1px; }

/* 홈 리스팅 카드 — 흑백+파스텔 칩 */
.fig-home .notice-card { border: 1px solid var(--fig-hairline); border-radius: 16px; }
.fig-home .notice-card:hover { box-shadow: 0 6px 22px rgba(0,0,0,.07); border-color: #0a0a0a; }
.fig-home .tag-region { background: var(--fig-lilac); color: #1f1d3d; }
.fig-home .tag-committee { background: var(--fig-mint); color: #14532d; }
.fig-home .tag-category { background: var(--fig-cream); color: #6b5a1e; }
.fig-home .card-title { color: #0a0a0a; }

@media (max-width: 640px) {
  .fig-block { padding: 32px 22px; border-radius: 18px; }
  .fig-feats { grid-template-columns: 1fr; }
  .fig-search input { padding: 13px 18px; }
}

/* ── 햄버거 버튼 ── */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px; height: 40px;
  background: none; border: none; cursor: pointer; padding: 4px;
  flex-shrink: 0;
}
.nav-toggle span {
  display: block; height: 2px; width: 22px; background: #0a0a0a; border-radius: 2px;
  transition: transform 0.2s, opacity 0.2s;
  transform-origin: center;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.pagination-top { margin-bottom: 12px; }

@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .header-inner { flex-wrap: wrap; height: auto; padding: 12px 0; align-items: center; }
  .header-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    padding: 6px 0 14px;
    border-top: 1px solid var(--fig-hairline);
    gap: 0;
    margin-top: 4px;
  }
  .header-nav.open { display: flex; }
  .header-nav a {
    padding: 11px 12px;
    font-size: 15px;
    border-radius: 12px;
    display: block;
    color: #0a0a0a;
  }
  .header-nav .nav-signup {
    margin-left: 0;
    margin-top: 8px;
    text-align: center;
    background: #0a0a0a; color: #fff;
  }
  .logout-form { width: 100%; }
  .logout-form button {
    display: block;
    width: 100%;
    text-align: left;
    background: none; border: none; cursor: pointer;
    padding: 11px 12px;
    border-radius: 12px;
    font-size: 15px;
    color: #0a0a0a; font-weight: 460;
  }
  .logout-form button:hover { background: var(--fig-surface); }
}

/* ── 모바일 중앙 정렬 ── */
@media (max-width: 768px) {
  /* 에디토리얼 컬러 블록 */
  .fig-block { text-align: center; }
  .fig-block p { margin-left: auto; margin-right: auto; }

  /* 섹션 구분 헤더 ("현재 지원 가능한 공고" 등) */
  .fig-sec-head { flex-direction: column; align-items: center; text-align: center; gap: 6px; margin: 40px 0 14px; }

  /* 공고 결과 수 */
  .result-count { text-align: center; }

  /* 각 페이지 헤드 (커뮤니티·이력서 등) */
  .page-head { flex-direction: column; align-items: center; text-align: center; }

  /* 푸터 */
  .footer-brand, .footer-desc, .footer-copy { text-align: center; }
  .footer-hubs { justify-content: center; }
  .footer-hub-group { text-align: center; }
  .footer-hub-group ul { justify-content: center; }
  .footer-legal { justify-content: center; }
}

/* ── 법적 페이지 ── */
.legal { max-width: 760px; margin: 0 auto; }
.legal h1 { font-size: 28px; font-weight: 800; margin-bottom: 16px; letter-spacing: -0.02em; }
.legal-intro { color: #475569; margin-bottom: 22px; line-height: 1.7; }
.legal h2 { font-size: 17px; font-weight: 700; margin: 26px 0 10px; }
.legal p { line-height: 1.75; color: #334155; margin-bottom: 8px; }
.legal ul { margin: 8px 0 10px 20px; }
.legal li { line-height: 1.7; color: #334155; margin-bottom: 4px; }
.legal b { color: #0a0a0a; }
.legal-date { margin-top: 28px; font-weight: 700; color: #0a0a0a; }
.legal-note { margin-top: 12px; padding: 14px 16px; background: var(--fig-surface); border-radius: 10px; font-size: 13px; color: #64748b; line-height: 1.6; }

/* ── 푸터 법적 링크 ── */
.footer-legal { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 18px; padding-top: 16px; border-top: 1px solid #334155; }
.footer-legal a { color: #cbd5e1; font-size: 13px; }
.footer-legal a:hover { color: #fff; }

/* ── 사업비 (나라장터 G2B 연계) ── */
.budget-cell { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 12px; }
.budget-amount { font-size: 18px; font-weight: 800; color: #0f766e; letter-spacing: -0.01em; }
.g2b-link { font-size: 12px; font-weight: 600; color: #2563eb; white-space: nowrap; }
.g2b-link:hover { text-decoration: underline; }
.budget-hint { flex-basis: 100%; font-size: 11px; color: #94a3b8; }
.side-budget { font-weight: 800; color: #0f766e; }
.card-budget { font-weight: 700; color: #0f766e; }

/* ── 마이페이지: 관심공고 다가오는 평가일정 ── */
.mp-sec-sub { font-size: 12px; font-weight: 500; color: #94a3b8; margin-left: 6px; }
.mp-eval-list { list-style: none; margin: 0 0 10px; padding: 0; }
.mp-eval-row { display: flex; align-items: center; gap: 12px; padding: 10px 2px; border-bottom: 1px solid var(--fig-hairline); }
.mp-eval-cal { flex: 0 0 auto; width: 54px; text-align: center; background: var(--fig-mint); border-radius: 10px; padding: 6px 0; line-height: 1.15; }
.mp-eval-cal b { display: block; font-size: 16px; font-weight: 800; color: #0f5132; }
.mp-eval-cal span { font-size: 11px; color: #2f6b4a; }
.mp-eval-body { flex: 1 1 auto; display: flex; flex-direction: column; min-width: 0; }
.mp-eval-title { font-weight: 600; color: #0a0a0a; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mp-eval-agency { font-size: 12px; color: #64748b; }
.mp-eval-dday { flex: 0 0 auto; font-size: 12px; font-weight: 700; color: #fff; background: #0a0a0a; padding: 4px 11px; border-radius: 9999px; white-space: nowrap; }
.mp-eval-dday.today { background: #e01e5a; }
.card-foot .eval-date { color: #0f766e; }
.footer-copy { margin-top: 12px; font-size: 12px; color: #94a3b8; }
.footer-legal { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 10px; }
.footer-legal a { font-size: 12px; color: #94a3b8; text-decoration: none; }
.footer-legal a:hover { color: #fff; }

/* ── 법적 페이지 ── */
article.legal { max-width: 760px; margin: 40px auto; }
article.legal h1 { font-size: 24px; font-weight: 800; margin-bottom: 6px; }
article.legal h2 { font-size: 16px; font-weight: 700; margin: 28px 0 8px; border-bottom: 1px solid #e2e8f0; padding-bottom: 4px; }
article.legal p, article.legal li { font-size: 14px; line-height: 1.7; color: #334155; }
article.legal ul { padding-left: 20px; margin: 8px 0; }
article.legal li { margin-bottom: 4px; }
.legal-date { font-size: 13px; color: #64748b; margin: 0 0 24px; }
.legal-note { font-size: 12px; color: #94a3b8; margin-top: 24px; border-top: 1px solid #e2e8f0; padding-top: 12px; }

/* ── 마감일 미확인 표시 (신뢰: 정직하게 원문 확인 유도) ── */
.deadline-na { color: #b45309; font-weight: 600; }
.card-foot .deadline-na { font-size: 12.5px; }
.side-dday.na { background: #fffbeb; color: #b45309; font-size: 17px; }

/* =======================================================================
   전역 Figma 통일 — style.css 의 옛 톤(민트/슬레이트)을 흑백+파스텔로 덮어씀
   ======================================================================= */
:root {
  --primary: #111111;
  --primary-dark: #0a0a0a000;
  --featured: #111111;
  --bg: #ffffff;
  --card-bg: #ffffff;
  --text: #111111;
  --text-muted: #6b7280;
  --border: #e6e6e6;
  --dark: #1f1d3d;
}
body { background: #ffffff; color: #111111; }

/* 카드·컨테이너: hairline + 둥근모서리, 그림자 최소화 */
.notice-card, .resume-card, .cm-post, .cm-comments, .side-box, .mp-card, .mp-side,
.mp-stat, .rf-section, .detail-main, .auth-box, .alert-form, .empty-state-box,
.faq-item, .chk-filter, .ai-cta, .ai-steps li, .cm-write { border-radius: 16px; }
.notice-card { transition: box-shadow .15s, border-color .15s; }
.notice-card:hover { transform: none; box-shadow: 0 6px 22px rgba(0,0,0,.06); border-color: #111; }
.notice-card.is-featured { border-color: #111; }

/* 태그 → 파스텔 칩 (전역) */
.tag-region { background: #ece6ff; color: #3a2e7a; }
.tag-committee { background: #c8e6cd; color: #14532d; }
.tag-category { background: #f4ecd6; color: #6b5a1e; }
.tag-more { background: #f1f1f1; color: #555; }
.cm-notice { background: #f4ecd6; color: #6b5a1e; }
.cm-free { background: #ece6ff; color: #3a2e7a; }
.cm-qna { background: #c8e6cd; color: #14532d; }
.badge-default { background: #c8e6cd; color: #14532d; }
.label-new { background: #111; color: #fff; }
.label-bookmarked { background: #f4ecd6; color: #6b5a1e; }

/* D-day 배지 → 모노 + 마젠타(긴급) */
.dday-badge { border-radius: 9999px; }
.dday-badge.open { background: #f7f7f5; color: #111; border: 1px solid #e6e6e6; }
.dday-badge.soon { background: #ffe9f0; color: #d6005a; border: 1px solid #ffc6da; }
.dday-badge.closed { background: #f1f1f1; color: #999; border: 1px solid #e6e6e6; }

/* 나라장터 입찰기반(평가위원 모집 예정) — 실제 모집과 구분되는 민트 계열 */
.label-proc { background: #0f766e; color: #fff; }
.fig-sec-links { display: inline-flex; gap: 14px; align-items: baseline; flex-wrap: wrap; }
.fig-sec-links .link-proc { color: #0f766e; border-bottom-color: #0f766e; }
.proc-note { margin: -6px 0 16px; font-size: 14.5px; color: #444; background: #f0faf7;
  border-left: 3px solid #0f766e; padding: 10px 13px; border-radius: 7px; line-height: 1.55; }

/* 허브 hero → 라이트 Figma 패널 */
.hero { background: #f7f7f5; color: #111; border-radius: 24px; }
.hero h1, .hero h1 span { color: #111; }
.hero > p { color: #555; }
.hero-search input { border: 1.5px solid #111; border-radius: 9999px 0 0 9999px; }
.hero-search button { background: #111; border-radius: 0 9999px 9999px 0; }
.hero-search button:hover { background: #2a2a2a; }

/* 버튼·칩 → pill 통일 */
.btn-sm, .btn-outline, .btn-list, .cm-like, .filter-reset, .mp-link, .chk, .cm-tab,
.btn-bookmark, .btn-add, .btn-share, .cm-search button, .cm-search input { border-radius: 9999px; }
.btn-bookmark { border-color: #111; color: #111; }
.btn-bookmark.active { background: #111; color: #fff; }
.btn-bookmark.active:hover { background: #2a2a2a; }
.cm-like.on { background: #111; color: #fff; border-color: #111; }
.chk.on { background: #111; color: #fff; border-color: #111; }
.cm-tab.on { color: #111; border-bottom-color: #111; }
.mp-nav a.on { background: #f7f7f5; color: #111; }
.btn-outline { border-color: #111; color: #111; }
.btn-outline:hover { background: #111; color: #fff; }
.cm-search button { background: #111; }
.result-count strong, .cm-cc { color: #111; }

/* 입력 포커스 = 검정 링 */
.cm-search input:focus, .hero-search input:focus { border-color: #111; }
input:focus, select:focus, textarea:focus { box-shadow: 0 0 0 3px rgba(0,0,0,.07); }

/* 푸터 → 네이비 inverse */
.site-footer { background: #1f1d3d; }
