/* ==========================================================
   core/layout.css — 페이지 뼈대
   .wrap(최대 폭) · .section(세로 간격) · .sec-head(섹션 제목) · .crumb(경로)
   · .page-hero(하위 페이지 공통 상단) · .filter-bar(필터 한 줄) · .grid 도우미
   ========================================================== */

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.wrap-narrow { max-width: 780px; }

.section { position: relative; padding: 36px 0; }
.section.section-top { padding-top: 20px; }
.section-tint { background: var(--surface-2); }

/* ---------- 섹션 제목 ---------- */
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.sec-head > div:first-child { min-width: 0; }
.sec-eyebrow { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 6px; font-size: 13px; font-weight: 700; color: var(--brand-deep); }
.sec-title { font-size: 21px; font-weight: 800; line-height: 1.3; letter-spacing: -.035em; }
.sec-desc { margin-top: 5px; font-size: 14px; color: var(--ink-3); }

/* ---------- 브레드크럼 ---------- */
.crumb { display: flex; align-items: center; flex-wrap: wrap; gap: 2px; font-size: 13px; font-weight: 600; color: var(--ink-3); }
.crumb a { display: inline-flex; align-items: center; min-height: 28px; }
.crumb a:hover { color: var(--ink); }
.crumb .ico { width: 14px; height: 14px; color: var(--ink-4); }

/* ---------- 하위 페이지 공통 상단 ---------- */
.page-hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(640px 300px at 92% -20%, #DDF5EA 0%, rgba(221, 245, 234, 0) 64%),
    linear-gradient(180deg, var(--mint) 0%, #fff 100%);
  border-bottom: 1px solid var(--line-2);
}
.page-hero-inner { position: relative; padding-top: 18px; padding-bottom: 24px; }
.page-hero h1 { margin-top: 10px; font-size: 26px; font-weight: 800; line-height: 1.28; letter-spacing: -.045em; }
.page-hero h1 em { font-style: normal; color: var(--brand-deep); }
.page-hero-desc { margin-top: 8px; font-size: 15px; color: var(--ink-2); max-width: 40em; }
.page-hero .basis { margin-top: 12px; }
.page-hero-row { display: flex; align-items: center; gap: 12px; }
.page-hero-row .ctile { width: 48px; height: 48px; border-radius: 15px; }
.page-hero-row .ctile .ico { width: 24px; height: 24px; }
.page-hero-row h1 { margin-top: 0; }

/* ---------- 필터 한 줄: 한 페이지의 모든 차트·목록을 함께 바꾼다 ---------- */
.filter-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px;
  padding: 12px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line);
  box-shadow: var(--shadow-1);
}
.filter-bar .grow { flex: 1 1 auto; min-width: 0; }
.filter-group { display: flex; align-items: center; gap: 8px; min-width: 0; }
.filter-label { flex: none; font-size: 13px; font-weight: 700; color: var(--ink-3); }
.filter-sticky { position: sticky; top: calc(var(--hdr-h) + var(--nav-h) + 8px); z-index: 20; }

/* ---------- 그리드 도우미 ---------- */
.grid-2 { display: grid; gap: 16px; }
.stack-16 > * + * { margin-top: 16px; }
.stack-24 > * + * { margin-top: 24px; }

@media (min-width: 768px) {
  .wrap { padding: 0 24px; }
  .sec-title { font-size: 26px; }
  .sec-desc { font-size: 15px; }
  .page-hero-inner { padding-top: 26px; padding-bottom: 34px; }
  .page-hero h1 { font-size: 36px; }
  .page-hero-desc { font-size: 16px; }
  .page-hero-row .ctile { width: 58px; height: 58px; border-radius: 18px; }
  .page-hero-row .ctile .ico { width: 28px; height: 28px; }
}
@media (min-width: 900px) {
  .grid-2 { grid-template-columns: 1fr 1fr; gap: 20px; }
}
@media (min-width: 1024px) {
  .section { padding: 52px 0; }
}
