/* 2026 더아트프라자 현장 리플렛(1008) 색. 흰 바탕·검정 글자가 주인,
   프로그램 색은 띠·면으로만(글자색으로 쓰면 안 읽힘). 모서리 0, 그림자 없음. */
:root {
  --red: #B82E29;
  --bg: #FFFFFF; --ink: #1A1A1A; --muted: #767676; --line: #E2E2E2;
  /* 리플렛 프로그램 면 색 (강연·워크숍·공연·마켓), 도슨트는 리플렛 1쪽 이름표 색 */
  --c-talk: #53C6D3; --c-make: #F17EB1; --c-tour: #01C1F3; --c-wave: #896EB1; --c-shop: #F89D5B;
  --accent: #1A1A1A;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: "Pretendard Variable", Pretendard, -apple-system, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  font-size: 16px; line-height: 1.55; word-break: keep-all;
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
.wrap { max-width: 720px; margin: 0 auto; padding: 0 16px; }
[hidden] { display: none !important; }

/* 머리 — KV의 8색 사선 띠 */
.stripes { display: flex; height: 8px; }
.stripes i { flex: 1; }
.stripes i:nth-child(1) { background: var(--c-talk); }
.stripes i:nth-child(2) { background: var(--c-make); }
.stripes i:nth-child(3) { background: var(--c-wave); }
.stripes i:nth-child(4) { background: var(--c-shop); }
.top { border-bottom: 1px solid var(--ink); overflow: hidden; }
.top-in { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 14px; padding-bottom: 14px; }
.brand { text-decoration: none; color: var(--ink); display: flex; flex-direction: column; line-height: 1.1; }
.brand-en { font-weight: 800; letter-spacing: -0.02em; font-size: 18px; }
.brand-sub { font-size: 12px; font-weight: 600; color: var(--accent); margin-top: 3px; letter-spacing: 0.04em; }
.link-btn { background: none; border: 1px solid var(--ink); padding: 8px 12px; font-size: 14px; font-weight: 600; white-space: nowrap; }

.intro { padding: 20px 0 20px; }
.intro .kv { display: block; width: 100%; height: auto; margin-bottom: 24px; }
.intro { text-align: center; }
.intro h1 { margin-bottom: 8px; }
.intro .cat-lead { margin: 0; font-size: 16px; }
h1 { font-size: 28px; line-height: 1.25; margin: 0 0 6px; letter-spacing: -0.02em; }
.meta { margin: 0; color: var(--muted); font-size: 14px; }

/* 종류 탭 */
.tabs { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--ink); gap: 1px; background: var(--ink); }
.tabs button {
  background: var(--bg); border: 0; padding: 12px 4px 10px;
  display: flex; flex-direction: column; align-items: center; gap: 1px; position: relative;
}
.tabs b { font-size: 16px; }
.tabs span { font-size: 11px; letter-spacing: 0.12em; color: var(--muted); font-weight: 600; }
.tabs button[aria-selected="true"] span { color: var(--ink); }
.tabs button[data-cat="강연"][aria-selected="true"] { background: var(--c-talk); }
.tabs button[data-cat="워크숍"][aria-selected="true"] { background: var(--c-make); }
.tabs button[data-cat="도슨트"][aria-selected="true"] { background: var(--c-tour); }
.tabs button::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; }
.tabs button[data-cat="강연"]::before { background: var(--c-talk); }
.tabs button[data-cat="워크숍"]::before { background: var(--c-make); }
.tabs button[data-cat="도슨트"]::before { background: var(--c-tour); }

