:root {
  --red: #fa2828;
  --red-d: #d81e1e;
  --ink: #191919;
  --sub: #6b6b6b;
  --line: #ececec;
  --bg: #f6f6f6;
  --paper: #fff;
  --sz: 26px;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: Pretendard, "Apple SD Gothic Neo", sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 15px;
  line-height: 1.5;
}
button, input, select, textarea { font-family: inherit; color: inherit; }
a { color: inherit; }
img { max-width: 100%; display: block; }
#prog {
  position: fixed; left: 0; top: 0; height: 3px; width: 0; background: var(--red); z-index: 80;
}
body.busy #prog { width: 68%; transition: width .35s ease; }
#toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(12px);
  background: #111; color: #fff; padding: 12px 16px; border-radius: 4px;
  opacity: 0; pointer-events: none; z-index: 90; max-width: min(440px, calc(100% - 32px));
  font-size: 14px; transition: .2s ease;
}
#toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }

.topline { height: 3px; background: var(--red); }
.header {
  position: sticky; top: 0; z-index: 30; background: #fff; border-bottom: 1px solid var(--line);
}
.header .in, .cats .in, .wrap {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}
.header .in { height: 64px; display: flex; align-items: center; gap: 18px; }
.logo { display: flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 800; font-size: 20px; letter-spacing: -0.03em; }
.logo i {
  width: 28px; height: 28px; border-radius: 4px; background: var(--red); color: #fff;
  display: grid; place-items: center; font-style: normal; font-size: 16px;
}
.search { flex: 1; display: flex; max-width: 520px; }
.search input {
  flex: 1; height: 40px; border: 1px solid #e3e3e3; border-right: 0; background: #fafafa;
  padding: 0 12px; border-radius: 2px 0 0 2px; outline: none;
}
.search button {
  height: 40px; padding: 0 14px; border: 0; background: var(--ink); color: #fff; cursor: pointer; border-radius: 0 2px 2px 0;
}
.hlinks { margin-left: auto; display: flex; gap: 16px; align-items: center; }
.hlinks a { text-decoration: none; font-size: 14px; color: #333; }
.cats { position: sticky; top: 64px; z-index: 25; background: #fff; border-bottom: 1px solid var(--line); }
.cats .in { display: flex; gap: 22px; overflow-x: auto; height: 46px; align-items: stretch; }
.cats a {
  display: flex; align-items: center; text-decoration: none; color: #222; flex: none; font-size: 15px;
}
.cats a.on { color: var(--red); font-weight: 700; box-shadow: inset 0 -2px 0 var(--red); }
.cats .in::-webkit-scrollbar { display: none; }

.hero-wrap { background: #111; }
.hero {
  display: grid; grid-template-columns: 1.45fr 380px; min-height: 440px;
}
.hero-main { position: relative; min-height: 440px; color: #fff; overflow: hidden; }
.hero-slide {
  position: absolute; inset: 0; color: #fff; text-decoration: none;
  opacity: 0; pointer-events: none; transition: opacity .45s ease;
}
.hero-slide.on { opacity: 1; pointer-events: auto; }
.hero-slide img, .hero-slide .ph { width: 100%; height: 100%; object-fit: cover; object-position: center center; position: absolute; inset: 0; }
.hero-slide img.fit { object-fit: contain; background: #000; }
.hero-slide .ph b, .hero-slide .ph span { display: none; }
.hero-slide .shade {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,.78) 0%, rgba(0,0,0,.28) 72%);
}
.hero-copy { position: relative; z-index: 1; min-height: 440px; display: flex; flex-direction: column; justify-content: flex-end; padding: 36px 36px 72px; }
.hero-nav {
  position: absolute; z-index: 2; left: 36px; right: 36px; bottom: 22px;
  display: flex; align-items: center; gap: 8px;
}
.hero-nav > button, .hero-dots button {
  border: 0; background: rgba(255,255,255,.16); color: #fff; cursor: pointer; height: 32px;
}
.hero-nav > button { width: 32px; font-size: 20px; line-height: 1; }
.hero-dots { display: flex; gap: 6px; flex-wrap: wrap; }
.hero-dots button { padding: 0 10px; font-size: 13px; }
.hero-dots button.on { background: var(--red); }
.kicker { color: #ffb4b4; font-size: 13px; letter-spacing: .08em; font-weight: 700; }
.hero-copy h1 { margin: 8px 0 10px; font-size: 40px; line-height: 1.25; letter-spacing: -0.03em; }
.hero-copy p { margin: 0 0 18px; color: #eee; }
.rankbox { background: #fff; color: var(--ink); padding: 18px 18px 8px; }
.rankbox h2 { margin: 0 0 8px; font-size: 16px; }
.rank { list-style: none; margin: 0; padding: 0; }
.rank li a { display: grid; grid-template-columns: 22px 54px 1fr; gap: 10px; align-items: center; text-decoration: none; padding: 8px 0; border-top: 1px solid #f3f3f3; }
.rank .num { font-weight: 800; color: var(--red); }
.rank .num.dim { color: #999; }
.thumb { width: 54px; height: 72px; background: #111; overflow: hidden; }
.thumb img, .thumb .ph { width: 100%; height: 100%; object-fit: cover; }
.rank b { display: block; font-size: 14px; line-height: 1.35; }
.rank small, .card small, .sub { color: var(--sub); font-size: 12px; }

.section { margin: 28px auto 8px; display: flex; align-items: baseline; justify-content: space-between; }
.section h2 { margin: 0; font-size: 22px; letter-spacing: -0.03em; }
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; padding-bottom: 28px; }
.card { text-decoration: none; background: #fff; display: flex; flex-direction: column; height: 100%; }
.cards .poster,
.cards .poster.full,
.cards .poster.cho,
.cards .poster.ailee { aspect-ratio: 226 / 324; background: #000; }
.cards .poster img { object-fit: contain; object-position: center center; }
.poster { position: relative; aspect-ratio: 3/4.05; background: #111; overflow: hidden; }
.poster img, .poster .ph { width: 100%; height: 100%; object-fit: cover; object-position: center center; }
.poster.full, .poster-lg.full { aspect-ratio: 828 / 1024; background: #000; }
.poster.cho, .poster-lg.cho { aspect-ratio: 430 / 602; background: #000; }
.poster.ailee, .poster-lg.ailee { aspect-ratio: 226 / 324; background: #000; }
.poster.full img, .poster-lg.full img, .poster.cho img, .poster-lg.cho img, .poster.ailee img, .poster-lg.ailee img { object-fit: contain; }
.ribbon { position: absolute; top: 10px; left: 10px; background: #111; color: #fff; font-size: 11px; padding: 3px 6px; }
.card .pad { margin-top: auto; padding: 10px 2px 16px; }
.card b { display: block; font-size: 16px; line-height: 1.35; min-height: 44px; word-break: keep-all; }
.price { color: var(--red); font-weight: 800; margin-top: 6px; }
.price.dim { color: #888; }
.blabel .price, .meta .price, .picked .price, .sum .price, .seatline .price { margin-top: 0; }
.past-head p { margin: -6px 0 16px; color: var(--sub); }
.cards.past-grid { grid-template-columns: repeat(2, 1fr); }
.cards .card.past .poster,
.cards .card.past .poster.wide { aspect-ratio: 16 / 9; background: #111; }
.poster.wide, .poster-lg.wide { aspect-ratio: 16 / 9; background: #111; }
.poster.wide img, .poster-lg.wide img { object-fit: contain; background: #111; }
.price s, .meta s, .blabel s { color: #999; font-weight: 600; margin-right: 6px; }
.ph {
  background:
    radial-gradient(circle at 18% 16%, rgba(250,40,40,.5), transparent 40%),
    linear-gradient(165deg, #161616, #4a1016 78%);
  color: #fff; display: flex; flex-direction: column; justify-content: flex-end; align-items: flex-start; padding: 16px; text-align: left;
}
.ph b { font-size: 12px; letter-spacing: .08em; opacity: .8; font-weight: 700; min-height: 0; }
.ph span { font-size: 22px; font-weight: 800; line-height: 1.3; letter-spacing: -0.04em; margin-top: 8px; word-break: keep-all; }
.thumb .ph b, .thumb .ph span { display: none; }
.poster-lg .ph span { font-size: 34px; }
.detail h1, .hero-copy h1 { word-break: keep-all; }

.page { width: min(1180px, calc(100% - 32px)); margin: 28px auto 72px; }
.narrow { width: min(760px, calc(100% - 32px)); }
.panel { background: #fff; border: 1px solid var(--line); padding: 22px; }
.detail { display: grid; grid-template-columns: 340px 1fr; gap: 36px; align-items: start; }
.places { margin-top: 36px; }
.places h2 { margin: 0 0 14px; }
.place-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.place { margin: 0; background: #fff; border: 1px solid var(--line); }
.place figcaption { display: flex; flex-direction: column; gap: 4px; padding: 14px 14px 0; }
.place figcaption span { color: var(--sub); font-size: 13px; }
.place iframe { display: block; width: 100%; height: 220px; margin-top: 12px; border: 0; }
.place a { display: inline-block; padding: 10px 14px 14px; font-size: 13px; }
.poster-lg { background: #111; aspect-ratio: 3/4.05; }
.poster-lg img, .poster-lg .ph { width: 100%; height: 100%; object-fit: cover; }
.cat { color: var(--red); font-weight: 700; font-size: 13px; }
.detail h1 { margin: 6px 0 8px; font-size: 32px; letter-spacing: -0.03em; line-height: 1.3; }
.meta { width: 100%; border-collapse: collapse; margin: 16px 0; }
.meta th { width: 92px; text-align: left; color: var(--sub); font-weight: 500; padding: 11px 0; vertical-align: top; }
.meta td { padding: 11px 0; border-bottom: 1px solid #f2f2f2; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 6px; }
.prose { white-space: pre-wrap; line-height: 1.75; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 16px;
  background: var(--red); color: #fff; text-decoration: none; border: 0; cursor: pointer; font-weight: 700; border-radius: 2px;
}
.btn:hover { background: var(--red-d); }
.btn[disabled] { background: #ccc; cursor: not-allowed; }
.btn.ghost { background: #fff; color: #222; border: 1px solid #ddd; }
.btn.ghost:hover { background: #fafafa; }
.btn.dark { background: #222; }
.btn.block { width: 100%; }
.btn.tall { height: 56px; font-size: 18px; }
.rowbtns { display: flex; gap: 8px; flex-wrap: wrap; }

.bookhead {
  height: 60px; background: #111; color: #fff; display: flex; align-items: center; gap: 16px; padding: 0 16px;
}
.bookhead a { color: #fff; text-decoration: none; font-size: 14px; }
.bh-mid { flex: 1; min-width: 0; }
.bh-mid b, .bh-mid small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bh-mid small { color: #bbb; }
.timer { font-variant-numeric: tabular-nums; font-weight: 800; color: #ffd0d0; min-width: 64px; text-align: right; }
.steps { display: flex; gap: 18px; background: #fff; border-bottom: 1px solid var(--line); padding: 0 16px; }
.steps span { height: 42px; display: flex; align-items: center; color: #999; font-size: 14px; }
.steps span.on { color: var(--red); font-weight: 800; box-shadow: inset 0 -2px 0 var(--red); }

.book-body { display: grid; grid-template-columns: 280px 1fr 320px; min-height: calc(100vh - 102px); }
.book-body.date { grid-template-columns: 320px 1fr; }
.book-body.pay { grid-template-columns: 1fr 360px; }
.calbox, .side { background: #fff; }
.calbox { border-right: 1px solid var(--line); padding: 16px; }
.mapwrap { background: #e9e9e9; overflow: auto; padding: 22px 16px 40px; }
.side { border-left: 1px solid var(--line); padding: 16px; }
.cal-h { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.cal-h button { border: 0; background: #f3f3f3; width: 32px; height: 32px; cursor: pointer; }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; text-align: center; }
.cal i { font-style: normal; color: #aaa; font-size: 12px; padding: 4px 0; }
.cal button {
  border: 0; background: transparent; height: 36px; cursor: pointer; border-radius: 4px;
}
.cal button.has { font-weight: 800; }
.cal button.on { background: var(--red); color: #fff; }
.cal button:disabled { color: #ddd; cursor: default; }
.times { display: flex; flex-direction: column; gap: 8px; }
.time {
  display: flex; justify-content: space-between; gap: 12px; text-decoration: none;
  background: #fff; border: 1px solid #e5e5e5; padding: 14px 12px;
}
.time.bad { color: #999; pointer-events: none; background: #fafafa; }
.time small { display: block; color: #777; font-weight: 500; font-size: 12px; margin-top: 2px; }
.time b { font-size: 16px; }
.stage {
  width: min(460px, 78%); height: 34px; margin: 0 auto 18px; background: #222; color: #fff;
  clip-path: polygon(8% 0, 92% 0, 100% 100%, 0 100%);
  display: grid; place-items: center; letter-spacing: .18em; font-size: 12px;
}
.hall { width: max-content; margin: 0 auto; }
.mapwrap:has(.gg) { background: #101018; }
.gg { width: max-content; margin: 0 auto; padding: 8px 8px 20px; }
.gg-label { color: #d7d7ea; font-weight: 800; margin: 16px 0 8px; }
.gg-floor { display: flex; align-items: center; justify-content: center; gap: 22px; }
.gg-mid { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.gg-split { display: flex; gap: 16px; }
.gg-side { display: flex; align-items: center; gap: 4px; }
.gg-side.left { transform: rotate(-14deg); }
.gg-side.right { transform: rotate(14deg); }
.gg-wheel { display: flex; gap: 10px; margin: 2px 0; }
.gg-wheel i { width: 14px; height: 14px; border: 1px solid #9a9ab0; border-radius: 50%; }
.gg-stage { margin-top: 16px; }
.gg-note { color: #b7b7c8; font-size: 12px; text-align: center; margin: 12px 0 0; }
.gg .row { gap: 2px; margin: 2px 0; }
.blabel { display: flex; align-items: center; gap: 8px; font-weight: 700; margin: 16px 0 8px; }
.row { display: flex; align-items: center; gap: 4px; margin: 4px 0; }
.rowlab { width: 26px; text-align: center; color: #666; font-size: 11px; }
.seat {
  width: var(--sz); height: var(--sz); border: 0; border-radius: 3px; padding: 0;
  background: var(--c, #888); color: #fff; font-size: 10px; font-weight: 700; cursor: pointer;
}
.seat.aisle { margin-left: 14px; }
.seat[data-state="sold"], .seat[data-state="held"] { background: #cfcfcf; color: transparent; cursor: not-allowed; }
.seat[data-state="mine"] { background: var(--red); outline: 2px solid #111; color: #fff; }
.map.z1 { --sz: 20px; }
.map.z2 { --sz: 26px; }
.map.z3 { --sz: 32px; }
.map.exco.z1 { --sz: 13px; }
.map.exco.z2 { --sz: 16px; }
.map.exco.z3 { --sz: 20px; }
.exco { width: max-content; margin: 0 auto; }
.exco-band { position: relative; display: flex; justify-content: center; align-items: flex-start; gap: 18px; margin: 0 0 26px; }
.exco-name { text-align: center; font-size: 12px; font-weight: 800; margin-bottom: 6px; white-space: nowrap; }
.exco-name .price { margin-top: 0; }
.exco .row {
  display: grid;
  grid-template-columns: 14px repeat(var(--n), var(--sz)) 14px;
  gap: 2px;
  margin: 1px 0;
  align-items: center;
}
.exco .rowlab { width: auto; font-size: 10px; }
.exco .gap { width: var(--sz); height: var(--sz); }
.exco .seat { font-size: 8px; line-height: 1; }
.exco-wheel {
  position: absolute; left: 50%; bottom: 0; transform: translateX(-50%);
  font-size: 11px; font-weight: 800; color: #333; background: #e9e9e9;
  padding: 2px 6px; pointer-events: none; white-space: nowrap;
}
.exco-note { text-align: center; color: #666; font-size: 12px; margin: 0; }
.legend { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 16px; color: #555; font-size: 12px; }
.legend b { display: inline-block; width: 12px; height: 12px; border-radius: 2px; margin-right: 4px; vertical-align: -1px; }
.zoom { display: flex; gap: 6px; justify-content: flex-end; margin-bottom: 8px; }
.zoom button { width: 32px; height: 32px; border: 1px solid #ccc; background: #fff; cursor: pointer; }
.picked { list-style: none; margin: 0 0 12px; padding: 0; }
.picked li { display: flex; justify-content: space-between; gap: 8px; padding: 8px 0; border-bottom: 1px solid #f2f2f2; font-size: 14px; }
.sum { display: flex; justify-content: space-between; margin: 6px 0; }
.sum.total { font-size: 18px; font-weight: 800; margin-top: 10px; }
.sum.total b { color: var(--red); }
.note { color: var(--sub); font-size: 13px; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.field input, .field select, .field textarea {
  height: 42px; border: 1px solid #ddd; border-radius: 2px; padding: 0 10px; background: #fff;
}
.field textarea { height: 110px; padding: 10px; resize: vertical; }
.check { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; margin: 8px 0 14px; }
.ticket { background: #fff; border: 1px solid var(--line); padding: 22px; display: grid; grid-template-columns: 180px 1fr; gap: 18px; }
.ticket h1 { margin: 0 0 8px; font-size: 26px; }
.ono { font-size: 20px; font-weight: 800; letter-spacing: .02em; }
.seatline { display: flex; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px solid #f3f3f3; }
#qr canvas { width: 180px; height: 180px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.stat { background: #fff; border: 1px solid var(--line); padding: 16px; }
.stat b { display: block; font-size: 24px; margin-top: 4px; }
table { width: 100%; border-collapse: collapse; background: #fff; }
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; font-size: 14px; }
th { color: var(--sub); font-weight: 600; background: #fafafa; }
.grade-head, .grade-row, .sess-row { display: grid; grid-template-columns: 1.1fr .8fr .8fr .55fr .5fr .5fr .8fr auto; gap: 6px; margin-bottom: 6px; align-items: center; }
.grade-scroll { overflow-x: auto; margin-bottom: 8px; }
.sess-row { grid-template-columns: 1fr auto; }
.grade-row input, .sess-row input { height: 38px; border: 1px solid #ddd; padding: 0 8px; width: 100%; }
.grade-row input[type="hidden"] { display: none; }
.tools { display: flex; gap: 8px; margin: 8px 0 14px; }
.banner { background: #fff6f6; border: 1px solid #ffd2d2; color: #8a1f1f; padding: 10px 12px; margin-bottom: 12px; font-size: 13px; }
.lead { font-size: 16px; margin: 0 0 8px; }
.tiers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 18px 0 22px; }
.tier { background: #fff; border: 1px solid var(--line); padding: 16px; }
.tier.now { border-color: var(--red); }
.tier b { display: block; font-size: 18px; margin-bottom: 8px; }
.tier p { margin: 4px 0; color: #444; font-size: 14px; }
.rules { margin: 8px 0 18px; padding-left: 18px; line-height: 1.7; }
.offer { border: 1px solid var(--line); background: #fff; padding: 12px; margin: 8px 0 14px; }
.offer b { display: block; margin-bottom: 6px; }
.offer label { display: flex; gap: 8px; align-items: flex-start; margin: 6px 0; font-size: 14px; }
.sub { color: var(--sub); font-size: 12px; }
.foot { background: #1b1b1b; color: #cfcfcf; padding: 28px 0 40px; font-size: 13px; }
.foot a { color: #fff; }
.foot .in { width: min(1180px, calc(100% - 32px)); margin: 0 auto; display: grid; gap: 6px; }
.empty { background: #fff; border: 1px dashed #ddd; padding: 36px 16px; text-align: center; }
.tag { display: inline-block; background: #f3f3f3; padding: 2px 6px; font-size: 12px; }

@media (max-width: 980px) {
  .hero, .detail, .book-body, .book-body.date, .book-body.pay, .ticket, .cards { grid-template-columns: 1fr; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .cards.past-grid { grid-template-columns: 1fr; }
  .tiers { grid-template-columns: 1fr 1fr; }
  .hero-main, .hero-copy { min-height: 320px; }
  .hero-copy h1 { font-size: 28px; }
  .poster-lg { height: 240px; aspect-ratio: auto; }
  .poster-lg.full { height: auto; aspect-ratio: 828 / 1024; }
  .poster-lg.cho { height: auto; aspect-ratio: 430 / 602; }
  .poster-lg.ailee { height: auto; aspect-ratio: 226 / 324; }
  .poster-lg img, .poster-lg .ph { height: 240px; }
  .poster-lg.full img, .poster-lg.cho img, .poster-lg.ailee img { height: 100%; }
  .poster-lg.wide { height: auto; aspect-ratio: 16 / 9; }
  .poster-lg.wide img { height: 100%; object-fit: contain; }
  .rankbox { border-top: 1px solid #eee; }
  .book-body { min-height: 0; }
  .side { border-left: 0; border-top: 1px solid var(--line); }
  .stats { grid-template-columns: 1fr; }
  .grade-head, .grade-row { min-width: 860px; grid-template-columns: 1.1fr .8fr .8fr .55fr .5fr .5fr .8fr auto; }
  .search { display: none; }
  .header .in { gap: 10px; }
}
@media print {
  .header, .cats, .foot, .bookhead, .steps, .noprint, #toast, #prog { display: none !important; }
  body { background: #fff; }
  .ticket { border-color: #111; }
}
