/* 행사 기록 전체 페이지 (v6, 평면 기업형) */

/* 상단 파란 띠 */
.sub-hero { background: linear-gradient(115deg, #2f63ff, #2a5bf5 45%, #2149dc); color: #fff; border-radius: 0 0 72px 0; padding: 44px 0 104px; }
.crumb { display: flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 550; color: rgba(255,255,255,.72); }
.crumb a:hover { color: #fff; }
.crumb svg { width: 12px; height: 12px; }
.crumb span { color: #fff; }
.sub-hero h1 { margin-top: 18px; font-size: clamp(30px, 3.6vw, 46px); font-weight: 780; letter-spacing: -.045em; line-height: 1.2; }
.sub-hero h1 em { font-style: normal; font-variant-numeric: tabular-nums; }
.sub-hero .lead { margin-top: 12px; max-width: 36em; font-size: 16.5px; line-height: 1.65; color: rgba(255,255,255,.86); }

/* 찾기 판 */
.arc { padding-bottom: 100px; }
.panel { position: relative; margin-top: -64px; background: #fff; border-radius: 20px; padding: 24px 28px 22px; display: grid; gap: 20px; box-shadow: 0 18px 40px -24px rgba(16,32,74,.35), 0 0 0 1px rgba(16,32,74,.05); }
.p-t { font-size: 15px; font-weight: 700; color: var(--ink); margin-bottom: 14px; }
.years { position: relative; }
.panel > * { min-width: 0; }
.bars { display: grid; grid-template-columns: repeat(var(--n, 13), 1fr); align-items: end; height: 110px; border-bottom: 1px solid var(--line); }
.bar { position: relative; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; cursor: pointer; padding: 0; }
.bar i { display: block; width: min(26px, 62%); height: var(--h); min-height: 2px; background: #c9d7fd; border-radius: 4px 4px 0 0; transition: background .2s, height .5s var(--ease); }
.bar:hover i, .bar:focus-visible i { background: #86a5fb; }
.bar.on i { background: var(--blue); }
.bar.zero { cursor: default; }
.bar.zero i { background: #edf0f4; }
.bar .v { position: absolute; bottom: calc(var(--h) + 6px); font-size: 12px; font-weight: 700; color: var(--ink-2); font-variant-numeric: tabular-nums; opacity: 0; transition: opacity .2s; }
.bar.on .v, .bar.max .v { opacity: 1; }
.bar:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 6px; }
.ylabels { display: grid; grid-template-columns: repeat(var(--n, 13), 1fr); margin-top: 8px; }
.ylabels span { text-align: center; font-size: 12.5px; font-weight: 600; color: var(--mute); font-variant-numeric: tabular-nums; }
.ylabels span.on { color: var(--blue); font-weight: 750; }
.ylabels i { font-style: normal; }
.ylabels .mo { display: none; }
.tip { position: absolute; left: 0; top: 0; transform: translate(-50%, calc(-100% - 8px)); padding: 6px 10px; border-radius: 8px; background: var(--ink); color: #fff; font-size: 13px; white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity .15s; }
.tip b { font-weight: 750; margin-right: 4px; }
.tip.show { opacity: 1; }

.tools { display: flex; justify-content: space-between; align-items: center; gap: 12px 20px; flex-wrap: wrap; padding-top: 18px; border-top: 1px solid var(--line); }
.cats { display: flex; flex-wrap: wrap; gap: 6px; }
.cats button { height: 40px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--line); background: #fff; font-size: 14.5px; font-weight: 650; color: var(--ink-2); transition: background .2s, color .2s, border-color .2s; }
.cats button:hover { border-color: #b9c9f5; color: var(--blue); }
.cats button.on { background: var(--blue); border-color: var(--blue); color: #fff; }
.cats button small { margin-left: 5px; font-size: 12.5px; font-weight: 600; opacity: .65; font-variant-numeric: tabular-nums; }
.search { flex: 1; min-width: 240px; max-width: 380px; }
.search input { width: 100%; height: 44px; border-radius: 10px; border: 1px solid var(--line); background: var(--gray); padding: 0 16px 0 42px; font-size: 15px; font-weight: 550; outline: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%238f97a5' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: 15px center; transition: border-color .2s, background-color .2s; }
.search input:focus { border-color: var(--blue); background-color: #fff; }

/* 사진 격자 */
.count { margin: 34px 0 16px; font-size: 15px; font-weight: 600; color: var(--sub); }
.count b { color: var(--blue); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 28px 18px; }
.grid li { content-visibility: auto; contain-intrinsic-size: 190px 270px; }
.grid li.off { display: none; }
.card { display: block; width: 100%; text-align: left; padding: 0; background: none; }
.card:focus-visible { outline: 2px solid var(--blue); outline-offset: 4px; border-radius: 12px; }
.ph { position: relative; display: block; aspect-ratio: 1; overflow: hidden; border-radius: 12px; background: var(--gray); }
.ph img { width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .4s, transform .6s var(--ease); }
.ph img.ok { opacity: 1; }
.card:hover .ph img.ok { transform: scale(1.05); }
.ph .wait { position: absolute; inset: 0; display: grid; place-content: center; gap: 8px; text-align: center; padding: 12px; font-size: 12.5px; font-weight: 600; color: var(--mute); }
.ph .wait img { width: 30px; height: auto; margin: 0 auto; opacity: .4; filter: grayscale(1); }
.ph img.ok + .wait { display: none; }
.cap { display: block; padding: 12px 2px 0; }
.cap b { font-size: 15px; font-weight: 700; letter-spacing: -.03em; line-height: 1.4; color: var(--ink); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; min-height: 2.8em; transition: color .2s; }
.card:hover .cap b { color: var(--blue); }
.cap > span { display: block; margin-top: 5px; font-size: 13px; color: var(--mute); font-variant-numeric: tabular-nums; }
.empty { margin-top: 40px; padding: 48px 0; text-align: center; color: var(--sub); background: var(--gray); border-radius: 16px; }

/* 크게 보기 */
.lb { position: fixed; inset: 0; z-index: 80; display: grid; grid-template-columns: 56px minmax(0, 620px) 56px; justify-content: center; align-items: center; gap: 20px; padding: 24px; background: rgba(12,20,40,.86); }
.lb[hidden] { display: none; }
.lb-print { background: #fff; border-radius: 16px; overflow: hidden; }
.lb-print img { width: 100%; aspect-ratio: 1; max-height: 70vh; object-fit: cover; background: var(--gray); }
.lb-print figcaption { padding: 16px 20px 18px; }
.lb-print b { display: block; font-size: 18px; font-weight: 750; letter-spacing: -.03em; }
.lb-print span { display: block; margin-top: 4px; font-size: 14px; color: var(--mute); }
.lb-nav, .lb-x { width: 52px; height: 52px; border-radius: 50%; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.3); position: relative; transition: background .2s; }
.lb-nav::before, .lb-x::before, .lb-x::after { content: ""; position: absolute; left: 50%; top: 50%; }
.lb-nav::before { width: 11px; height: 11px; border-left: 2.5px solid #fff; border-bottom: 2.5px solid #fff; }
.lb-prev::before { transform: translate(-30%, -50%) rotate(45deg); }
.lb-next::before { transform: translate(-70%, -50%) rotate(-135deg); }
.lb-x { position: absolute; top: 20px; right: 20px; width: 48px; height: 48px; }
.lb-x::before, .lb-x::after { width: 18px; height: 2.5px; background: #fff; border-radius: 2px; transform: translate(-50%, -50%) rotate(45deg); }
.lb-x::after { transform: translate(-50%, -50%) rotate(-45deg); }
.lb-nav:hover, .lb-x:hover { background: rgba(255,255,255,.24); }
.lb-n { position: absolute; left: 0; right: 0; bottom: 22px; text-align: center; font-size: 14px; font-weight: 650; color: rgba(255,255,255,.75); font-variant-numeric: tabular-nums; }

@media (max-width: 640px) {
  .sub-hero { border-radius: 0 0 40px 0; padding: 28px 0 84px; }
  .sub-hero .lead { font-size: 15px; }
  .panel { margin-top: -52px; padding: 18px 16px 16px; border-radius: 16px; gap: 16px; }
  .bars { height: 84px; }
  .ylabels .pc { display: none; }
  .ylabels .mo { display: inline; }
  .ylabels span { font-size: 11px; letter-spacing: -.04em; }
  .tools { padding-top: 14px; }
  .cats { flex: 1 1 100%; min-width: 0; flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 0 16px; scrollbar-width: none; }
  .cats::-webkit-scrollbar { display: none; }
  .cats button { flex: none; height: 38px; padding: 0 14px; font-size: 14px; }
  .search { max-width: none; min-width: 0; flex-basis: 100%; }
  .count { margin-top: 26px; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 22px 12px; }
  .grid li { contain-intrinsic-size: 160px 240px; }
  .cap b { font-size: 14px; }
  .lb { grid-template-columns: 1fr; padding: 76px 16px 96px; }
  .lb-nav { position: absolute; bottom: 20px; width: 50px; height: 50px; }
  .lb-prev { left: 18px; } .lb-next { right: 18px; }
  .lb-n { bottom: 36px; }
}