.cat-lead { color: var(--ink); }
.tabs + .cards { margin-top: 20px; }
.days { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; margin: 0 -16px 8px; padding-left: 16px; padding-right: 16px; scrollbar-width: none; }
.days::-webkit-scrollbar { display: none; }
.days button {
  flex: 0 0 auto; background: var(--bg); border: 1px solid var(--line); padding: 7px 12px; font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.days button[aria-pressed="true"] { border-color: var(--ink); background: var(--ink); color: #fff; font-weight: 600; }

/* 회차 카드 — 색은 위 띠에만 */
.cards { display: grid; gap: 12px; margin-top: 8px; }
.day-head { margin: 18px 0 2px; font-size: 14px; font-weight: 700; color: var(--accent); font-variant-numeric: tabular-nums; }
.card { border: 1px solid var(--line); border-top: 5px solid var(--c); background: var(--bg); display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 16px; }
.card[data-cat="강연"] { --c: var(--c-talk); }
.card[data-cat="워크숍"] { --c: var(--c-make); }
.card[data-cat="도슨트"] { --c: var(--c-tour); }
.card.has-photo { grid-template-columns: 84px 1fr; }
.card.has-photo .photo { margin: -4px 0 0; }
.photo { grid-row: span 3; width: 84px; height: 104px; background: #fff; border-bottom: 3px solid var(--c); object-fit: cover; display: block; }
.photo.blank { display: flex; align-items: flex-end; padding: 6px; font-size: 11px; color: var(--muted); }
.card .when { font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }
.card .title { font-size: 18px; font-weight: 800; line-height: 1.35; margin: 4px 0 0; }
.card .host { font-size: 16px; font-weight: 400; color: var(--ink); margin-top: 4px; }
.card .place { font-size: 13px; color: var(--muted); }
.card .bottom { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.seats { font-size: 14px; font-variant-numeric: tabular-nums; }
.seats b { color: var(--accent); }
.seats.low b { color: var(--red); }
.seats.wait { font-weight: 600; }
.apply-btn { background: var(--ink); color: #fff; border: 0; padding: 10px 18px; font-weight: 700; font-size: 15px; min-width: 104px; }
.apply-btn.wait { background: var(--bg); color: var(--ink); border: 1px solid var(--ink); }
.apply-btn:disabled { background: var(--line); color: var(--muted); cursor: default; }

.note { color: var(--muted); font-size: 13px; margin: 20px 0 40px; padding: 0; list-style: none; }
.note li { margin-bottom: 4px; }
.empty { padding: 32px 0; color: var(--muted); text-align: center; }

/* 신청서 */
.back { background: none; border: 0; padding: 20px 0 8px; color: var(--muted); font-size: 14px; }
.picked { border: 1px solid var(--line); border-top: 5px solid var(--c); padding: 16px; margin: 8px 0 24px; }
.picked .cat { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; background: var(--c); color: var(--ink); }
.picked .title { font-size: 19px; font-weight: 700; margin: 4px 0; line-height: 1.35; }
.picked p { margin: 0; font-size: 14px; }
form label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 16px; }
form input:not([type="checkbox"]) {
  display: block; width: 100%; margin-top: 6px; padding: 12px; border: 1px solid #BDBDBD; border-radius: 0;
  font-size: 17px; background: var(--bg); -webkit-appearance: none; appearance: none;
}
form input:focus { outline: 2px solid var(--accent); outline-offset: -1px; border-color: var(--accent); }
form small { display: block; font-weight: 400; color: var(--muted); margin-top: 6px; font-size: 13px; }
.agree { border: 1px solid var(--line); margin: 4px 0 16px; }
.agree .all { padding: 14px; border-bottom: 1px solid var(--line); background: #F7F7F7; }
.agree-item { padding: 12px 14px; border-bottom: 1px solid var(--line); }
.agree-item:last-child { border-bottom: 0; }
.agree-item .check { font-weight: 500; }
details p { margin: 8px 0 0; }
details li { margin-bottom: 4px; }
details li b { color: var(--ink); margin-right: 4px; }
.check { display: flex !important; gap: 10px; align-items: flex-start; margin: 0 !important; font-weight: 600; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--accent); flex: 0 0 auto; }
details { margin-top: 10px; font-size: 13px; color: var(--muted); }
details summary { cursor: pointer; }
details ul { padding-left: 18px; margin: 8px 0 0; }
.err { color: var(--red); font-size: 14px; font-weight: 600; min-height: 1em; margin: 0 0 12px; }
.primary { display: block; width: 100%; background: var(--accent); color: #fff; border: 0; padding: 16px; font-size: 17px; font-weight: 700; }
.primary:disabled { opacity: .5; }
.ghost { display: block; width: 100%; background: var(--bg); border: 1px solid var(--ink); padding: 14px; font-size: 16px; font-weight: 600; margin-top: 10px; }

/* 완료 */
.done { padding: 36px 0 24px; }
.done .badge { display: inline-block; background: var(--accent); color: #fff; font-weight: 700; padding: 4px 10px; font-size: 14px; }
.done .badge.wait { background: var(--c-make); color: var(--ink); }
.done h1 { margin-top: 14px; }
.done .summary { border-top: 1px solid var(--ink); margin-top: 22px; padding-top: 14px; }
.done .summary p { margin: 2px 0; }
.done .hint { color: var(--muted); font-size: 14px; margin-top: 16px; }

/* 내 신청 */
.mine { margin: 28px 0 40px; display: grid; gap: 12px; }
.mine .card { grid-template-columns: 1fr; }
.status { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; background: var(--accent); color: #fff; margin-right: 6px; vertical-align: 2px; }
.status.wait { background: var(--c-make); color: var(--ink); }
.cancel-btn { background: var(--bg); border: 1px solid var(--red); color: var(--red); padding: 9px 14px; font-weight: 700; font-size: 14px; }
.confirm-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.confirm-row span { font-size: 14px; font-weight: 600; }
.confirm-row .yes { background: var(--red); color: #fff; border: 0; padding: 9px 14px; font-weight: 700; font-size: 14px; }
.confirm-row .no { background: none; border: 1px solid var(--line); padding: 9px 14px; font-size: 14px; }

.foot { border-top: 1px solid var(--line); padding: 20px 0 40px; font-size: 13px; text-align: center; }
.foot p { margin: 0 0 4px; }
.muted { color: var(--muted); }

@media (min-width: 640px) {
  h1 { font-size: 34px; }
  .intro { padding-top: 44px; }
  .brand-en { font-size: 20px; }
}

/* 워크숍·도슨트 — 프로그램 하나에 회차를 고르는 칸 */
.prog { border: 1px solid var(--line); border-top: 5px solid var(--c); background: var(--bg); }
.prog[data-cat="워크숍"] { --c: var(--c-make); }
.prog[data-cat="도슨트"] { --c: var(--c-tour); }
.prog-img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; background: #f2f2f2; }
.prog-body { padding: 16px; }
.host-tag { display: inline-block; background: var(--c); color: var(--ink); font-weight: 700; font-size: 13px; padding: 2px 8px; }
.prog-title { font-size: 21px; line-height: 1.3; margin: 8px 0 6px; letter-spacing: -0.01em; }
.prog-desc { margin: 0 0 6px; font-size: 15px; }
.prog .place { margin: 0 0 14px; font-size: 13px; color: var(--muted); }
.slots { border-top: 1px solid var(--ink); }
.slot-row { display: grid; grid-template-columns: 1fr; gap: 6px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.slot-day { font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }
.slot-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.slot {
  display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 0; padding: 7px 4px;
  background: var(--bg); border: 1px solid var(--ink); line-height: 1.2; font-variant-numeric: tabular-nums;
}
.slot b { font-size: 14px; white-space: nowrap; letter-spacing: -0.02em; }
.slot small { font-size: 11px; color: var(--muted); margin-top: 2px; }
.slot small.low { color: var(--red); font-weight: 700; }
.slot.wait { border-style: dashed; }
.slot[aria-pressed="true"] { background: var(--c); border-color: var(--ink); border-width: 2px; padding: 5px 9px; }
.slot[aria-pressed="true"] small { color: var(--ink); }
.slot:disabled { border-color: var(--line); color: #BDBDBD; cursor: default; }
.slot:disabled small { color: #BDBDBD; }
.apply-btn.block { display: block; width: 100%; margin-top: 14px; padding: 14px; }
/* 하루 한 회차(워크숍)는 날짜 옆에 회차 칸 */
.slots.single .slot-row { grid-template-columns: 84px minmax(0, 150px); align-items: center; gap: 8px; }
.slots.single .slot-list { grid-template-columns: 1fr; }

.contact { font-size: 14px; color: var(--ink); margin-bottom: 10px !important; line-height: 1.6; }
.contact a { color: var(--ink); font-weight: 700; }
.cal { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.cal a { display: block; text-align: center; text-decoration: none; color: var(--ink); border: 1px solid var(--ink); padding: 11px 4px; font-size: 14px; font-weight: 600; }
.mine .cal { margin-top: 10px; }

/* 네이버·구글 검색으로 들어온 경우 (10/21 10:00 전) */
.blocked-note { display: none; padding: 64px 0; text-align: center; }
.blocked-note h1 { font-size: 22px; margin: 0 0 12px; }
.blocked-note p { color: var(--muted); line-height: 1.6; margin: 0; }
html.blocked .blocked-note { display: block; }
html.blocked main, html.blocked .top .link-btn, html.blocked footer { display: none !important; }

/* 안내 문자 링크(/c/열쇠) — 시간 변경 안내 + 참석 확정 */
#view-notice h1 { margin-top: 28px; }
#view-notice > .hint { color: var(--ink); font-size: 15px; line-height: 1.6; }
.was { color: var(--muted); text-decoration: line-through; margin-right: 6px; font-weight: 400; }
.changed { color: var(--red); font-size: 12px; font-weight: 700; margin-left: 6px; }
.attend-btn { background: var(--accent); color: #fff; border: 0; padding: 11px 18px; font-weight: 700; font-size: 15px; }
.attended { font-weight: 700; font-size: 14px; }
.cal-note { color: var(--muted); font-size: 13px; margin: 8px 0 0; }
#view-notice > .hint { margin: 8px 0; }
.notice-info { margin: 4px 0 12px; padding-left: 22px; font-size: 16px; line-height: 1.6; }
.notice-info li { margin: 4px 0; }
